Skip to content

Commit ed2b4f0

Browse files
committed
update
1 parent e39e2ca commit ed2b4f0

File tree

3 files changed

+22
-2
lines changed

3 files changed

+22
-2
lines changed

.github/workflows/build-haf-tfa.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ on:
1818
- 'Platforms/QemuSbsaPkg/**'
1919
- 'Silicon/Arm/**'
2020
workflow_dispatch:
21+
workflow_call:
2122

2223
jobs:
2324
build:
@@ -67,13 +68,11 @@ jobs:
6768
run: python Platforms/QemuSbsaPkg/PlatformBuild.py HAF_TFA_BUILD=TRUE
6869

6970
- name: Install archive tools
70-
if: github.event_name == 'release'
7171
run: |
7272
apt-get update -y
7373
apt-get install -y zip tar gh
7474
7575
- name: Create per-target archives
76-
if: github.event_name == 'release'
7776
shell: bash
7877
run: |
7978
set -euo pipefail
@@ -89,6 +88,12 @@ jobs:
8988
(cd "$BIN_DIR" && tar -czf "$TAR_PATH" .)
9089
echo "Created archives:"
9190
ls -lh "$ZIP_PATH" "$TAR_PATH"
91+
92+
- name: Upload Artifacts
93+
if: github.event_name != 'release'
94+
uses: actions/upload-artifact@v3
95+
with:
96+
name: haf-tfa-firmware
9297

9398
- name: Upload Release Assets
9499
if: github.event_name == 'release'

.github/workflows/constants.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,15 @@ on:
2020
qemu-core-count:
2121
description: 'Number of CPU cores for QEMU.'
2222
value: ${{ jobs.vars.outputs.qemu-core-count }}
23+
build-haf-tfa:
24+
description: 'Whether to run the Hafnium and Trusted Firmware-A build job'
25+
value: ${{ jobs.vars.outputs.build-haf-tfa }}
2326

2427
env:
2528
CONTAINER_IMAGE: 'ghcr.io/microsoft/mu_devops/ubuntu-24-test:latest'
2629
PYTHON_VERSION: '3.12'
2730
QEMU_CORE_COUNT: '2'
31+
BUILD_HAF_TFA: 'true'
2832

2933
jobs:
3034
vars:
@@ -35,6 +39,7 @@ jobs:
3539
container-image: ${{ steps.set-vars.outputs.container-image }}
3640
python-version: ${{ steps.set-vars.outputs.python-version }}
3741
qemu-core-count: ${{ steps.set-vars.outputs.qemu-core-count }}
42+
build-haf-tfa: ${{ steps.set-vars.outputs.build-haf-tfa }}
3843

3944
steps:
4045
- name: Set Environment Constants
@@ -44,3 +49,4 @@ jobs:
4449
echo "container-image=${CONTAINER_IMAGE}" >> $GITHUB_OUTPUT
4550
echo "python-version=${PYTHON_VERSION}" >> $GITHUB_OUTPUT
4651
echo "qemu-core-count=${QEMU_CORE_COUNT}" >> $GITHUB_OUTPUT
52+
echo "build-haf-tfa=${BUILD_HAF_TFA}" >> $GITHUB_OUTPUT

.github/workflows/platform-ci.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,22 @@ jobs:
2323
vars:
2424
name: Get Repository Constants
2525
uses: ./.github/workflows/constants.yml
26+
27+
build-haf-tfa:
28+
needs: vars
29+
30+
if: ${{ needs.vars.outputs.build-haf-tfa == 'true' }}
31+
32+
name: Build Hafnium and Trusted Firmware-A
33+
uses: ./.github/workflows/build-haf-tfa.yml
2634

2735
# Builds the platform(s) in this repository as defined by the matrix.
2836
build:
2937
name: ${{ matrix.platform }} ${{ matrix.architecture }} ${{ matrix.target }} ${{ matrix.tool-chain }} (${{ matrix.os }})
3038

3139
needs:
3240
- vars
41+
- build-haf-tfa
3342

3443
runs-on: ${{ matrix.os }}
3544

0 commit comments

Comments
 (0)