commit 40aab72031277afc1f7d5f95cad5a7f24ad65355 parent 2033cc7b5ede662dbee1b0de1850fad731ba491a Author: David Goulet <dgoulet@torproject.org> Date: Wed, 26 Oct 2022 14:00:57 -0400 Merge branch 'tor-gitlab/mr/628' Diffstat:
| M | scripts/build/combine_libs | | | 10 | ++++++++++ |
1 file changed, 10 insertions(+), 0 deletions(-)
diff --git a/scripts/build/combine_libs b/scripts/build/combine_libs @@ -11,6 +11,15 @@ abspath() { echo "$(cd "$(dirname "$1")" >/dev/null && pwd)/$(basename "$1")" } +apple_symdef_fix() { + # On modern macOS and iOS we need to remove the "__.SYMDEF" and "__.SYMDEF + # SORTED" before we repack the archive. + # See: tor#40683. + if [ "$(uname -s)" = "Darwin" ] ; then + find . -name "__.SYMDEF*" -delete + fi +} + TARGET=$(abspath "$1") shift @@ -25,6 +34,7 @@ for input in "$@"; do done cd "$TMPDIR" >/dev/null +apple_symdef_fix "${AR:-ar}" "${ARFLAGS:-cru}" library.tmp.a ./*/** "${RANLIB:-ranlib}" library.tmp.a mv -f library.tmp.a "$TARGET"