From 63b3524386ba4e1148b3782776bf8398421dd3d9 Mon Sep 17 00:00:00 2001 From: Tadej Novak Date: Sat, 11 Jan 2025 11:45:23 +0100 Subject: [PATCH] Update to Qt 6.8.1 --- .github/actions/qt6-build-legacy/Dockerfile | 5 +++ .github/actions/qt6-build-legacy/action.yml | 8 ++++ .../actions/qt6-build-legacy/entrypoint.sh | 30 +++++++++++++++ .github/actions/qt6-build/Dockerfile | 2 +- .github/actions/qt6-build/entrypoint.sh | 2 + .github/workflows/Android.yml | 21 +++++++++- .github/workflows/Linux.yml | 23 +++++++++-- .github/workflows/Windows.yml | 38 ++++++++++++++----- .github/workflows/iOS.yml | 14 ++++--- .github/workflows/macOS.yml | 16 +++++++- .github/workflows/source-tarball.yml | 7 +++- 11 files changed, 143 insertions(+), 23 deletions(-) create mode 100644 .github/actions/qt6-build-legacy/Dockerfile create mode 100644 .github/actions/qt6-build-legacy/action.yml create mode 100755 .github/actions/qt6-build-legacy/entrypoint.sh diff --git a/.github/actions/qt6-build-legacy/Dockerfile b/.github/actions/qt6-build-legacy/Dockerfile new file mode 100644 index 0000000..be972b5 --- /dev/null +++ b/.github/actions/qt6-build-legacy/Dockerfile @@ -0,0 +1,5 @@ +FROM ghcr.io/maplibre/linux-builder:centos8-gcc8 + +# Copy and set the entry point +COPY entrypoint.sh /entrypoint.sh +ENTRYPOINT ["/entrypoint.sh"] diff --git a/.github/actions/qt6-build-legacy/action.yml b/.github/actions/qt6-build-legacy/action.yml new file mode 100644 index 0000000..a7ca001 --- /dev/null +++ b/.github/actions/qt6-build-legacy/action.yml @@ -0,0 +1,8 @@ +# action.yml +name: "Qt6 Linux Builder (Legacy)" +description: "Helper action to build in a specific Docker container" +runs: + using: "docker" + image: "Dockerfile" + args: + - ${{ inputs.build-type }} diff --git a/.github/actions/qt6-build-legacy/entrypoint.sh b/.github/actions/qt6-build-legacy/entrypoint.sh new file mode 100755 index 0000000..ff0f8c4 --- /dev/null +++ b/.github/actions/qt6-build-legacy/entrypoint.sh @@ -0,0 +1,30 @@ +#!/bin/bash -l + +set -e +set -x + +export CCACHE_DIR="$GITHUB_WORKSPACE/.ccache" +export PATH="$QT_ROOT_DIR/bin:$PATH" +qmake --version + +# Main project +pushd source +cmake --workflow --preset Linux-CI +popd + +mkdir install && pushd install +tar xf ../build/qt6-Linux/maplibre-native-qt_*.tar.bz2 +mv maplibre-native-qt_* maplibre-native-qt +popd + +export QMapLibre_DIR="$(pwd)/install/maplibre-native-qt" + +# QtQuick example +pushd source/examples/quick +cmake --workflow --preset default +popd + +# QtWidgets example +pushd source/examples/widgets +cmake --workflow --preset default +popd diff --git a/.github/actions/qt6-build/Dockerfile b/.github/actions/qt6-build/Dockerfile index be972b5..63e7213 100644 --- a/.github/actions/qt6-build/Dockerfile +++ b/.github/actions/qt6-build/Dockerfile @@ -1,4 +1,4 @@ -FROM ghcr.io/maplibre/linux-builder:centos8-gcc8 +FROM ghcr.io/maplibre/linux-builder:centos8-gcc11 # Copy and set the entry point COPY entrypoint.sh /entrypoint.sh diff --git a/.github/actions/qt6-build/entrypoint.sh b/.github/actions/qt6-build/entrypoint.sh index ff0f8c4..be83cf1 100755 --- a/.github/actions/qt6-build/entrypoint.sh +++ b/.github/actions/qt6-build/entrypoint.sh @@ -1,5 +1,7 @@ #!/bin/bash -l +source /opt/rh/gcc-toolset-11/enable + set -e set -x diff --git a/.github/workflows/Android.yml b/.github/workflows/Android.yml index 2e3b2cd..9413ec2 100644 --- a/.github/workflows/Android.yml +++ b/.github/workflows/Android.yml @@ -82,6 +82,18 @@ jobs: - qt_version: 6.7.3 abi: arm64-v8a arch: android_arm64_v8a + - qt_version: 6.8.1 + abi: x86 + arch: android_x86 + - qt_version: 6.8.1 + abi: x86_64 + arch: android_x86_64 + - qt_version: 6.8.1 + abi: armeabi-v7a + arch: android_armv7 + - qt_version: 6.8.1 + abi: arm64-v8a + arch: android_arm64_v8a steps: - name: Checkout @@ -107,6 +119,11 @@ jobs: chmod +x "$QT_ROOT_DIR/bin/qt-cmake" sed -i "s/C:\/Qt\/Qt-${QT_VERSION}/\/usr\/local\/Qt-${QT_VERSION}/g" "$QT_ROOT_DIR/lib/cmake/Qt6BuildInternals/QtBuildInternalsExtra.cmake" + - name: Setup CMake + uses: jwlawson/actions-setup-cmake@v2 + with: + cmake-version: 3.30.x + - name: Set up OpenJDK 17 uses: actions/setup-java@v4 with: @@ -142,7 +159,7 @@ jobs: needs: build strategy: matrix: - qt_version: [6.5.3, 6.6.3, 6.7.3] + qt_version: [6.5.3, 6.6.3, 6.7.3, 6.8.1] steps: - name: Download artifacts for x86 @@ -215,7 +232,7 @@ jobs: contents: write strategy: matrix: - qt_version: [6.5.3, 6.6.3, 6.7.3] + qt_version: [6.5.3, 6.6.3, 6.7.3, 6.8.1] steps: - name: Download artifacts diff --git a/.github/workflows/Linux.yml b/.github/workflows/Linux.yml index 90c5fce..00902ed 100644 --- a/.github/workflows/Linux.yml +++ b/.github/workflows/Linux.yml @@ -65,7 +65,12 @@ jobs: preset: Linux-CI compiler: default - qt_series: 6 - qt_version: 6.7.3 + qt_version: 6.8.1 + qt_modules: qtlocation qtpositioning + preset: Linux-CI + compiler: default + - qt_series: 6 + qt_version: 6.8.1 qt_modules: qtlocation qtpositioning preset: Linux-coverage compiler: gcc-13 @@ -138,6 +143,12 @@ jobs: target: desktop modules: ${{ matrix.qt_modules }} + - name: Setup CMake + if: matrix.compiler != 'default' + uses: jwlawson/actions-setup-cmake@v2 + with: + cmake-version: 3.30.x + - name: Setup ninja if: matrix.compiler != 'default' uses: seanmiddleditch/gha-setup-ninja@v5 @@ -152,8 +163,12 @@ jobs: if: matrix.qt_series == 5 uses: ./source/.github/actions/qt5-build - - name: Build (Qt6) - if: matrix.qt_series == 6 && matrix.compiler == 'default' + - name: Build (Qt6, GCC8) + if: matrix.qt_series == 6 && matrix.compiler == 'default' && matrix.qt_version != '6.8.1' + uses: ./source/.github/actions/qt6-build-legacy + + - name: Build (Qt6, GCC11) + if: matrix.qt_series == 6 && matrix.compiler == 'default' && matrix.qt_version == '6.8.1' uses: ./source/.github/actions/qt6-build - name: Build (Qt6, custom compiler) @@ -225,7 +240,7 @@ jobs: contents: write strategy: matrix: - qt_version: [5.15.2, 6.5.3, 6.6.3, 6.7.3] + qt_version: [5.15.2, 6.5.3, 6.6.3, 6.7.3, 6.8.1] steps: - name: Download artifacts diff --git a/.github/workflows/Windows.yml b/.github/workflows/Windows.yml index 64db40a..2ef5668 100644 --- a/.github/workflows/Windows.yml +++ b/.github/workflows/Windows.yml @@ -45,7 +45,7 @@ env: jobs: build-and-test: name: Build (Qt${{ matrix.qt_version}}, ${{ matrix.arch }}) - runs-on: windows-2022 + runs-on: ${{ matrix.platform }} strategy: matrix: include: @@ -53,33 +53,41 @@ jobs: qt_version: 5.15.2 qt_arch: win64_msvc2019_64 qt_modules: "" + platform: windows-2019 arch: msvc2019_64 compiler: x64 - compiler_version: 14.29 preset: Windows-legacy-ccache - qt_series: 6 qt_version: 6.5.3 qt_arch: win64_msvc2019_64 qt_modules: qtlocation qtpositioning + platform: windows-2019 arch: msvc2019_64 compiler: x64 - compiler_version: 14.29 preset: Windows-ccache - qt_series: 6 qt_version: 6.6.3 qt_arch: win64_msvc2019_64 qt_modules: qtlocation qtpositioning + platform: windows-2019 arch: msvc2019_64 compiler: x64 - compiler_version: 14.29 preset: Windows-ccache - qt_series: 6 qt_version: 6.7.3 qt_arch: win64_msvc2019_64 qt_modules: qtlocation qtpositioning + platform: windows-2019 arch: msvc2019_64 compiler: x64 - compiler_version: 14.29 + preset: Windows-ccache + - qt_series: 6 + qt_version: 6.8.1 + qt_arch: win64_msvc2022_64 + qt_modules: qtlocation qtpositioning + platform: windows-2022 + arch: msvc2022_64 + compiler: x64 preset: Windows-ccache env: @@ -109,15 +117,18 @@ jobs: arch: ${{ matrix.qt_arch }} modules: ${{ matrix.qt_modules }} + - name: Setup CMake + uses: jwlawson/actions-setup-cmake@v2 + with: + cmake-version: 3.30.x + - name: Setup ninja uses: seanmiddleditch/gha-setup-ninja@v5 - name: Setup MSVC - if: matrix.qt_arch == 'win64_msvc2019_64' uses: ilammy/msvc-dev-cmd@v1 with: arch: ${{ matrix.compiler }} - toolset: ${{ matrix.compiler_version }} - name: Update ccache run: | @@ -182,8 +193,17 @@ jobs: contents: write strategy: matrix: - qt_version: [5.15.2, 6.5.3, 6.6.3, 6.7.3] - arch: [msvc2019_64] + include: + - qt_version: 5.15.2 + arch: msvc2019_64 + - qt_version: 6.5.3 + arch: msvc2019_64 + - qt_version: 6.6.3 + arch: msvc2019_64 + - qt_version: 6.7.3 + arch: msvc2019_64 + - qt_version: 6.8.1 + arch: msvc2022_64 steps: - name: Download artifacts diff --git a/.github/workflows/iOS.yml b/.github/workflows/iOS.yml index e4b957b..8a3305f 100644 --- a/.github/workflows/iOS.yml +++ b/.github/workflows/iOS.yml @@ -52,6 +52,8 @@ jobs: preset: iOS - qt_version: 6.7.3 preset: iOS + - qt_version: 6.8.1 + preset: iOS env: PRESET: ${{ matrix.preset }} @@ -71,13 +73,15 @@ jobs: brew uninstall google-chrome sudo rm -rf /Users/runner/Library/Android sudo rm -rf /Applications/Xcode_14* - sudo rm -rf /Applications/Xcode_15.0* - sudo rm -rf /Applications/Xcode_15.1* - sudo rm -rf /Applications/Xcode_15.2* - sudo rm -rf /Applications/Xcode_15.3* + sudo rm -rf /Applications/Xcode_15* ls /Applications df -h + - name: Setup CMake + uses: jwlawson/actions-setup-cmake@v2 + with: + cmake-version: 3.30.x + - name: Setup Xcode uses: maxim-lobanov/setup-xcode@v1 with: @@ -115,7 +119,7 @@ jobs: contents: write strategy: matrix: - qt_version: [6.5.3, 6.6.3, 6.7.3] + qt_version: [6.5.3, 6.6.3, 6.7.3, 6.8.1] steps: - name: Download artifacts diff --git a/.github/workflows/macOS.yml b/.github/workflows/macOS.yml index 9211c0a..e587f74 100644 --- a/.github/workflows/macOS.yml +++ b/.github/workflows/macOS.yml @@ -76,7 +76,13 @@ jobs: compiler: static runs_on: macos-14 - qt_series: 6 - qt_version: 6.7.3 + qt_version: 6.8.1 + qt_modules: qtlocation qtpositioning + preset: macOS-ccache + compiler: default + runs_on: macos-14 + - qt_series: 6 + qt_version: 6.8.1 qt_modules: qtlocation qtpositioning preset: macOS-clang-tidy compiler: llvm @@ -131,6 +137,11 @@ jobs: echo "$PWD/Qt/$QT_VERSION/macos_static/bin" >> $GITHUB_PATH cd $GITHUB_WORKSPACE + - name: Setup CMake + uses: jwlawson/actions-setup-cmake@v2 + with: + cmake-version: 3.30.x + - name: Setup ninja uses: seanmiddleditch/gha-setup-ninja@v5 @@ -204,6 +215,9 @@ jobs: - qt_version: 6.7.3 compiler: static suffix: "_static" + - qt_version: 6.8.1 + compiler: default + suffix: "" steps: - name: Download artifacts diff --git a/.github/workflows/source-tarball.yml b/.github/workflows/source-tarball.yml index e6ebf51..638a4ab 100644 --- a/.github/workflows/source-tarball.yml +++ b/.github/workflows/source-tarball.yml @@ -58,11 +58,16 @@ jobs: uses: jurplel/install-qt-action@v4 with: aqtversion: ==3.1.* - version: 6.7.3 + version: 6.8.1 dir: ${{ github.workspace }} target: desktop modules: qtlocation qtpositioning + - name: Setup CMake + uses: jwlawson/actions-setup-cmake@v2 + with: + cmake-version: 3.30.x + - name: Build run: | mkdir build && cd build