Skip to content

Commit ff80d5f

Browse files
committed
macos: add macOS release build for AzPipelines
Add an incomplete build stage for macOS. ESRP is not yet enabled. Signed-off-by: Matthew John Cheetham <mjcheetham@outlook.com>
1 parent 2f30ca2 commit ff80d5f

1 file changed

Lines changed: 127 additions & 1 deletion

File tree

.azure-pipelines/release.yml

Lines changed: 127 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,9 @@ extends:
5555
- output: pipelineArtifact
5656
targetPath: '$(Build.ArtifactStagingDirectory)\payload'
5757
artifactName: 'win-x86_payload'
58+
- output: pipelineArtifact
59+
targetPath: '$(Build.ArtifactStagingDirectory)\symbols'
60+
artifactName: 'win-x86_symbols'
5861
- output: pipelineArtifact
5962
targetPath: '$(Build.ArtifactStagingDirectory)\installers'
6063
artifactName: 'win-x86_installers'
@@ -158,4 +161,127 @@ extends:
158161
# "toolName": "sign",
159162
# "toolVersion": "1.0"
160163
# }
161-
# ]
164+
# ]
165+
166+
- stage: macos
167+
displayName: 'macOS'
168+
jobs:
169+
- job: macos_x64_build
170+
displayName: 'macOS Build and Sign (x64)'
171+
pool:
172+
name: 'Azure Pipelines'
173+
image: macOS-latest
174+
os: macOS
175+
templateContext:
176+
outputs:
177+
- output: pipelineArtifact
178+
targetPath: '$(Build.ArtifactStagingDirectory)\payload'
179+
artifactName: 'osx-x64_payload'
180+
- output: pipelineArtifact
181+
targetPath: '$(Build.ArtifactStagingDirectory)\symbols'
182+
artifactName: 'osx-x64_symbols'
183+
- output: pipelineArtifact
184+
targetPath: '$(Build.ArtifactStagingDirectory)\installers'
185+
artifactName: 'osx-x64_installers'
186+
steps:
187+
- checkout: self
188+
- task: Bash@3
189+
displayName: 'Get version'
190+
inputs:
191+
targetType: inline
192+
script: |
193+
echo "##vso[task.setvariable variable=VERSION]$(cat ./VERSION)"
194+
- task: UseDotNet@2
195+
displayName: 'Use .NET 8 SDK'
196+
inputs:
197+
packageType: sdk
198+
version: '8.x'
199+
- task: Bash@3
200+
displayName: 'Build payload'
201+
inputs:
202+
targetType: filePath
203+
filePath: './src/macos/Installer.Mac/layout.sh'
204+
arguments: |
205+
--runtime="osx-x64" \
206+
--configuration="Release" \
207+
--output="$(Build.ArtifactStagingDirectory)/payload" \
208+
--symbol-output="$(Build.ArtifactStagingDirectory)/symbols"
209+
- task: Bash@3
210+
displayName: 'Build component package'
211+
inputs:
212+
targetType: filePath
213+
filePath: './src/macos/Installer.Mac/pack.sh'
214+
arguments: |
215+
--version="$(VERSION)" \
216+
--payload="$(Build.ArtifactStagingDirectory)/payload" \
217+
--output="$(Build.ArtifactStagingDirectory)/pkg"
218+
- task: Bash@3
219+
displayName: 'Build installer package'
220+
inputs:
221+
targetType: filePath
222+
filePath: './src/macos/Installer.Mac/dist.sh'
223+
arguments: |
224+
--version="$(VERSION)" \
225+
--runtime="osx-x64" \
226+
--package-path="$(Build.ArtifactStagingDirectory)/pkg" \
227+
--output="$(Build.ArtifactStagingDirectory)/installers"
228+
229+
- job: macos_arm64_build
230+
displayName: 'macOS Build and Sign (ARM64)'
231+
pool:
232+
name: 'Azure Pipelines'
233+
image: macOS-latest
234+
os: macOS
235+
templateContext:
236+
outputs:
237+
- output: pipelineArtifact
238+
targetPath: '$(Build.ArtifactStagingDirectory)\payload'
239+
artifactName: 'osx-arm64_payload'
240+
- output: pipelineArtifact
241+
targetPath: '$(Build.ArtifactStagingDirectory)\symbols'
242+
artifactName: 'osx-arm64_symbols'
243+
- output: pipelineArtifact
244+
targetPath: '$(Build.ArtifactStagingDirectory)\installers'
245+
artifactName: 'osx-arm64_installers'
246+
steps:
247+
- checkout: self
248+
- task: Bash@3
249+
displayName: 'Get version'
250+
inputs:
251+
targetType: inline
252+
script: |
253+
echo "##vso[task.setvariable variable=VERSION]$(cat ./VERSION)"
254+
- task: UseDotNet@2
255+
displayName: 'Use .NET 8 SDK'
256+
inputs:
257+
packageType: sdk
258+
version: '8.x'
259+
- task: Bash@3
260+
displayName: 'Build payload'
261+
inputs:
262+
targetType: filePath
263+
filePath: './src/macos/Installer.Mac/layout.sh'
264+
arguments: |
265+
--runtime="osx-arm64" \
266+
--configuration="Release" \
267+
--output="$(Build.ArtifactStagingDirectory)/payload" \
268+
--symbol-output="$(Build.ArtifactStagingDirectory)/symbols"
269+
- task: Bash@3
270+
displayName: 'Build component package'
271+
inputs:
272+
targetType: filePath
273+
filePath: './src/macos/Installer.Mac/pack.sh'
274+
arguments: |
275+
--version="$(VERSION)" \
276+
--payload="$(Build.ArtifactStagingDirectory)/payload" \
277+
--output="$(Build.ArtifactStagingDirectory)/pkg"
278+
- task: Bash@3
279+
displayName: 'Build installer package'
280+
inputs:
281+
targetType: filePath
282+
filePath: './src/macos/Installer.Mac/dist.sh'
283+
arguments: |
284+
--version="$(VERSION)" \
285+
--runtime="osx-arm64" \
286+
--package-path="$(Build.ArtifactStagingDirectory)/pkg" \
287+
--output="$(Build.ArtifactStagingDirectory)/installers"

0 commit comments

Comments
 (0)