diff --git a/.github/workflows/_build_and_package.yml b/.github/workflows/_build_and_package.yml index 8ac2b419..66648b12 100644 --- a/.github/workflows/_build_and_package.yml +++ b/.github/workflows/_build_and_package.yml @@ -5,33 +5,11 @@ on: jobs: - QC: - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v4 - - name: Set Environment Variables - uses: "./.github/workflows/setup" - - name: Quality Control - uses: "./.github/workflows/qc" - - Test: - needs: QC - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v4 - - name: Set Environment Variables - uses: "./.github/workflows/setup" - - name: "Test (Backend)" - uses: "./.github/workflows/test" - Build: - needs: Test strategy: fail-fast: false matrix: - os: [ubuntu-latest, windows-latest] + os: [windows-latest] runs-on: ${{ matrix.os }} steps: - name: Checkout @@ -46,7 +24,7 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-latest, windows-latest] + os: [windows-latest] runs-on: ${{ matrix.os }} steps: - name: Checkout diff --git a/.github/workflows/build/windows/action.yml b/.github/workflows/build/windows/action.yml index 16506979..b686f048 100644 --- a/.github/workflows/build/windows/action.yml +++ b/.github/workflows/build/windows/action.yml @@ -5,44 +5,61 @@ inputs: cacheOnly: type: boolean default: false + msvcVersion: + type: string + default: '19.44' + required: true runs: using: "composite" steps: - - name: Install Chocolatey Dependencies - shell: bash - run: choco install -y ninja - - uses: actions/setup-python@v5 with: - python-version: '3.11' + python-version: ${{ env.pythonVersion }} + +# - name: Install Downgraded MSVC +# shell: powershell +# run: | +# # For versions update see here: https://learn.microsoft.com/en-us/visualstudio/install/workload-component-id-vs-build-tools?view=vs-2022 +# Set-Location "C:\Program Files (x86)\Microsoft Visual Studio\Installer\" +# $InstallPath = "C:\Program Files\Microsoft Visual Studio\2022\Enterprise" +# $componentsToInstall= @( +# "Microsoft.VisualStudio.Component.VC.${{ inputs.msvcVersion }}.x86.x64" +# "Microsoft.VisualStudio.Component.VC.${{ inputs.msvcVersion }}.ATL" +# ) +# [string]$workloadArgs = $componentsToInstall | ForEach-Object {" --add " + $_} +# $Arguments = ('/c', "vs_installer.exe", 'modify', '--installPath', "`"$InstallPath`"",$workloadArgs, '--quiet', '--norestart', '--nocache') +# # should be run twice +# $process = Start-Process -FilePath cmd.exe -ArgumentList $Arguments -Wait -PassThru -WindowStyle Hidden +# $process = Start-Process -FilePath cmd.exe -ArgumentList $Arguments -Wait -PassThru -WindowStyle Hidden + + - name: Setup cmake + uses: jwlawson/actions-setup-cmake@v2 + with: + cmake-version: '3.x' - name: Install Python Dependencies shell: bash - run: pip3 install aqtinstall + run: pip3 install py7zr==1.1.0 aqtinstall conan - - name: Retrieve Qt Cache - id: cache-qt - uses: actions/cache@v4 - with: - key: windows-qt-${{ env.qtVersion }} - path: ${{ runner.temp }}\qt +# - name: Retrieve Qt Cache +# id: cache-qt +# uses: actions/cache@v4 +# with: +# key: windows-qt-${{ env.qtVersion }} +# path: ${{ runner.temp }}\qt - name: Install Qt - # if: ${{ steps.cache-qt.outputs.cache-hit != 'true' }} +# if: ${{ steps.cache-qt.outputs.cache-hit != 'true' }} shell: bash run: | aqt install-qt --outputdir ${RUNNER_TEMP}/qt windows desktop ${{ env.qtVersion }} win64_msvc2019_64 -m all - - name: Remove /usr/bin/link - shell: bash - run: | - echo "Removing /usr/bin/link.exe since it will conflict with our MSVC paths..." - rm -rf /usr/bin/link.exe - - name: Setup MSVC Compiler uses: ilammy/msvc-dev-cmd@v1 +# with: +# toolset: ${{ inputs.msvcVersion }} - name: Build Frontend shell: bash @@ -50,9 +67,15 @@ runs: cd frontend Qt6_DIR="${RUNNER_TEMP}\qt\${{ env.qtVersion }}\msvc2019_64" + export PATH="${Qt6_DIR}\bin;$PATH" + echo $Qt6_DIR + ls $Qt6_DIR + + mkdir build && cd build - cmake --preset ci-windows - cmake --build --preset build + cmake ../ -G Ninja -DCMAKE_C_COMPILER=cl -DCMAKE_CXX_COMPILER=cl + #cmake --preset ci-windows + #cmake --build --preset build - name: Deploy Runtime Libs shell: bash diff --git a/.github/workflows/setup/action.yml b/.github/workflows/setup/action.yml index b4c1bd21..525115dd 100644 --- a/.github/workflows/setup/action.yml +++ b/.github/workflows/setup/action.yml @@ -8,8 +8,8 @@ runs: shell: bash run: | set -ex - echo "pythonVersion=3.10" >> ${GITHUB_ENV} - echo "qtVersion=6.3.*" >> ${GITHUB_ENV} + echo "pythonVersion=3.11" >> ${GITHUB_ENV} + echo "qtVersion=6.4.2" >> ${GITHUB_ENV} - name: Get Code Version shell: bash