fixDarwinDylibNames: set name of install_name_tool

This commit is contained in:
Andrew Childs 2020-11-19 17:18:44 +09:00
parent 9fb8924389
commit c696fcdacb
2 changed files with 4 additions and 2 deletions

View file

@ -23,7 +23,7 @@ fixDarwinDylibNames() {
for fn in "$@"; do
if [ -L "$fn" ]; then continue; fi
echo "$fn: fixing dylib"
int_out=$(install_name_tool -id "$fn" "${flags[@]}" "$fn" 2>&1)
int_out=$(@targetPrefix@install_name_tool -id "$fn" "${flags[@]}" "$fn" 2>&1)
result=$?
if [ "$result" -ne 0 ] &&
! grep "shared library stub file and can't be changed" <<< "$out"

View file

@ -641,7 +641,9 @@ in
setJavaClassPath = makeSetupHook { } ../build-support/setup-hooks/set-java-classpath.sh;
fixDarwinDylibNames = makeSetupHook { } ../build-support/setup-hooks/fix-darwin-dylib-names.sh;
fixDarwinDylibNames = makeSetupHook {
substitutions = { inherit (binutils) targetPrefix; };
} ../build-support/setup-hooks/fix-darwin-dylib-names.sh;
keepBuildTree = makeSetupHook { } ../build-support/setup-hooks/keep-build-tree.sh;