From e6b1e5a554fd0f776bd01c17cfb1ebbbdf7a7831 Mon Sep 17 00:00:00 2001 From: Jim Myhrberg Date: Tue, 3 Aug 2021 00:13:10 +0100 Subject: [PATCH] fix(sign): resolve signing issue caused by re-linking shared lib in *.eln files When shared libs are stored in `Contents/Frameworks`, the re-link path for `/usr/local/lib/gcc/11/libgcc_s.1.dylib` within bundled *.eln files becomes `@executable_path/../Frameworks/libgcc_s.1.dylib`, which seems to not leave enough space in the *.eln binary header to add a code signature with codesign. This used to work when shared libraries were bundled into `Contents/MacOS/lib`, leading to a shorter relink path of `@executable_path/lib/libgcc_s.1.dylib`, which does leave enough space to add a code signature to *.eln files. --- build-emacs-for-macos | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build-emacs-for-macos b/build-emacs-for-macos index 8505cea..f9dac95 100755 --- a/build-emacs-for-macos +++ b/build-emacs-for-macos @@ -747,7 +747,7 @@ class AbstractEmbedder end def lib_dir - File.join(app, 'Contents', 'Frameworks') + File.join(invocation_dir, 'lib') end end