From af004988bd9b148074dc319a7b2443729d488aea Mon Sep 17 00:00:00 2001 From: Stefan Kebekus Date: Wed, 6 Dec 2023 07:56:17 +0100 Subject: [PATCH] Update actions --- .github/workflows/ios.yml | 32 ++++---------------------------- .gitmodules | 3 +++ buildscript-android.sh | 20 ++++++++++++++++++++ buildscript-ios.sh | 29 +++++++++++++++++++++++++++-- bzip2 | 1 + maplibre-native-qt | 2 +- 6 files changed, 56 insertions(+), 31 deletions(-) create mode 160000 bzip2 diff --git a/.github/workflows/ios.yml b/.github/workflows/ios.yml index 1902fdc..65c4047 100644 --- a/.github/workflows/ios.yml +++ b/.github/workflows/ios.yml @@ -31,36 +31,12 @@ jobs: - name: Install software run: | brew install cmake ninja - - name: Configure and compile zlib - run: | - $Qt6_DIR/bin/qt-cmake \ - -G Ninja \ - -S zlib \ - -B build-zlib-ios \ - -DCMAKE_OSX_ARCHITECTURES="arm64;x86_64" \ - -DCMAKE_INSTALL_PREFIX=ios - cmake --build build-zlib-ios - cmake --install build-zlib-ios - cp -rv ios/* $Qt6_DIR - - name: Configure and compile libzip - run: | - $Qt6_DIR/bin/qt-cmake \ - -G Ninja \ - -S libzip \ - -B build-libzip-ios \ - -DBUILD_DOC=OFF \ - -DBUILD_EXAMPLES=OFF \ - -DBUILD_REGRESS=OFF \ - -DBUILD_SHARED_LIBS=OFF \ - -DBUILD_TOOLS=OFF \ - -DCMAKE_OSX_ARCHITECTURES="arm64;x86_64" \ - -DCMAKE_PREFIX_PATH=ios \ - -DCMAKE_INSTALL_PREFIX=ios - cmake --build build-libzip-ios - cmake --install build-libzip-ios + - name: Compile and Install + run: | + Qt6_DIR_BASE=$(dirname "$Qt6_DIR") ./buildscript-linux.sh - name: Package run: | - tar cvfz enrouteDependencies_ios.tar.gz ios + tar cvfz enrouteDependencies_ios.tar.gz Qt - name: Upload to developerBuilds run: | gh release upload --clobber developerBuilds *.tar.gz diff --git a/.gitmodules b/.gitmodules index bf529ba..247a041 100644 --- a/.gitmodules +++ b/.gitmodules @@ -7,3 +7,6 @@ [submodule "zlib"] path = zlib url = https://github.com/madler/zlib.git +[submodule "bzip2"] + path = bzip2 + url = https://gitlab.com/bzip2/bzip2.git diff --git a/buildscript-android.sh b/buildscript-android.sh index f631b29..252add4 100755 --- a/buildscript-android.sh +++ b/buildscript-android.sh @@ -6,6 +6,26 @@ set -e for PLATFORM in android_armv7 android_arm64_v8a android_x86 android_x86_64 do + echo + echo "libzip - static for arm64 and x86_64 on iOS" + + $Qt6_DIR_BASE/$PLATFORM/bin/qt-cmake \ + -G Ninja \ + -S libzip \ + -B build-libzip-$PLATFORM \ + -DBUILD_DOC=OFF \ + -DBUILD_EXAMPLES=OFF \ + -DBUILD_REGRESS=OFF \ + -DBUILD_SHARED_LIBS=OFF \ + -DBUILD_TOOLS=OFF \ + -DENABLE_BZIP2=OFF \ + -DENABLE_LZMA=OFF \ + -DENABLE_ZSTD=OFF \ + -DCMAKE_INSTALL_PREFIX=$Qt6_DIR_BASE/$PLATFORM + cmake --build build-libzip-$PLATFORM + cmake --install build-libzip-$PLATFORM + + echo echo "Android ARMv7" diff --git a/buildscript-ios.sh b/buildscript-ios.sh index b845c41..5b32446 100755 --- a/buildscript-ios.sh +++ b/buildscript-ios.sh @@ -2,6 +2,24 @@ # Fail on first error set -e +installDir=Qt/$(basename "$Qt6_DIR_BASE")/ios + + +echo +echo "bzip2 - static for arm64 and x86_64 on iOS" + +$Qt6_DIR_BASE/ios/bin/qt-cmake \ + -G Ninja \ + -S bzip2 \ + -B build-bzip2-iOS \ + -DENABLE_APP=OFF \ + -DENABLE_DOCS=OFF \ + -DENABLE_SHARED_LIB=OFF \ + -DENABLE_STATIC_LIB=ON \ + -DCMAKE_OSX_ARCHITECTURES="arm64;x86_64" \ + -DCMAKE_INSTALL_PREFIX=$installDir +cmake --build build-bzip2-iOS +cmake --install build-bzip2-iOS echo @@ -12,10 +30,17 @@ $Qt6_DIR_BASE/ios/bin/qt-cmake \ -S zlib \ -B build-zlib-iOS \ -DCMAKE_OSX_ARCHITECTURES="arm64;x86_64" \ - -DCMAKE_INSTALL_PREFIX=$Qt6_DIR_BASE/ios + -DCMAKE_INSTALL_PREFIX=$installDir cmake --build build-zlib-iOS cmake --install build-zlib-iOS + +echo +echo "copy static bzip2 and zlib to development directory, so cmake can find it" + +cp -rv $installDir $Qt6_DIR_BASE + + echo echo "libzip - static for arm64 and x86_64 on iOS" @@ -32,6 +57,6 @@ $Qt6_DIR_BASE/ios/bin/qt-cmake \ -DENABLE_LZMA=OFF \ -DENABLE_ZSTD=OFF \ -DCMAKE_OSX_ARCHITECTURES="arm64;x86_64" \ - -DCMAKE_INSTALL_PREFIX=$Qt6_DIR_BASE/ios + -DCMAKE_INSTALL_PREFIX=$installDir cmake --build build-libzip-iOS cmake --install build-libzip-iOS diff --git a/bzip2 b/bzip2 new file mode 160000 index 0000000..6a8690f --- /dev/null +++ b/bzip2 @@ -0,0 +1 @@ +Subproject commit 6a8690fc8d26c815e798c588f796eabe9d684cf0 diff --git a/maplibre-native-qt b/maplibre-native-qt index 3f29481..80fe60e 160000 --- a/maplibre-native-qt +++ b/maplibre-native-qt @@ -1 +1 @@ -Subproject commit 3f294817b4a003a24f65df00c81cd32ce692fc12 +Subproject commit 80fe60eb967851514cd4cdd9d168e961fc290733