Skip to content

Add portable linux package build matrix per target. #1

Add portable linux package build matrix per target.

Add portable linux package build matrix per target. #1

name: Portable Linux Package Matrix
on:
workflow_dispatch:
inputs:
package_version:
type: string
default: ADHOCBUILD
workflow_call:
inputs:
package_version:
type: string
default: ADHOCBUILD
jobs:
portable_linux_packages:
strategy:
matrix:
target_bundle:
- amdgpu_family: "gfx94X-dcgpu"
- amdgpu_family: "gfx110X-dgpu"
- amdgpu_family: "gfx1151"
name: Build Linux Packages
runs-on: azure-cpubuilder-linux-scale
strategy:

Check failure on line 27 in .github/workflows/portable_linux_package_matrix.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/portable_linux_package_matrix.yml

Invalid workflow file

You have an error in your yaml syntax on line 27
fail-fast: true
env:
TEATIME_LABEL_GH_GROUP: 1
OUTPUT_DIR: ${{ github.workspace }}/output
BUILD_IMAGE: ghcr.io/nod-ai/therock_build_manylinux_x86_64:main
steps:
- name: "Checking out repository"
uses: actions/checkout@8f4b7f84864484a7bf31766abe9204da3cbe65b3 # v3.5.0
# TODO: We shouldn't be using a cache on actual release branches, but it
# really helps for iteration time.
- name: Enable cache
uses: actions/cache/restore@v4
with:
path: ${{ env.OUTPUT_DIR }}/caches
key: portable-linux-package-matrix-v1-${{matrix.target_bundle.amdgpu_family}}-${{ github.sha }}
restore-keys: |
portable-linux-package-matrix-v1-${{matrix.target_bundle.amdgpu_family}}-
- name: Fetch sources
run: |
# Prefetch docker container in background.
docker pull ${{env.BUILD_IMAGE}} &
git config --global user.email "nobody@amd.com"
git config --global user.name "Nobody"
./build_tools/fetch_sources.py --depth 1
wait
# The full checkout is very large: ~16GB, 9 of which is GIT stuff.
# So we delete the latter. This must be done after getting any git
# stamps or such things.
- name: Trim Disk Space
run: |
rm -Rf sources/.repo
df -h
- name: Build Projects
run: |
./packaging/linux-portable/build_portable.py \
--image=${{env.BUILD_IMAGE}} \
--output-dir=${{env.OUTPUT_DIR}} \
-- \
"-DTHEROCK_AMDGPU_FAMILIES=${{matrix.target_bundle.amdgpu_family}}" \
"-DTHEROCK_ENABLE_ALL=OFF"
- name: Report
if: ${{ !cancelled() }}
run: |
echo "Full SDK du:"
echo "------------"
du -h -d 1 ${{env.OUTPUT_DIR}/build/dist/rocm
echo "Artifact Archives:"
echo "------------------"
ls -lh ${{env.OUTPUT_DIR}/build/artifacts/*.tar.xz
echo "Artifacts:"
echo "----------"
du -h -d 1 ${{env.OUTPUT_DIR}/build/artifacts
- name: Save cache
uses: actions/cache/save@v4
if: always()
with:
path: ${{ env.CACHE_DIR }}
key: portable-linux-package-matrix-v1-${{matrix.target_bundle.amdgpu_family}}-${{ github.sha }}