From a29b7a24376c8736c809df268517c01a323b0484 Mon Sep 17 00:00:00 2001 From: Charles Lechasseur Date: Wed, 10 Jul 2024 01:37:51 -0400 Subject: [PATCH 1/5] Update GitHub action versions, pin to hashes --- .github/workflows/main.yml | 29 ++++++++++++++--------------- 1 file changed, 14 insertions(+), 15 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 75e6f2a..a3afff4 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,25 +1,24 @@ name: CI -on: [ push, pull_request ] +on: [ push ] jobs: build: runs-on: windows-latest steps: - - uses: actions/checkout@v2 - - uses: microsoft/setup-msbuild@v1 - - name: Initialize CodeQL - uses: github/codeql-action/init@v1 - with: - languages: cpp + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 + - uses: microsoft/setup-msbuild@6fb02220983dee41ce7ae257b6f4d8f9bf5ed4ce # v2.0.0 + # - name: Initialize CodeQL + # uses: github/codeql-action/init@v1 + # with: + # languages: cpp - name: Cache NuGet packages - uses: actions/cache@v2 + uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2 with: path: packages - key: packages-v1-${{ hashFiles('**/packages.config') }} + key: packages-v4-${{ hashFiles('**/packages.config') }} restore-keys: | - packages-v1- - packages- + packages-v4- - name: Restore NuGet packages run: nuget restore - name: Build Debug Win32 @@ -30,12 +29,12 @@ jobs: run: msbuild /p:Platform=Win32 /p:Configuration=Release PathCopyCopy.sln - name: Build Release x64 run: msbuild /p:Platform=x64 /p:Configuration=Release PathCopyCopy.sln - - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v1 + # - name: Perform CodeQL Analysis + # uses: github/codeql-action/analyze@v1 - name: Build installer run: iscc /O+ /DSIGNCODE="no" /DDEVBUILD="yes" "Installer\Setup.iss" - name: Upload installer artifact - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@0b2256b8c012f0828dc542b3febcab082c67f72b # v4.3.4 with: name: installer - path: Installer/Output/ \ No newline at end of file + path: Installer/Output/ From f3613eb5414553bf0c0fa1588df76f5439eb16a1 Mon Sep 17 00:00:00 2001 From: Charles Lechasseur Date: Tue, 6 Jan 2026 23:44:40 -0500 Subject: [PATCH 2/5] chore: update to latest GitHub actions, remove CodeQL for now --- .github/workflows/main.yml | 31 +++++++++++++++++++------------ 1 file changed, 19 insertions(+), 12 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index a3afff4..d70fc01 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,19 +1,26 @@ name: CI -on: [ push ] +on: + push: + branches: + - main + pull_request: + +env: + CI: 1 jobs: build: - runs-on: windows-latest + runs-on: windows-2022 steps: - - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 - - uses: microsoft/setup-msbuild@6fb02220983dee41ce7ae257b6f4d8f9bf5ed4ce # v2.0.0 - # - name: Initialize CodeQL - # uses: github/codeql-action/init@v1 - # with: - # languages: cpp + - name: Checkout project code + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 + + - name: Setup MSBuild + uses: microsoft/setup-msbuild@6fb02220983dee41ce7ae257b6f4d8f9bf5ed4ce # v2.0.0 + - name: Cache NuGet packages - uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2 + uses: actions/cache@9255dc7a253b0ccc959486e2bca901246202afeb # v5.0.1 with: path: packages key: packages-v4-${{ hashFiles('**/packages.config') }} @@ -21,6 +28,7 @@ jobs: packages-v4- - name: Restore NuGet packages run: nuget restore + - name: Build Debug Win32 run: msbuild /p:Platform=Win32 /p:Configuration=Debug PathCopyCopy.sln - name: Build Debug x64 @@ -29,12 +37,11 @@ jobs: run: msbuild /p:Platform=Win32 /p:Configuration=Release PathCopyCopy.sln - name: Build Release x64 run: msbuild /p:Platform=x64 /p:Configuration=Release PathCopyCopy.sln - # - name: Perform CodeQL Analysis - # uses: github/codeql-action/analyze@v1 + - name: Build installer run: iscc /O+ /DSIGNCODE="no" /DDEVBUILD="yes" "Installer\Setup.iss" - name: Upload installer artifact - uses: actions/upload-artifact@0b2256b8c012f0828dc542b3febcab082c67f72b # v4.3.4 + uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0 with: name: installer path: Installer/Output/ From fd53dc7bd51fbbdb3095771b0582865549565216 Mon Sep 17 00:00:00 2001 From: Charles Lechasseur Date: Tue, 6 Jan 2026 23:48:57 -0500 Subject: [PATCH 3/5] chore: use windows-2025 runner --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index d70fc01..fcee526 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -11,7 +11,7 @@ env: jobs: build: - runs-on: windows-2022 + runs-on: windows-2025 steps: - name: Checkout project code uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 From a5ef1b18eb603e51cc7cc737847d5b2aab203260 Mon Sep 17 00:00:00 2001 From: Charles Lechasseur Date: Tue, 6 Jan 2026 23:58:16 -0500 Subject: [PATCH 4/5] chore: add steps to reinstall components required for ATL builds Copied from: https://github.com/actions/runner-images/issues/9701 --- .github/workflows/main.yml | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index fcee526..dea211e 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -19,6 +19,38 @@ jobs: - name: Setup MSBuild uses: microsoft/setup-msbuild@6fb02220983dee41ce7ae257b6f4d8f9bf5ed4ce # v2.0.0 + # Note: the following two steps are required to be able to do ATL builds on the new windows-2022+ runners. + # The code has been copied from https://github.com/actions/runner-images/issues/9701. + # It's not ideal as it adds quite a bit of time to the builds, so it might be interesting to find a + # workaround at some point in the future. + - name: Delete components + run: | + Set-Location "C:\Program Files (x86)\Microsoft Visual Studio\Installer\" + $InstallPath = "C:\Program Files\Microsoft Visual Studio\2022\Enterprise" + $componentsToRemove= @( + "Microsoft.VisualStudio.Component.VC.ATL.ARM" + "Microsoft.VisualStudio.Component.VC.ATL.ARM.Spectre" + ) + [string]$workloadArgs = $componentsToRemove | ForEach-Object {" --remove " + $_} + $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: Install components + run: | + Set-Location "C:\Program Files (x86)\Microsoft Visual Studio\Installer\" + $InstallPath = "C:\Program Files\Microsoft Visual Studio\2022\Enterprise" + $componentsToAdd= @( + "Microsoft.VisualStudio.Component.VC.14.39.17.9.ATL.ARM" + "Microsoft.VisualStudio.Component.VC.14.39.17.9.ATL.ARM.Spectre" + ) + [string]$workloadArgs = $componentsToAdd | 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: Cache NuGet packages uses: actions/cache@9255dc7a253b0ccc959486e2bca901246202afeb # v5.0.1 with: From 12cb5ca443f4308e530e7eb17de1c3ad27d22b63 Mon Sep 17 00:00:00 2001 From: Charles Lechasseur Date: Wed, 7 Jan 2026 00:14:58 -0500 Subject: [PATCH 5/5] chore: fix missing ATL components --- .github/workflows/main.yml | 26 +++++--------------------- 1 file changed, 5 insertions(+), 21 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index dea211e..03c7702 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -19,31 +19,15 @@ jobs: - name: Setup MSBuild uses: microsoft/setup-msbuild@6fb02220983dee41ce7ae257b6f4d8f9bf5ed4ce # v2.0.0 - # Note: the following two steps are required to be able to do ATL builds on the new windows-2022+ runners. - # The code has been copied from https://github.com/actions/runner-images/issues/9701. - # It's not ideal as it adds quite a bit of time to the builds, so it might be interesting to find a - # workaround at some point in the future. - - name: Delete components - run: | - Set-Location "C:\Program Files (x86)\Microsoft Visual Studio\Installer\" - $InstallPath = "C:\Program Files\Microsoft Visual Studio\2022\Enterprise" - $componentsToRemove= @( - "Microsoft.VisualStudio.Component.VC.ATL.ARM" - "Microsoft.VisualStudio.Component.VC.ATL.ARM.Spectre" - ) - [string]$workloadArgs = $componentsToRemove | ForEach-Object {" --remove " + $_} - $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: Install components + - name: Install missing ATL components run: | Set-Location "C:\Program Files (x86)\Microsoft Visual Studio\Installer\" $InstallPath = "C:\Program Files\Microsoft Visual Studio\2022\Enterprise" $componentsToAdd= @( - "Microsoft.VisualStudio.Component.VC.14.39.17.9.ATL.ARM" - "Microsoft.VisualStudio.Component.VC.14.39.17.9.ATL.ARM.Spectre" + "Microsoft.VisualStudio.Component.VC.14.29.16.11.ATL" + "Microsoft.VisualStudio.Component.VC.14.29.16.11.ATL.Spectre" + "Microsoft.VisualStudio.Component.VC.14.29.16.11.MFC" + "Microsoft.VisualStudio.Component.VC.14.29.16.11.MFC.Spectre" ) [string]$workloadArgs = $componentsToAdd | ForEach-Object {" --add " + $_} $Arguments = ('/c', "vs_installer.exe", 'modify', '--installPath', "`"$InstallPath`"",$workloadArgs, '--quiet', '--norestart', '--nocache')