/
Matrix-Build-Job.yml
83 lines (76 loc) · 2.46 KB
/
Matrix-Build-Job.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
## @file
# Template file for generating a build job matrix for the packages currently supported for
# build in Mu Plus.
#
# Copyright (c) Microsoft Corporation.
# Copyright (c) 2020 - 2021, ARM Limited. All rights reserved.<BR>
# SPDX-License-Identifier: BSD-2-Clause-Patent
##
parameters:
- name: arch_list
displayName: Architectures (e.g. IA32, X64)
type: string
default: ''
- name: extra_build_args
displayName: Extra Build Command Arguments
type: string
default: ''
- name: extra_install_step
displayName: Extra Install Steps
type: stepList
default:
- script: echo No extra steps provided
- name: tool_chain_tag
displayName: Tool Chain (e.g. VS2022)
type: string
default: ''
- name: vm_image
displayName: Virtual Machine Image (e.g. windows-latest)
type: string
default: 'windows-latest'
- name: container_image
displayName: Container Image
type: string
default: ''
jobs:
- job: Build
timeoutInMinutes: 120
# Use matrix to speed up the build process
strategy:
matrix:
TARGET_DFCI_ZERO_XML:
Build.Pkgs: 'DfciPkg,ZeroTouchPkg,XmlSupportPkg,MfciPkg'
Build.Targets: 'DEBUG,RELEASE,NO-TARGET,NOOPT'
TARGET_GRAPHICS:
Build.Pkgs: 'MsGraphicsPkg'
Build.Targets: 'DEBUG,RELEASE,NO-TARGET,NOOPT'
TARGET_CORE:
Build.Pkgs: 'MsCorePkg'
Build.Targets: 'DEBUG,RELEASE,NO-TARGET,NOOPT'
TARGET_TEST_PCBDS_LOG_WHEA_HID:
Build.Pkgs: 'UefiTestingPkg,PcBdsPkg,AdvLoggerPkg,MsWheaPkg,HidPkg'
Build.Targets: 'DEBUG,RELEASE,NO-TARGET,NOOPT'
workspace:
clean: all
${{ if ne(parameters.container_image, '') }}:
container: ${{ parameters.container_image }}
pool:
vmImage: ${{ parameters.vm_image }}
steps:
- ${{ if and(ne(parameters.container_image, ''), not(contains(parameters.vm_image, 'windows'))) }}:
- script: echo "##vso[task.prependpath]/home/vsts_azpcontainer/.local/bin"
displayName: Add User Local Bin to Path
- template: Steps/PrGate.yml@mu_devops
parameters:
build_archs: ${{ parameters.arch_list }}
build_pkgs: $(Build.Pkgs)
build_targets: $(Build.Targets)
do_ci_build: true
do_ci_setup: true
do_non_ci_build: false
do_non_ci_setup: true
do_pr_eval: true
extra_build_args: ${{ parameters.extra_build_args }}
extra_install_step: ${{ parameters.extra_install_step }}
tool_chain_tag: ${{ parameters.tool_chain_tag }}
install_tools: ${{ eq(parameters.container_image, '') }}