From d929336f08f08e0b8c6a054df2367d24af92dd11 Mon Sep 17 00:00:00 2001 From: rejbasket <39080670+rejbasket@users.noreply.github.com> Date: Sat, 10 Feb 2024 20:16:30 +0100 Subject: Rejbasket/pyinstaller fix installer checks (#2718) * netowrkx deps added in build * check for user inkscape config before installing * get os version in exception * update electron app location according to pyinstaller redesign * fixed broken libgeos syslinks * contents-directory added pyinstaller args fix broken linux and win versions * updated inkex * fix print_pdf --------- authored-by: rejbasket --- bin/build-distribution-archives | 21 +++++++++++++++++---- bin/build-python | 2 ++ 2 files changed, 19 insertions(+), 4 deletions(-) (limited to 'bin') diff --git a/bin/build-distribution-archives b/bin/build-distribution-archives index 021461df..285e5ef8 100644 --- a/bin/build-distribution-archives +++ b/bin/build-distribution-archives @@ -8,8 +8,21 @@ if [ "$BUILD" = "osx" ]; then # adding version to Info.plist plutil -replace CFBundleShortVersionString -string ${VERSION} dist/inkstitch.app/Contents/Info.plist rm -rf dist/inkstitch/ - # this removes the extra dylibs that cause notary to fail. - rm -rf dist/inkstitch.app/Contents/MacOS/shapely/.dylibs + # unlinking the libgeos and dot dylib folder syslinks and fix broken syslinks for notary. + # copying libgeos dylibs with ditto preserves information to pass notary. + unlink dist/inkstitch.app/Contents/Resources/shapely/.dylibs + + unlink dist/inkstitch.app/Contents/Resources/libgeos.3.11.2.dylib + unlink dist/inkstitch.app/Contents/Resources/libgeos_c.1.17.2.dylib + + unlink dist/inkstitch.app/Contents/Frameworks/libgeos.3.11.2.dylib + unlink dist/inkstitch.app/Contents/Frameworks/libgeos_c.1.17.2.dylib + + ditto dist/inkstitch.app/Contents/Frameworks/shapely/__dot__dylibs/libgeos.3.11.2.dylib dist/inkstitch.app/Contents/Resources/ + ditto dist/inkstitch.app/Contents/Frameworks/shapely/__dot__dylibs/libgeos_c.1.17.2.dylib dist/inkstitch.app/Contents/Resources/ + + ditto dist/inkstitch.app/Contents/Frameworks/shapely/__dot__dylibs/libgeos.3.11.2.dylib dist/inkstitch.app/Contents/Frameworks/ + ditto dist/inkstitch.app/Contents/Frameworks/shapely/__dot__dylibs/libgeos_c.1.17.2.dylib dist/inkstitch.app/Contents/Frameworks/ # Install location for pkgbuild PKG_INSTALL_PATH="/tmp/inkstitch/" # Checking arch of macos and setting path of electron for arm64 or intel @@ -36,7 +49,7 @@ if [ "$BUILD" = "osx" ]; then DEV_IDENT="Developer ID Application: Lex Neva (929A568N58)" echo "Signing of inkstitch.app" # Coyping inkstitch-gui.app into inkstitch - ditto "${ELECTRON_BUILD_PATH}" dist/inkstitch.app/Contents/MacOS/electron + ditto "${ELECTRON_BUILD_PATH}" dist/inkstitch.app/Contents/Frameworks/electron # signing the binary may fix notary issue /usr/bin/codesign -s "${DEV_IDENT}" \ --deep \ @@ -92,7 +105,7 @@ if [ "$BUILD" = "osx" ]; then fi else # local builds will not be signed or notarized - cp -a "${ELECTRON_BUILD_PATH}" dist/inkstitch.app/Contents/MacOS/electron + cp -a "${ELECTRON_BUILD_PATH}" dist/inkstitch.app/Contents/Frameworks/electron pkgbuild --root dist/inkstitch.app \ --component-plist installer_scripts/inkstitch.plist \ --ownership recommended \ diff --git a/bin/build-python b/bin/build-python index 4c27e5d8..cd3e84a2 100755 --- a/bin/build-python +++ b/bin/build-python @@ -2,6 +2,8 @@ set -e info_year=$( date "+%Y" ) +# PyInstaller v6.x rearranges folder configuration causing broken builds, This re-enables old onedir layout. +pyinstaller_args+="--contents-directory . " # We need to use the precompiled bootloader linked with graphical Mac OS X # libraries if we develop a GUI application for Mac: -- cgit v1.2.3