From 0ac6248cc43898ca678233433b9b0d143f517641 Mon Sep 17 00:00:00 2001 From: Raul Metsma Date: Tue, 19 Jul 2022 14:39:53 +0300 Subject: [PATCH] Build only Burn installer with single arch IB-7146 Signed-off-by: Raul Metsma --- .github/workflows/cmake-windows.yml | 63 ++++------------------------- install/plugins.wxs | 13 +----- src/app/CMakeLists.txt | 9 ++--- 3 files changed, 13 insertions(+), 72 deletions(-) diff --git a/.github/workflows/cmake-windows.yml b/.github/workflows/cmake-windows.yml index a76ea90f..d4c9afbb 100644 --- a/.github/workflows/cmake-windows.yml +++ b/.github/workflows/cmake-windows.yml @@ -21,13 +21,13 @@ jobs: - arch: x64 qt: win64_msvc2017_64 - suffix: qt6 - qtver: 6.3.0 + qtver: 6.3.1 arch: x64 qt: win64_msvc2019_64 steps: - name: Checkout code - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: submodules: recursive @@ -35,7 +35,7 @@ jobs: uses: lukka/run-vcpkg@v7 with: vcpkgArguments: gtest openssl - vcpkgTriplet: ${{ matrix.arch }}-windows + vcpkgTriplet: ${{matrix.arch}}-windows vcpkgGitCommitId: 9b064ff07b987c8f213fdbf4358122fd4fe38ef1 - name: Install Qt @@ -60,66 +60,17 @@ jobs: run: | cmake --build build --config ${env:BUILD_TYPE} cmake --build build --config ${env:BUILD_TYPE} --target installer + cmake --build build --config ${env:BUILD_TYPE} --target bundle - name: Test if: matrix.arch == 'x64' run: ctest -V -C ${env:BUILD_TYPE} --test-dir build - name: Upload artifacts - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v3 with: - name: web-eid-app-windows-build-${{github.run_number}}-${{ matrix.suffix }} + name: web-eid-app-windows-build-${{github.run_number}}-${{matrix.suffix}} path: | build/src/app/*.msi - build/**/*.pdb - - bundle: - needs: build - runs-on: windows-2019 - steps: - - name: Checkout code - uses: actions/checkout@v2 - with: - submodules: recursive - - - name: Prepare vcpkg and libraries - uses: lukka/run-vcpkg@v7 - with: - vcpkgArguments: gtest openssl - vcpkgTriplet: x64-windows - vcpkgGitCommitId: 9b064ff07b987c8f213fdbf4358122fd4fe38ef1 - - - name: Install Qt - uses: jurplel/install-qt-action@v2 - with: - version: 5.12.12 - arch: win64_msvc2017_64 - - - name: Setup MS Visual C++ dev env - uses: ilammy/msvc-dev-cmd@v1 - with: - arch: x64 - toolset: 14.29 - - - name: Configure CMake - run: | - cmake "-GNinja" ` - "-DCMAKE_TOOLCHAIN_FILE=${{env.VCPKG_ROOT}}/scripts/buildsystems/vcpkg.cmake" ` - "-DCMAKE_BUILD_TYPE=${env:BUILD_TYPE}" -S . -B build - - - name: Download artifacts - uses: actions/download-artifact@v2 - with: - name: web-eid-app-windows-build-${{github.run_number}}-qt5 - path: build - - - name: Build - run: | - cmake --build build --config ${env:BUILD_TYPE} --target bundle - - - name: Upload artifacts - uses: actions/upload-artifact@v2 - with: - name: web-eid-app-windows-build-${{github.run_number}} - path: | build/src/app/*.exe + build/**/*.pdb diff --git a/install/plugins.wxs b/install/plugins.wxs index e9082130..03ddecc5 100644 --- a/install/plugins.wxs +++ b/install/plugins.wxs @@ -31,17 +31,8 @@ Key="SOFTWARE\Mozilla\NativeMessagingHosts\eu.webeid" Win64="yes"/> - - - - - - - - - + diff --git a/src/app/CMakeLists.txt b/src/app/CMakeLists.txt index 728a8d6d..d28386e9 100644 --- a/src/app/CMakeLists.txt +++ b/src/app/CMakeLists.txt @@ -27,8 +27,7 @@ if(WIN32) get_filename_component(SSL_PATH "${OPENSSL_INCLUDE_DIR}/../bin" ABSOLUTE) endif() set(WEBEID_PATH web-eid.exe) - set(BASE_FILE $_${PROJECT_VERSION}) - set(MSI_FILE ${BASE_FILE}.${PLATFORM}) + set(BASE_FILE $_${PROJECT_VERSION}.${PLATFORM}) list(APPEND CANDLE_CMD "$ENV{WIX}bin\\candle.exe" -nologo -arch ${PLATFORM} -dMSI_VERSION=${PROJECT_VERSION} -dPlatform=${PLATFORM} @@ -49,10 +48,10 @@ if(WIN32) ) add_custom_target(installer DEPENDS web-eid COMMAND ${CANDLE_CMD} - COMMAND ${LIGHT_CMD} -o "${MSI_FILE}.msi" + COMMAND ${LIGHT_CMD} -o "${BASE_FILE}.msi" #Build MSI with QT COMMAND ${CANDLE_CMD} -dqt_path=${qtCore_install_prefix} -dqt_version_major=${QT_VERSION_MAJOR} - COMMAND ${LIGHT_CMD} -o "${MSI_FILE}.qt.msi" + COMMAND ${LIGHT_CMD} -o "${BASE_FILE}.qt.msi" WORKING_DIRECTORY $ ) add_custom_target(bundle @@ -69,7 +68,7 @@ if(WIN32) COMMAND_EXPAND_LISTS ) add_custom_command(TARGET installer POST_BUILD - COMMAND ${SIGNCMD} "${MSI_FILE}.msi" "${MSI_FILE}.qt.msi" + COMMAND ${SIGNCMD} "${BASE_FILE}.msi" "${BASE_FILE}.qt.msi" WORKING_DIRECTORY $ ) add_custom_command(TARGET bundle POST_BUILD