Skip to content

Commit e4b2ad5

Browse files
Refactor
Windows CI is now built with ninja (debug build now possible) Dependencies handling does not require a second call of the entire cmake project
1 parent 7bd44c2 commit e4b2ad5

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+1261
-1252
lines changed

.github/workflows/qt5_6.yml

Lines changed: 11 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -126,9 +126,9 @@ jobs:
126126
- name: 👷 Build
127127
shell: bash
128128
run: |
129+
brew reinstall --formula cmake
129130
cmake --preset macos-${{ env.BUILD_TYPE }}
130-
cmake --build --preset macos-${{ env.BUILD_TYPE }} --parallel $(sysctl -n hw.ncpu)
131-
cd build; cpack
131+
cmake --build --preset macos-${{ env.BUILD_TYPE }} --target package --parallel $(sysctl -n hw.ncpu)
132132
env:
133133
BUILD_TYPE: ${{ inputs.event_name == 'pull_request' && 'debug' || 'release' }}
134134

@@ -149,7 +149,6 @@ jobs:
149149
name: 🪟 Windows x64
150150
runs-on: windows-2022
151151
env:
152-
VCINSTALLDIR: 'C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC'
153152
LIBJPEG_TURBO_VERSION: 3.0.1
154153
steps:
155154
- name: ⬇ Checkout
@@ -162,14 +161,14 @@ jobs:
162161
shell: bash
163162
run: tr -d '\n' < .version > temp && mv temp .version && echo -n "+PR${{ inputs.pull_request_number }}" >> .version
164163

165-
- name: 📥 Download and 💾 Cache DirectX SDK
164+
- name: 💾 Restore DirectX SDK (if available)
166165
uses: ethanjli/[email protected]
167166
with:
168167
url: https://download.microsoft.com/download/A/E/7/AE743F1F-632B-4809-87A9-AA1BB3458E31/DXSDK_Jun10.exe
169168
destination: .\installer\dxsdk-jun10.exe
170169
cache-key: dxsdk-jun10
171170

172-
- name: 📥 Download and 💾 Cache libjpeg-turbo
171+
- name: 💾 Restore libjpeg-turbo (if available)
173172
uses: ethanjli/[email protected]
174173
with:
175174
url: https://sourceforge.net/projects/libjpeg-turbo/files/${{ env.LIBJPEG_TURBO_VERSION }}/libjpeg-turbo-${{ env.LIBJPEG_TURBO_VERSION }}-vc64.exe
@@ -181,7 +180,7 @@ jobs:
181180
cmd.exe /c start /wait .\installer\libjpeg-turbo.exe /S
182181
cmd.exe /c start /wait .\installer\dxsdk-jun10.exe /U /F
183182
184-
- name: Install Vulkan SDK
183+
- name: 📥 Install Vulkan SDK
185184
if: ${{ inputs.qt_version == '6' }}
186185
uses: jakoch/[email protected]
187186
with:
@@ -199,14 +198,15 @@ jobs:
199198
cache-key-prefix: 'cache-qt-windows'
200199

201200
- name: 🛠️ Setup MSVC
202-
shell: cmd
203-
run: call "${{env.VCINSTALLDIR}}\Auxiliary\Build\vcvars64.bat"
201+
uses: ilammy/msvc-dev-cmd@v1
204202

205203
- name: 👷 Build
206-
shell: bash
204+
shell: cmd
207205
run: |
208-
cmake --preset windows-release
209-
cmake --build --preset windows-release --target package -- -nologo -v:m -maxcpucount
206+
cmake --preset windows-${{ env.BUILD_TYPE }}
207+
cmake --build --preset windows-${{ env.BUILD_TYPE }} --target package --parallel %NUMBER_OF_PROCESSORS%
208+
env:
209+
BUILD_TYPE: ${{ inputs.event_name == 'pull_request' && 'debug' || 'release' }}
210210

211211
- name: 📦 Upload
212212
if: ${{ inputs.publish || inputs.event_name == 'pull_request' }}
@@ -216,39 +216,3 @@ jobs:
216216
path: ${{ inputs.event_name == 'pull_request' && 'build/*.exe' || 'build/Hyperion-*' }}
217217
env:
218218
NAME: ${{ inputs.qt_version == '6' && 'windows_x64_qt6' || 'windows_x64' }}
219-
220-
#####################################
221-
###### Publish GitHub Releases ######
222-
#####################################
223-
224-
github_publish:
225-
name: 🚀 Publish GitHub Releases
226-
if: ${{ inputs.qt_version == '5' && inputs.publish }}
227-
needs: [Linux, macOS, windows]
228-
runs-on: ubuntu-latest
229-
steps:
230-
- name: ⬇ Checkout
231-
uses: actions/checkout@v4
232-
233-
- name: 🔧 Prepare
234-
run: |
235-
echo '::group::Generate environment variables from .version and tag'
236-
echo "TAG=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV
237-
echo "VERSION=$(tr -d '\n' < .version)" >> $GITHUB_ENV
238-
echo '::endgroup::'
239-
240-
- name: 💾 Artifact download
241-
uses: actions/[email protected]
242-
with:
243-
pattern: artifact-*
244-
path: all-artifacts
245-
246-
- name: 📦 Upload
247-
uses: softprops/action-gh-release@v2
248-
with:
249-
name: Hyperion ${{ env.VERSION }}
250-
tag_name: ${{ env.TAG }}
251-
files: "all-artifacts/**"
252-
draft: true
253-
env:
254-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)