diff options
Diffstat (limited to 'bin')
| -rw-r--r-- | bin/build-distribution-archives | 15 | ||||
| -rwxr-xr-x | bin/build-geos-win.cmd | 29 | ||||
| -rwxr-xr-x | bin/build-linux-dist | 24 |
3 files changed, 53 insertions, 15 deletions
diff --git a/bin/build-distribution-archives b/bin/build-distribution-archives index 285e5ef8..3565e3f5 100644 --- a/bin/build-distribution-archives +++ b/bin/build-distribution-archives @@ -8,21 +8,6 @@ if [ "$BUILD" = "osx" ]; then # adding version to Info.plist plutil -replace CFBundleShortVersionString -string ${VERSION} dist/inkstitch.app/Contents/Info.plist rm -rf dist/inkstitch/ - # 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 diff --git a/bin/build-geos-win.cmd b/bin/build-geos-win.cmd new file mode 100755 index 00000000..c2b5d4b7 --- /dev/null +++ b/bin/build-geos-win.cmd @@ -0,0 +1,29 @@ +@echo off
+mkdir %CD%\geos-build
+SET GEOS_INSTALL=%CD%\geos-build
+
+if NOT DEFINED BUILD32 (SET BUILDFLAG="x64") else (SET BUILDFLAG="Win32")
+echo %BUILDFLAG%
+
+curl -O https://download.osgeo.org/geos/geos-3.12.1.tar.bz2
+
+7z x geos-3.12.1.tar.bz2
+7z x geos-3.12.1.tar
+
+cd geos-3.12.1
+cmake -S . -B _build -G "Visual Studio 17 2022" -A %BUILDFLAG% -DCMAKE_INSTALL_PREFIX=%GEOS_INSTALL% -DCMAKE_GENERATOR_TOOLSET=host=x64
+
+cmake --build _build --config Release -j 16 --verbose
+cd _build
+cmake --install .
+
+SET PATH=%GEOS_INSTALL%\bin;%PATH%
+SET GEOS_INCLUDE_PATH=%GEOS_INSTALL%\include
+set GEOS_LIBRARY_PATH=%GEOS_INSTALL%\lib
+
+xcopy %GEOS_INSTALL%\bin\geos_c.dll %pythonLocation% /E /H /C /I
+xcopy %GEOS_INSTALL%\bin\geos.dll %pythonLocation% /E /H /C /I
+
+python -m pip uninstall -y shapely
+python -m pip cache remove shapely
+python -m pip install -v shapely --no-binary shapely
diff --git a/bin/build-linux-dist b/bin/build-linux-dist new file mode 100755 index 00000000..6893e3c1 --- /dev/null +++ b/bin/build-linux-dist @@ -0,0 +1,24 @@ +#!/usr/bin/env bash +# creating folder to install geos +mkdir $HOME/geos-build +GEOS_PATH=$HOME/geos-build +# Downloading geos +curl -O https://download.osgeo.org/geos/geos-3.12.1.tar.bz2 + +# uzipping geos +tar -xf geos-3.12.1.tar.bz2 +cd geos-3.12.1 +# Building geos +mkdir build && cd build && cmake -DCMAKE_INSTALL_PREFIX:PATH=$GEOS_PATH -DCMAKE_BUILD_TYPE=Release .. +make && make install + +export PATH=$GEOS_PATH/bin:$PATH +export GEOS_INCLUDE_PATH=$GEOS_PATH/include +export GEOS_LIBRARY_PATH=$GEOS_PATH/lib +export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$GEOS_PATH/lib +cd ../.. +python -m pip uninstall -y shapely +python -m pip cache remove shapely +python -m pip install -v shapely --no-binary shapely +make dist + |
