5353 # ## Determine platforms to include
5454 # ##
5555
56- select :
57- name : ' Select platforms '
56+ prepare :
57+ name : ' Prepare the run '
5858 runs-on : ubuntu-22.04
5959 outputs :
6060 linux-x64 : ${{ steps.include.outputs.linux-x64 }}
6767 windows-aarch64 : ${{ steps.include.outputs.windows-aarch64 }}
6868
6969 steps :
70- # This function must be inlined in main.yml, or we'd be forced to checkout the repo
70+ - name : ' Checkout the scripts'
71+ uses : actions/checkout@v4
72+ with :
73+ sparse-checkout : |
74+ .github
75+ make/conf/github-actions.conf
76+
77+ - name : ' Build JTReg'
78+ id : jtreg
79+ uses : ./.github/actions/build-jtreg
80+
81+ # TODO: Now that we are checking out the repo scripts, we can put the following code
82+ # into a separate file
7183 - name : ' Check what jobs to run'
7284 id : include
7385 run : |
@@ -123,18 +135,18 @@ jobs:
123135
124136 build-linux-x64 :
125137 name : linux-x64
126- needs : select
138+ needs : prepare
127139 uses : ./.github/workflows/build-linux.yml
128140 with :
129141 platform : linux-x64
130142 gcc-major-version : ' 10'
131143 configure-arguments : ${{ github.event.inputs.configure-arguments }}
132144 make-arguments : ${{ github.event.inputs.make-arguments }}
133- if : needs.select .outputs.linux-x64 == 'true'
145+ if : needs.prepare .outputs.linux-x64 == 'true'
134146
135147 build-linux-x86-hs :
136148 name : linux-x86-hs
137- needs : select
149+ needs : prepare
138150 uses : ./.github/workflows/build-linux.yml
139151 with :
140152 platform : linux-x86
@@ -148,11 +160,11 @@ jobs:
148160 extra-conf-options : ' --with-target-bits=32'
149161 configure-arguments : ${{ github.event.inputs.configure-arguments }}
150162 make-arguments : ${{ github.event.inputs.make-arguments }}
151- if : needs.select .outputs.linux-x86-hs == 'true'
163+ if : needs.prepare .outputs.linux-x86-hs == 'true'
152164
153165 build-linux-x64-hs-nopch :
154166 name : linux-x64-hs-nopch
155- needs : select
167+ needs : prepare
156168 uses : ./.github/workflows/build-linux.yml
157169 with :
158170 platform : linux-x64
@@ -162,11 +174,11 @@ jobs:
162174 extra-conf-options : ' --disable-precompiled-headers'
163175 configure-arguments : ${{ github.event.inputs.configure-arguments }}
164176 make-arguments : ${{ github.event.inputs.make-arguments }}
165- if : needs.select .outputs.linux-x64-variants == 'true'
177+ if : needs.prepare .outputs.linux-x64-variants == 'true'
166178
167179 build-linux-x64-hs-zero :
168180 name : linux-x64-hs-zero
169- needs : select
181+ needs : prepare
170182 uses : ./.github/workflows/build-linux.yml
171183 with :
172184 platform : linux-x64
@@ -176,11 +188,11 @@ jobs:
176188 extra-conf-options : ' --with-jvm-variants=zero --disable-precompiled-headers'
177189 configure-arguments : ${{ github.event.inputs.configure-arguments }}
178190 make-arguments : ${{ github.event.inputs.make-arguments }}
179- if : needs.select .outputs.linux-x64-variants == 'true'
191+ if : needs.prepare .outputs.linux-x64-variants == 'true'
180192
181193 build-linux-x64-hs-minimal :
182194 name : linux-x64-hs-minimal
183- needs : select
195+ needs : prepare
184196 uses : ./.github/workflows/build-linux.yml
185197 with :
186198 platform : linux-x64
@@ -190,11 +202,11 @@ jobs:
190202 extra-conf-options : ' --with-jvm-variants=minimal --disable-precompiled-headers'
191203 configure-arguments : ${{ github.event.inputs.configure-arguments }}
192204 make-arguments : ${{ github.event.inputs.make-arguments }}
193- if : needs.select .outputs.linux-x64-variants == 'true'
205+ if : needs.prepare .outputs.linux-x64-variants == 'true'
194206
195207 build-linux-x64-hs-optimized :
196208 name : linux-x64-hs-optimized
197- needs : select
209+ needs : prepare
198210 uses : ./.github/workflows/build-linux.yml
199211 with :
200212 platform : linux-x64
@@ -205,58 +217,57 @@ jobs:
205217 extra-conf-options : ' --with-debug-level=optimized --disable-precompiled-headers'
206218 configure-arguments : ${{ github.event.inputs.configure-arguments }}
207219 make-arguments : ${{ github.event.inputs.make-arguments }}
208- if : needs.select .outputs.linux-x64-variants == 'true'
220+ if : needs.prepare .outputs.linux-x64-variants == 'true'
209221
210222 build-linux-cross-compile :
211223 name : linux-cross-compile
212- needs :
213- - select
224+ needs : prepare
214225 uses : ./.github/workflows/build-cross-compile.yml
215226 with :
216227 gcc-major-version : ' 10'
217228 configure-arguments : ${{ github.event.inputs.configure-arguments }}
218229 make-arguments : ${{ github.event.inputs.make-arguments }}
219- if : needs.select .outputs.linux-cross-compile == 'true'
230+ if : needs.prepare .outputs.linux-cross-compile == 'true'
220231
221232 build-macos-x64 :
222233 name : macos-x64
223- needs : select
234+ needs : prepare
224235 uses : ./.github/workflows/build-macos.yml
225236 with :
226237 platform : macos-x64
227238 runs-on : ' macos-13'
228239 xcode-toolset-version : ' 14.3.1'
229240 configure-arguments : ${{ github.event.inputs.configure-arguments }}
230241 make-arguments : ${{ github.event.inputs.make-arguments }}
231- if : needs.select .outputs.macos-x64 == 'true'
242+ if : needs.prepare .outputs.macos-x64 == 'true'
232243
233244 build-macos-aarch64 :
234245 name : macos-aarch64
235- needs : select
246+ needs : prepare
236247 uses : ./.github/workflows/build-macos.yml
237248 with :
238249 platform : macos-aarch64
239250 runs-on : ' macos-14'
240251 xcode-toolset-version : ' 15.4'
241252 configure-arguments : ${{ github.event.inputs.configure-arguments }}
242253 make-arguments : ${{ github.event.inputs.make-arguments }}
243- if : needs.select .outputs.macos-aarch64 == 'true'
254+ if : needs.prepare .outputs.macos-aarch64 == 'true'
244255
245256 build-windows-x64 :
246257 name : windows-x64
247- needs : select
258+ needs : prepare
248259 uses : ./.github/workflows/build-windows.yml
249260 with :
250261 platform : windows-x64
251262 msvc-toolset-version : ' 14.29'
252263 msvc-toolset-architecture : ' x86.x64'
253264 configure-arguments : ${{ github.event.inputs.configure-arguments }}
254265 make-arguments : ${{ github.event.inputs.make-arguments }}
255- if : needs.select .outputs.windows-x64 == 'true'
266+ if : needs.prepare .outputs.windows-x64 == 'true'
256267
257268 build-windows-aarch64 :
258269 name : windows-aarch64
259- needs : select
270+ needs : prepare
260271 uses : ./.github/workflows/build-windows.yml
261272 with :
262273 platform : windows-aarch64
@@ -266,7 +277,7 @@ jobs:
266277 extra-conf-options : ' --openjdk-target=aarch64-unknown-cygwin'
267278 configure-arguments : ${{ github.event.inputs.configure-arguments }}
268279 make-arguments : ${{ github.event.inputs.make-arguments }}
269- if : needs.select .outputs.windows-aarch64 == 'true'
280+ if : needs.prepare .outputs.windows-aarch64 == 'true'
270281
271282 # ##
272283 # ## Test jobs
0 commit comments