diff options
author | Todd Gamblin <tgamblin@llnl.gov> | 2022-07-30 15:19:18 -0700 |
---|---|---|
committer | Todd Gamblin <tgamblin@llnl.gov> | 2022-07-31 13:29:20 -0700 |
commit | f52f6e99dbf1131886a80112b8c79dfc414afb7c (patch) | |
tree | 05cb7d64b2395922f2f24683da49f472075be12c /var/spack/repos/builtin/packages/salmon-tddft/package.py | |
parent | 549ba1ed32372c67fc57271cde3797d58b7dec6e (diff) | |
download | spack-f52f6e99dbf1131886a80112b8c79dfc414afb7c.tar.gz spack-f52f6e99dbf1131886a80112b8c79dfc414afb7c.tar.bz2 spack-f52f6e99dbf1131886a80112b8c79dfc414afb7c.tar.xz spack-f52f6e99dbf1131886a80112b8c79dfc414afb7c.zip |
black: reformat entire repository with black
Diffstat (limited to 'var/spack/repos/builtin/packages/salmon-tddft/package.py')
-rw-r--r-- | var/spack/repos/builtin/packages/salmon-tddft/package.py | 116 |
1 files changed, 60 insertions, 56 deletions
diff --git a/var/spack/repos/builtin/packages/salmon-tddft/package.py b/var/spack/repos/builtin/packages/salmon-tddft/package.py index 4d79957583..56efc406ed 100644 --- a/var/spack/repos/builtin/packages/salmon-tddft/package.py +++ b/var/spack/repos/builtin/packages/salmon-tddft/package.py @@ -18,81 +18,85 @@ class SalmonTddft(CMakePackage): homepage = "https://salmon-tddft.jp" url = "https://salmon-tddft.jp/download/SALMON-v.2.0.0.tar.gz" - version('2.0.0', sha256='c3bb80bc5d338cba21cd8f345acbf2f2d81ef75af069a0a0ddbdc0acf358456c') - version('1.2.1', sha256='a5045149e49abe9dd9edefe00cd1508a1323081bc3d034632176b728effdbaeb') + version("2.0.0", sha256="c3bb80bc5d338cba21cd8f345acbf2f2d81ef75af069a0a0ddbdc0acf358456c") + version("1.2.1", sha256="a5045149e49abe9dd9edefe00cd1508a1323081bc3d034632176b728effdbaeb") - variant('mpi', default=False, description='Enable MPI') - variant('libxc', default=False, description='Enable libxc') - variant('scalapack', default=False, description='Enable scalapack') - variant('eigenexa', default=False, description='Enable eigenexa') + variant("mpi", default=False, description="Enable MPI") + variant("libxc", default=False, description="Enable libxc") + variant("scalapack", default=False, description="Enable scalapack") + variant("eigenexa", default=False, description="Enable eigenexa") variant( - 'manycore', default=False, - description='Enable optimization of reduction for many-core processor' + "manycore", + default=False, + description="Enable optimization of reduction for many-core processor", ) variant( - 'current_processing', default=False, - description='Enable preprocessing of the current computation in RT' + "current_processing", + default=False, + description="Enable preprocessing of the current computation in RT", ) - depends_on('cmake@3.14:', type='build') - depends_on('mpi', type='link', when='+mpi') - depends_on('scalapack', type='link', when='+scalapack') - depends_on('eigenexa', type='link', when='+eigenexa') - depends_on('lapack', type='link') - depends_on('libxc', type='link', when='+libxc') - depends_on('libxc@:4.9', type='link', when='@:1.9.9 +libxc') + depends_on("cmake@3.14:", type="build") + depends_on("mpi", type="link", when="+mpi") + depends_on("scalapack", type="link", when="+scalapack") + depends_on("eigenexa", type="link", when="+eigenexa") + depends_on("lapack", type="link") + depends_on("libxc", type="link", when="+libxc") + depends_on("libxc@:4.9", type="link", when="@:1.9.9 +libxc") - conflicts('+scalapack', when='~mpi') - conflicts('+eigenexa', when='@:1.9.9') - conflicts('+eigenexa', when='~scalapack') - conflicts('+manycore', when='@2.0.0:') - conflicts('+current_processing', when='@2.0.0:') + conflicts("+scalapack", when="~mpi") + conflicts("+eigenexa", when="@:1.9.9") + conflicts("+eigenexa", when="~scalapack") + conflicts("+manycore", when="@2.0.0:") + conflicts("+current_processing", when="@2.0.0:") - patch('fjmpi.patch', when='@2.0.0: %fj') - patch('v2.0.libxc-5.0.patch', when='@2.0.0 +libxc') - patch('cmakefix.patch', when='+scalapack') + patch("fjmpi.patch", when="@2.0.0: %fj") + patch("v2.0.libxc-5.0.patch", when="@2.0.0 +libxc") + patch("cmakefix.patch", when="+scalapack") def cmake_args(self): define_from_variant = self.define_from_variant spec = self.spec define = self.define args = [ - define_from_variant('USE_SCALAPACK', 'scalapack'), - define_from_variant('USE_EIGENEXA', 'eigenexa'), - define_from_variant('USE_MPI', 'mpi'), - define_from_variant('USE_LIBXC', 'libxc'), - define_from_variant('REDUCE_FOR_MANYCORE', 'manycore'), - define_from_variant('CURRENT_PREPROCESSING', 'current_processing') + define_from_variant("USE_SCALAPACK", "scalapack"), + define_from_variant("USE_EIGENEXA", "eigenexa"), + define_from_variant("USE_MPI", "mpi"), + define_from_variant("USE_LIBXC", "libxc"), + define_from_variant("REDUCE_FOR_MANYCORE", "manycore"), + define_from_variant("CURRENT_PREPROCESSING", "current_processing"), ] - if spec.satisfies('+mpi'): - args.extend([ - define('CMAKE_C_COMPILER', spec['mpi'].mpicc), - define('CMAKE_Fortran_COMPILER', spec['mpi'].mpifc), - ]) - if spec.satisfies('+scalapack'): - math_libs = spec['scalapack'].libs + \ - spec['lapack'].libs + spec['blas'].libs - if spec.satisfies('@2.0:'): - args.append(define('ScaLAPACK_VENDOR_FLAGS', - math_libs.ld_flags)) + if spec.satisfies("+mpi"): + args.extend( + [ + define("CMAKE_C_COMPILER", spec["mpi"].mpicc), + define("CMAKE_Fortran_COMPILER", spec["mpi"].mpifc), + ] + ) + if spec.satisfies("+scalapack"): + math_libs = spec["scalapack"].libs + spec["lapack"].libs + spec["blas"].libs + if spec.satisfies("@2.0:"): + args.append(define("ScaLAPACK_VENDOR_FLAGS", math_libs.ld_flags)) else: - args.extend([ - define('BLACS_LINKER_FLAGS', math_libs.ld_flags), - define('BLACS_LIBRARIES', math_libs.libraries), - define('ScaLAPACK_LINKER_FLAGS', math_libs.ld_flags), - define('ScaLAPACK_LIBRARIES', math_libs.libraries) - ]) - if spec.satisfies('^fujitsu-mpi'): - args.append(define('USE_FJMPI', True)) + args.extend( + [ + define("BLACS_LINKER_FLAGS", math_libs.ld_flags), + define("BLACS_LIBRARIES", math_libs.libraries), + define("ScaLAPACK_LINKER_FLAGS", math_libs.ld_flags), + define("ScaLAPACK_LIBRARIES", math_libs.libraries), + ] + ) + if spec.satisfies("^fujitsu-mpi"): + args.append(define("USE_FJMPI", True)) else: - args.append(define('USE_FJMPI', False)) - if spec.satisfies('%fj'): - args.append(self.define('CMAKE_Fortran_MODDIR_FLAG', '-M')) + args.append(define("USE_FJMPI", False)) + if spec.satisfies("%fj"): + args.append(self.define("CMAKE_Fortran_MODDIR_FLAG", "-M")) return args def flag_handler(self, name, flags): flags = list(flags) - if name == 'fflags': - if self.spec.satisfies('%gcc'): - flags.append('-ffree-line-length-none') + if name == "fflags": + if self.spec.satisfies("%gcc"): + flags.append("-ffree-line-length-none") return (None, None, flags) |