py-petsc4py: patch again for wrong assumption on LDSHARED
This commit is contained in:
parent
bab2053d54
commit
6989bf9661
@ -7,7 +7,7 @@ index 8a2466a5bd..73c08b923a 100644
|
||||
ldflags = getenv('LDFLAGS', cflags + ' ' + (ldflags or ''))
|
||||
ldcmd = split_quoted(ld) + split_quoted(ldflags)
|
||||
- ldshared = [flg for flg in split_quoted(ldshared) if flg not in ldcmd]
|
||||
+ ldshared = [flg for flg in split_quoted(ldshared) if flg not in ldcmd and (flg.find('/lib/spack/env')<0)]
|
||||
+ ldshared = [flg for flg in split_quoted(ldshared) if flg not in ldcmd and (flg.find('/libexec/spack')<0)]
|
||||
ldshared = str.join(' ', ldshared)
|
||||
#
|
||||
def get_flags(cmd):
|
||||
|
@ -0,0 +1,12 @@
|
||||
diff --unified --recursive --no-dereference spack-src1/conf/confpetsc.py spack-src2/conf/confpetsc.py
|
||||
--- spack-src1/conf/confpetsc.py 2025-02-17 13:02:08.781676798 +0100
|
||||
+++ spack-src2/conf/confpetsc.py 2025-02-17 13:03:13.024625112 +0100
|
||||
@@ -350,7 +350,7 @@
|
||||
ldshared = [
|
||||
flg
|
||||
for flg in split_quoted(ldshared)
|
||||
- if flg not in ldcmd and (flg.find('/lib/spack/env') < 0)
|
||||
+ if flg not in ldcmd and (flg.find('/libexec/spack/') < 0)
|
||||
]
|
||||
ldshared = str.join(' ', ldshared)
|
||||
|
@ -93,6 +93,9 @@ class PyPetsc4py(PythonPackage):
|
||||
|
||||
variant("mpi", default=True, description="Activates MPI support")
|
||||
|
||||
# Hack to fix https://github.com/spack/spack/issues/21451, where Petsc4Py expects LDSHARED
|
||||
# to start with the same executable as get_config_var("CC")
|
||||
patch("ldshared_319.patch", when="@3.19:")
|
||||
patch("ldshared.patch", when="@:3.18")
|
||||
|
||||
depends_on("py-cython@3:", when="@3.20:", type="build")
|
||||
|
Loading…
Reference in New Issue
Block a user