@@ -8,13 +8,16 @@ variables:
8
8
# Turn this Powershell console into a developer powershell console.
9
9
# https://intellitect.com/enter-vsdevshell-powershell/
10
10
PWSH_DEV : |
11
- $installPath = &"C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe" -latest -property installationpath
12
- $devShell = &"C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe" -latest -find **\Microsoft.VisualStudio.DevShell.dll
13
- Import-Module $devShell
14
- Enter-VsDevShell -VsInstallPath $installPath -SkipAutomaticLocation -DevCmdArguments "-arch=amd64"
11
+ if ($env:Agent_OS -eq 'Windows_NT') {
12
+ $installPath = &"C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe" -latest -property installationpath
13
+ $devShell = &"C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe" -latest -find **\Microsoft.VisualStudio.DevShell.dll
14
+ Import-Module $devShell
15
+ Enter-VsDevShell -VsInstallPath $installPath -SkipAutomaticLocation -DevCmdArguments "-arch=amd64"
16
+ }
15
17
RAKUDO_CHECKOUT_TYPE : master
16
18
NQP_CHECKOUT_TYPE : " rev-$(Build.SourceVersion)-selfrepo"
17
19
MOAR_CHECKOUT_TYPE : downstream
20
+ INSTALL_DIR : install
18
21
19
22
stages :
20
23
- stage : Test
@@ -138,117 +141,65 @@ stages:
138
141
139
142
# Build MoarVM
140
143
- script : |
141
- perl Configure.pl --prefix=../install $(MOAR_OPTIONS)
142
- make install
144
+ perl Configure.pl --prefix=../$(INSTALL_DIR) $(MOAR_OPTIONS)
145
+ make -j2 install
143
146
workingDirectory: '$(Pipeline.Workspace)/MoarVM'
144
147
condition: and(succeeded(), ne( variables['Agent.OS'], 'Windows_NT' ), ne( variables['BACKEND'], 'JVM'))
145
148
displayName: Build MoarVM
146
149
- pwsh : |
147
150
${{ variables.PWSH_DEV }}
148
- perl Configure.pl --prefix=..\install $(MOAR_OPTIONS)
151
+ perl Configure.pl --prefix=..\$(INSTALL_DIR) $(MOAR_OPTIONS)
152
+ set CL=/MP
149
153
nmake install
150
154
failOnStderr: false
151
155
workingDirectory: '$(Pipeline.Workspace)/MoarVM'
152
156
condition: and(succeeded(), eq( variables['Agent.OS'], 'Windows_NT' ), ne( variables['BACKEND'], 'JVM'))
153
157
displayName: Build MoarVM (Windows)
154
158
155
159
# Build NQP
156
- - script : |
157
- perl Configure.pl --prefix=../install $(NQP_OPTIONS)
158
- make install
159
- workingDirectory: '$(Pipeline.Workspace)/nqp'
160
- condition: and(succeeded(), ne( variables['Agent.OS'], 'Windows_NT' ))
161
- displayName: Build NQP
162
160
- pwsh : |
163
161
${{ variables.PWSH_DEV }}
164
- perl Configure.pl --prefix=..\install $(NQP_OPTIONS)
165
- nmake install
166
- failOnStderr: false
162
+ perl Configure.pl --prefix=../$(INSTALL_DIR) $(NQP_OPTIONS) --make-install
167
163
workingDirectory: '$(Pipeline.Workspace)/nqp'
168
- condition: and( succeeded(), eq( variables['Agent.OS'], 'Windows_NT' ) )
169
- displayName: Build NQP (Windows)
164
+ condition: succeeded()
165
+ displayName: Build NQP
170
166
171
167
# Build Rakudo
172
- - script : |
173
- perl Configure.pl --prefix=../install $(RAKUDO_OPTIONS)
174
- make install
175
- workingDirectory: '$(Pipeline.Workspace)/rakudo'
176
- condition: and(succeeded(), ne( variables['Agent.OS'], 'Windows_NT' ))
177
- displayName: Build Rakudo
178
168
- pwsh : |
179
169
${{ variables.PWSH_DEV }}
180
- perl Configure.pl --prefix=..\install $(RAKUDO_OPTIONS)
181
- nmake install
182
- failOnStderr: false
170
+ perl Configure.pl --prefix=../$(INSTALL_DIR) $(RAKUDO_OPTIONS) --make-install
183
171
workingDirectory: '$(Pipeline.Workspace)/rakudo'
184
- condition: and( succeeded(), eq( variables['Agent.OS'], 'Windows_NT' ) )
185
- displayName: Build Rakudo (Windows)
172
+ condition: succeeded()
173
+ displayName: Build Rakudo
186
174
187
175
# TODO: Should use "install moved" instead of "install-moved". But `prove` currently fails with an executable path that contains a space.
188
- - script : mv install install-moved
176
+ - pwsh : |
177
+ mv $(INSTALL_DIR) $(INSTALL_DIR)-moved
178
+ echo "##vso[task.setvariable variable=INSTALL_DIR]$(INSTALL_DIR)-moved"
189
179
workingDirectory: $(Pipeline.Workspace)
190
- condition : and(succeeded(), eq( variables['RELOCATABLE'], 'yes' ), ne( variables['Agent.OS'], 'Windows_NT' ) )
180
+ condition: and(succeeded(), eq( variables['RELOCATABLE'], 'yes' ) )
191
181
displayName: Move installation
192
- - pwsh : mv install install-moved
193
- workingDirectory : $(Pipeline.Workspace)
194
- condition : and(succeeded(), eq( variables['RELOCATABLE'], 'yes' ), eq( variables['Agent.OS'], 'Windows_NT' ) )
195
- displayName : Move installation (Windows)
196
182
197
183
# Test NQP
198
- - script : prove -j0 -r -e ../install /bin/nqp t/nqp t/hll t/qregex t/p5regex t/qast t/moar t/serialization t/nativecall t/concurrency
184
+ - script : prove -j2 -r -e ../$(INSTALL_DIR) /bin/nqp t/nqp t/hll t/qregex t/p5regex t/qast t/moar t/serialization t/nativecall t/concurrency
199
185
workingDirectory : ' $(Pipeline.Workspace)/nqp'
200
- condition : and(succeeded(), ne( variables['RELOCATABLE'], 'yes' ), ne( variables[' BACKEND'], 'JVM'), ne( variables['Agent.OS'], 'Windows_NT' ) )
186
+ condition : and(succeeded(), ne( variables['BACKEND'], 'JVM') )
201
187
displayName : Test NQP
202
- - pwsh : |
203
- ${{ variables.PWSH_DEV }}
204
- prove -j0 -r -e ..\install\bin\nqp t\nqp t\hll t\qregex t\p5regex t\qast t\moar t\serialization t\nativecall t\concurrency
188
+ - script : prove -j0 -r -e ../$(INSTALL_DIR)/bin/nqp t/nqp t/hll t/qregex t/p5regex t/qast t/jvm t/serialization t/nativecall
205
189
workingDirectory : ' $(Pipeline.Workspace)/nqp'
206
- condition: and(succeeded(), ne( variables['RELOCATABLE'], 'yes' ), ne( variables['BACKEND'], 'JVM'), eq( variables['Agent.OS'], 'Windows_NT' ) )
207
- displayName: Test NQP (Windows)
208
- - script : prove -j0 -r -e ../install/bin/nqp t/nqp t/hll t/qregex t/p5regex t/qast t/jvm t/serialization t/nativecall
209
- workingDirectory : ' $(Pipeline.Workspace)/nqp'
210
- condition : and(succeeded(), ne( variables['RELOCATABLE'], 'yes' ), eq( variables['BACKEND'], 'JVM'), ne( variables['Agent.OS'], 'Windows_NT' ) )
190
+ condition : and(succeeded(), eq( variables['BACKEND'], 'JVM') )
211
191
displayName : Test NQP (JVM)
212
- - pwsh : |
213
- ${{ variables.PWSH_DEV }}
214
- prove -j0 -r -e ..\install\bin\nqp t\nqp t\hll t\qregex t\p5regex t\qast t\jvm t\serialization t\nativecall
215
- workingDirectory: '$(Pipeline.Workspace)/nqp'
216
- condition: and( False, succeeded(), ne( variables['RELOCATABLE'], 'yes' ), eq( variables['BACKEND'], 'JVM'), eq( variables['Agent.OS'], 'Windows_NT' ) )
217
- displayName: Test NQP (Windows, JVM)
218
- - script : prove -j0 -r -e ../install-moved/bin/nqp t/nqp t/hll t/qregex t/p5regex t/qast t/moar t/serialization t/nativecall t/concurrency
219
- workingDirectory : ' $(Pipeline.Workspace)/nqp'
220
- condition : and(succeeded(), eq( variables['RELOCATABLE'], 'yes' ), ne( variables['BACKEND'], 'JVM'), ne( variables['Agent.OS'], 'Windows_NT' ) )
221
- displayName : Test NQP (relocated)
222
- - pwsh : |
223
- ${{ variables.PWSH_DEV }}
224
- prove -j0 -r -e ..\install-moved\bin\nqp t\nqp t\hll t\qregex t\p5regex t\qast t\moar t\serialization t\nativecall t\concurrency
225
- workingDirectory: '$(Pipeline.Workspace)/nqp'
226
- condition: and(succeeded(), eq( variables['RELOCATABLE'], 'yes' ), ne( variables['BACKEND'], 'JVM'), eq( variables['Agent.OS'], 'Windows_NT' ) )
227
- displayName: Test NQP (relocated, Windows)
228
192
229
193
# Test Rakudo
230
- - script : prove -e ../install/bin/perl6 -vlr t
231
- workingDirectory : ' $(Pipeline.Workspace)/rakudo'
232
- condition : and(succeeded(), ne( variables['RELOCATABLE'], 'yes' ), ne( variables['BACKEND'], 'JVM'), ne( variables['Agent.OS'], 'Windows_NT' ) )
233
- displayName : Test Rakudo
234
194
- pwsh : |
235
195
${{ variables.PWSH_DEV }}
236
- prove -e ..\install\bin\perl6 -vlr t
196
+ $install_path = Resolve-Path ../$(INSTALL_DIR)/bin/
197
+ prove -j2 -e "$($install_path.Path)raku" -vlr t
237
198
workingDirectory: '$(Pipeline.Workspace)/rakudo'
238
- condition: and(succeeded(), ne( variables['RELOCATABLE'], 'yes' ), ne( variables['BACKEND'], 'JVM'), eq( variables['Agent.OS'], 'Windows_NT' ) )
239
- displayName: Test Rakudo (Windows)
240
- - script : prove -e ../install-moved/bin/perl6 -vlr t
241
- workingDirectory : ' $(Pipeline.Workspace)/rakudo'
242
- condition : and(succeeded(), eq( variables['RELOCATABLE'], 'yes' ), ne( variables['BACKEND'], 'JVM'), ne( variables['Agent.OS'], 'Windows_NT' ) )
243
- displayName : Test Rakudo (relocated)
244
- - pwsh : |
245
- ${{ variables.PWSH_DEV }}
246
- prove -e ..\install-moved\bin\perl6 -vlr t
247
- workingDirectory: '$(Pipeline.Workspace)/rakudo'
248
- condition: and(succeeded(), eq( variables['RELOCATABLE'], 'yes' ), ne( variables['BACKEND'], 'JVM'), eq( variables['Agent.OS'], 'Windows_NT' ) )
249
- displayName: Test Rakudo (relocated, Windows)
199
+ condition: and(succeeded(), ne( variables['BACKEND'], 'JVM') )
200
+ displayName: Test Rakudo
250
201
251
- - publish : $(Pipeline.Workspace)/install-moved
202
+ - publish : $(Pipeline.Workspace)/$(INSTALL_DIR)
252
203
condition : and(succeeded(), eq( variables['RELOCATABLE'], 'yes' ), ne( variables['BACKEND'], 'JVM') )
253
204
displayName : Publish build artifact
254
205
0 commit comments