@@ -3,10 +3,10 @@ name: Build Cemu
3
3
on :
4
4
workflow_call :
5
5
inputs :
6
- deploymode :
6
+ next_version_major :
7
7
required : false
8
8
type : string
9
- experimentalversion :
9
+ next_version_minor :
10
10
required : false
11
11
type : string
12
12
@@ -24,25 +24,17 @@ jobs:
24
24
submodules : " recursive"
25
25
fetch-depth : 0
26
26
27
- - name : Setup release mode parameters (for deploy)
28
- if : ${{ inputs.deploymode == 'release' }}
27
+ - name : Setup release mode parameters
29
28
run : |
30
29
echo "BUILD_MODE=release" >> $GITHUB_ENV
31
30
echo "BUILD_FLAGS=" >> $GITHUB_ENV
32
31
echo "Build mode is release"
33
32
34
- - name : Setup debug mode parameters ( for continous build)
35
- if : ${{ inputs.deploymode != 'release ' }}
33
+ - name : Setup build flags for version
34
+ if : ${{ inputs.next_version_major != '' }}
36
35
run : |
37
- echo "BUILD_MODE=debug" >> $GITHUB_ENV
38
- echo "BUILD_FLAGS=" >> $GITHUB_ENV
39
- echo "Build mode is debug"
40
-
41
- - name : Setup version for experimental
42
- if : ${{ inputs.experimentalversion != '' }}
43
- run : |
44
- echo "[INFO] Experimental version ${{ inputs.experimentalversion }}"
45
- echo "BUILD_FLAGS=${{ env.BUILD_FLAGS }} -DEXPERIMENTAL_VERSION=${{ inputs.experimentalversion }}" >> $GITHUB_ENV
36
+ echo "[INFO] Version ${{ inputs.next_version_major }}.${{ inputs.next_version_minor }}"
37
+ echo "BUILD_FLAGS=${{ env.BUILD_FLAGS }} -DEMULATOR_VERSION_MAJOR=${{ inputs.next_version_major }} -DEMULATOR_VERSION_MINOR=${{ inputs.next_version_minor }}" >> $GITHUB_ENV
46
38
47
39
- name : " Install system dependencies"
48
40
run : |
@@ -81,12 +73,10 @@ jobs:
81
73
cmake --build build
82
74
83
75
- name : Prepare artifact
84
- if : ${{ inputs.deploymode == 'release' }}
85
76
run : mv bin/Cemu_release bin/Cemu
86
77
87
78
- name : Upload artifact
88
79
uses : actions/upload-artifact@v4
89
- if : ${{ inputs.deploymode == 'release' }}
90
80
with :
91
81
name : cemu-bin-linux-x64
92
82
path : ./bin/Cemu
@@ -128,24 +118,17 @@ jobs:
128
118
with :
129
119
submodules : " recursive"
130
120
131
- - name : Setup release mode parameters (for deploy)
132
- if : ${{ inputs.deploymode == 'release' }}
121
+ - name : Setup release mode parameters
133
122
run : |
134
123
echo "BUILD_MODE=release" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append
135
124
echo "BUILD_FLAGS=" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append
136
125
echo "Build mode is release"
137
-
138
- - name : Setup debug mode parameters (for continous build)
139
- if : ${{ inputs.deploymode != 'release' }}
140
- run : |
141
- echo "BUILD_MODE=debug" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append
142
- echo "BUILD_FLAGS=" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append
143
- echo "Build mode is debug"
144
- - name : Setup version for experimental
145
- if : ${{ inputs.experimentalversion != '' }}
126
+
127
+ - name : Setup build flags for version
128
+ if : ${{ inputs.next_version_major != '' }}
146
129
run : |
147
- echo "[INFO] Experimental version ${{ inputs.experimentalversion }}"
148
- echo "BUILD_FLAGS=${{ env.BUILD_FLAGS }} -DEXPERIMENTAL_VERSION =${{ inputs.experimentalversion }}" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append
130
+ echo "[INFO] Version ${{ inputs.next_version_major }}. ${{ inputs.next_version_minor }}"
131
+ echo "BUILD_FLAGS=${{ env.BUILD_FLAGS }} -DEMULATOR_VERSION_MAJOR =${{ inputs.next_version_major }} -DEMULATOR_VERSION_MINOR=${{ inputs.next_version_minor }}" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append
149
132
150
133
- name : " Setup cmake"
151
134
uses : jwlawson/actions-setup-cmake@v2
@@ -184,12 +167,10 @@ jobs:
184
167
cmake --build . --config ${{ env.BUILD_MODE }}
185
168
186
169
- name : Prepare artifact
187
- if : ${{ inputs.deploymode == 'release' }}
188
170
run : Rename-Item bin/Cemu_release.exe Cemu.exe
189
171
190
172
- name : Upload artifact
191
173
uses : actions/upload-artifact@v4
192
- if : ${{ inputs.deploymode == 'release' }}
193
174
with :
194
175
name : cemu-bin-windows-x64
195
176
path : ./bin/Cemu.exe
@@ -202,24 +183,17 @@ jobs:
202
183
with :
203
184
submodules : " recursive"
204
185
205
- - name : Setup release mode parameters (for deploy)
206
- if : ${{ inputs.deploymode == 'release' }}
186
+ - name : Setup release mode parameters
207
187
run : |
208
188
echo "BUILD_MODE=release" >> $GITHUB_ENV
209
189
echo "BUILD_FLAGS=" >> $GITHUB_ENV
210
190
echo "Build mode is release"
211
- - name : Setup debug mode parameters (for continous build)
212
- if : ${{ inputs.deploymode != 'release' }}
213
- run : |
214
- echo "BUILD_MODE=debug" >> $GITHUB_ENV
215
- echo "BUILD_FLAGS=" >> $GITHUB_ENV
216
- echo "Build mode is debug"
217
-
218
- - name : Setup version for experimental
219
- if : ${{ inputs.experimentalversion != '' }}
191
+
192
+ - name : Setup build flags for version
193
+ if : ${{ inputs.next_version_major != '' }}
220
194
run : |
221
- echo "[INFO] Experimental version ${{ inputs.experimentalversion }}"
222
- echo "BUILD_FLAGS=${{ env.BUILD_FLAGS }} -DEXPERIMENTAL_VERSION =${{ inputs.experimentalversion }}" >> $GITHUB_ENV
195
+ echo "[INFO] Version ${{ inputs.next_version_major }}. ${{ inputs.next_version_minor }}"
196
+ echo "BUILD_FLAGS=${{ env.BUILD_FLAGS }} -DEMULATOR_VERSION_MAJOR =${{ inputs.next_version_major }} -DEMULATOR_VERSION_MINOR=${{ inputs.next_version_minor }}" >> $GITHUB_ENV
223
197
224
198
- name : " Install system dependencies"
225
199
run : |
@@ -275,7 +249,6 @@ jobs:
275
249
cmake --build build
276
250
277
251
- name : Prepare artifact
278
- if : ${{ inputs.deploymode == 'release' }}
279
252
run : |
280
253
mkdir bin/Cemu_app
281
254
mv bin/Cemu_release.app bin/Cemu_app/Cemu.app
@@ -289,7 +262,6 @@ jobs:
289
262
290
263
- name : Upload artifact
291
264
uses : actions/upload-artifact@v4
292
- if : ${{ inputs.deploymode == 'release' }}
293
265
with :
294
266
name : cemu-bin-macos-x64
295
267
path : ./bin/Cemu.dmg
0 commit comments