Check for -r
in ccld mode too (#1972)
This commit is contained in:
parent
efae58a4ef
commit
ccf530ba5e
4
lib/spack/env/cc
vendored
4
lib/spack/env/cc
vendored
@ -204,9 +204,9 @@ fi
|
|||||||
# It doesn't work with -rpath.
|
# It doesn't work with -rpath.
|
||||||
# This variable controls whether they are added.
|
# This variable controls whether they are added.
|
||||||
add_rpaths=true
|
add_rpaths=true
|
||||||
if [[ $mode == ld && "$SPACK_SHORT_SPEC" =~ "darwin" ]]; then
|
if [[ ($mode == ld || $mode == ccld) && "$SPACK_SHORT_SPEC" =~ "darwin" ]]; then
|
||||||
for arg in "$@"; do
|
for arg in "$@"; do
|
||||||
if [[ $arg == -r ]]; then
|
if [[ ($arg == -r && $mode == ld) || ($arg == -Wl,-r && $mode == ccld) ]]; then
|
||||||
add_rpaths=false
|
add_rpaths=false
|
||||||
break
|
break
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user