mirror of
https://gitlab.gnome.org/GNOME/gimp.git
synced 2025-07-03 09:23:24 +00:00

The DYLD_LIBRARY_PATH trick was working fine on CI, but not on local builds for Lukas. Apparently there are security measures disabling the environment variable. Instead let's temporarily add then remove libgimp libraries folders from rpath. See: https://gitlab.gnome.org/Infrastructure/gimp-macos-build/-/merge_requests/292#note_2075291
38 lines
1.7 KiB
Bash
Executable file
38 lines
1.7 KiB
Bash
Executable file
#!/bin/sh
|
|
|
|
if [ -n "$GIMP_TEMP_UPDATE_RPATH" ]; then
|
|
# Earlier code used to set DYLD_LIBRARY_PATH environment variable instead, but
|
|
# it didn't work on contributor's builds because of System Integrity
|
|
# Protection (SIP), though it did work in the CI.
|
|
export IFS=":"
|
|
for bin in $GIMP_TEMP_UPDATE_RPATH;
|
|
do
|
|
install_name_tool -add_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimp $bin
|
|
install_name_tool -add_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpbase $bin
|
|
install_name_tool -add_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpcolor $bin
|
|
install_name_tool -add_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpconfig $bin
|
|
install_name_tool -add_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpmath $bin
|
|
install_name_tool -add_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpmodule $bin
|
|
install_name_tool -add_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpthumb $bin
|
|
install_name_tool -add_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpwidgets $bin
|
|
done;
|
|
unset IFS
|
|
fi
|
|
|
|
cat /dev/stdin | $GIMP_SELF_IN_BUILD "$@"
|
|
|
|
if [ -n "$GIMP_TEMP_UPDATE_RPATH" ]; then
|
|
export IFS=":"
|
|
for bin in $GIMP_TEMP_UPDATE_RPATH;
|
|
do
|
|
install_name_tool -delete_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimp $bin
|
|
install_name_tool -delete_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpbase $bin
|
|
install_name_tool -delete_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpcolor $bin
|
|
install_name_tool -delete_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpconfig $bin
|
|
install_name_tool -delete_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpmath $bin
|
|
install_name_tool -delete_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpmodule $bin
|
|
install_name_tool -delete_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpthumb $bin
|
|
install_name_tool -delete_rpath ${GIMP_GLOBAL_BUILD_ROOT}/libgimpwidgets $bin
|
|
done;
|
|
unset IFS
|
|
fi
|