Skip to content

Commit 5fe6ce1

Browse files
committed
reloc
1 parent d851203 commit 5fe6ce1

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

.github/workflows/build_osx.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,17 @@ jobs:
6363
install_root=$(find ./IfcOpenShell/build -maxdepth 4 -name install)
6464
find "$install_root" -type f -name 'cache-*.tar.gz' -maxdepth 1 -exec tar -xzf {} -C "$install_root" \;
6565
66+
- name: Relocate python libraries
67+
run: |
68+
base=$(find $PWD/IfcOpenShell/build -maxdepth 4 -name install)
69+
for pybin in $(find $base -name python3); do
70+
l="$(ls $(dirname $pybin)/../lib/libpython*.dylib 2>/dev/null | head -n 1)"
71+
o="$(otool -L "$pybin" | awk '/libpython/ {print $1; exit}')"
72+
n="@executable_path/../lib/$(basename "$l")"
73+
install_name_tool -change "$o" "$n" "$pybin"
74+
otool -L "$pybin"
75+
done
76+
6677
- name: Debug
6778
run: |
6879
base=$(find $PWD/IfcOpenShell/build -maxdepth 4 -name install)

0 commit comments

Comments
 (0)