diff options
author | m-shunji <76516098+m-shunji@users.noreply.github.com> | 2024-01-26 19:00:22 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-26 11:00:22 +0100 |
commit | 6c3c06a5710fd4a2f5799bc6909697f7e39ec382 (patch) | |
tree | 9b6e2afd45199cb19cc9a634493b81b97d13aadd | |
parent | 6a4573ce5aef2c6b890b11092620a36d4395cef9 (diff) | |
download | spack-6c3c06a5710fd4a2f5799bc6909697f7e39ec382.tar.gz spack-6c3c06a5710fd4a2f5799bc6909697f7e39ec382.tar.bz2 spack-6c3c06a5710fd4a2f5799bc6909697f7e39ec382.tar.xz spack-6c3c06a5710fd4a2f5799bc6909697f7e39ec382.zip |
pexsi: fix to build with fujitsu-ssl2 (#42234)
Co-authored-by: inada-yoshie <inada.yoshie@fujitsu.com>
-rw-r--r-- | var/spack/repos/builtin/packages/pexsi/fujitsu-add-link-flags.patch | 11 | ||||
-rw-r--r-- | var/spack/repos/builtin/packages/pexsi/package.py | 6 |
2 files changed, 17 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/pexsi/fujitsu-add-link-flags.patch b/var/spack/repos/builtin/packages/pexsi/fujitsu-add-link-flags.patch new file mode 100644 index 0000000000..2a2f6e7716 --- /dev/null +++ b/var/spack/repos/builtin/packages/pexsi/fujitsu-add-link-flags.patch @@ -0,0 +1,11 @@ +diff -Nur spack-src.org/fortran/CMakeLists.txt spack-src/fortran/CMakeLists.txt +--- spack-src.org/fortran/CMakeLists.txt 2023-06-06 17:55:44.000000000 +0900 ++++ spack-src/fortran/CMakeLists.txt 2023-06-06 15:50:05.000000000 +0900 +@@ -47,6 +47,7 @@ +
+ endmacro()
+
++set (CMAKE_EXE_LINKER_FLAGS "--linkfortran")
+
+ add_pexsi_f_example_exe( f_driver_ksdft )
+ add_pexsi_f_example_exe( f_driver_pselinv_real )
diff --git a/var/spack/repos/builtin/packages/pexsi/package.py b/var/spack/repos/builtin/packages/pexsi/package.py index 88728a5c5e..9b7191ef00 100644 --- a/var/spack/repos/builtin/packages/pexsi/package.py +++ b/var/spack/repos/builtin/packages/pexsi/package.py @@ -38,6 +38,8 @@ class Pexsi(MakefilePackage, CMakePackage): version("0.10.2", sha256="8714c71b76542e096211b537a9cb1ffb2c28f53eea4f5a92f94cc1ca1e7b499f") version("0.9.0", sha256="e5efe0c129013392cdac3234e37f1f4fea641c139b1fbea47618b4b839d05029") + patch("fujitsu-add-link-flags.patch", when="%fj") + depends_on("parmetis") depends_on("superlu-dist@5.1.2:5.3", when="@0.10.2:0") depends_on("superlu-dist@:6.1.0", when="@1") # Upper limit from CP2K toolchain @@ -123,4 +125,8 @@ class CMakeBuilder(spack.build_systems.cmake.CMakeBuilder): self.define_from_variant("PEXSI_ENABLE_FORTRAN", "fortran"), self.define_from_variant("PEXSI_ENABLE_OPENMP ", "openmp"), ] + + if self.spec.satisfies("%fj"): + args.append(self.define("BLAS_LIBRARIES", self.spec["blas"].libs.link_flags)) + return args |