diff options
| author | Peter Jones <pjones@redhat.com> | 2021-02-01 15:03:33 -0500 |
|---|---|---|
| committer | Peter Jones <pjones@redhat.com> | 2021-03-22 16:43:44 -0400 |
| commit | 4bc72543eadd3908a8da55027c207e1c24b0d8a1 (patch) | |
| tree | 9712114b744a55be2d88ac81dc0c1e5938a14f60 | |
| parent | e03ce7ed85195107fce206c7390263ff9afeaece (diff) | |
| download | efi-boot-shim-4bc72543eadd3908a8da55027c207e1c24b0d8a1.tar.gz efi-boot-shim-4bc72543eadd3908a8da55027c207e1c24b0d8a1.zip | |
Try multi-arch CI building using cross compilation
This enables a pile of CI builds on fedora and centos, some using a cross
compilers:
- cross-compiler builds for f32, f33, f34, and f35 (currently rawhide):
x86_64 (yes, x86_64->x86_64)
i686 (x86_64->i686)
arm (x86_64->arm)
aarch64 (x86-64->aarch64)
- non-cross builds for centos7 and centos8
x86_64
i686
- we can't cross build on centos7 or centos8 because they don't have
the cross compiler packages
Signed-off-by: Peter Jones <pjones@redhat.com>
| -rw-r--r-- | .github/workflows/pullrequest.yml | 172 | ||||
| -rw-r--r-- | .github/workflows/push.yml | 55 |
2 files changed, 160 insertions, 67 deletions
diff --git a/.github/workflows/pullrequest.yml b/.github/workflows/pullrequest.yml index df506555..41ca282c 100644 --- a/.github/workflows/pullrequest.yml +++ b/.github/workflows/pullrequest.yml @@ -1,44 +1,102 @@ -name: pull-request-builds +name: pull-request on: + push: + branches: + - main pull_request: branches: - main - - sbat jobs: - pull-request-intel: + cross-build-pull-request: runs-on: ubuntu-20.04 - container: vathpela/efi-ci:f34-x64 - name: ${{ matrix.distro }} ${{ matrix.efiarch }} build + container: vathpela/efi-ci:${{ matrix.distro }}-x64 + name: ${{ matrix.distro }} ${{ matrix.efiarch }} cross-build strategy: matrix: include: - arch: amd64 + efiarch: aa64 + gccarch: aarch64 + makearch: aarch64 + distro: f35 + - arch: amd64 + efiarch: aa64 + gccarch: aarch64 + makearch: aarch64 + distro: f34 + - arch: amd64 + efiarch: aa64 + gccarch: aarch64 + makearch: aarch64 + distro: f33 + - arch: amd64 + efiarch: aa64 + gccarch: aarch64 + makearch: aarch64 + distro: f32 + - arch: amd64 + efiarch: arm + gccarch: arm + makearch: arm + distro: f35 + - arch: amd64 + efiarch: arm + gccarch: arm + makearch: arm + distro: f34 + - arch: amd64 + efiarch: arm + gccarch: arm + makearch: arm + distro: f33 + - arch: amd64 + efiarch: arm + gccarch: arm + makearch: arm + distro: f32 + - arch: amd64 efiarch: x64 + gccarch: x86_64 makearch: x86_64 - distro: efi-ci-f34 + distro: f35 - arch: amd64 efiarch: x64 + gccarch: x86_64 makearch: x86_64 - distro: efi-ci-f33 + distro: f34 - arch: amd64 efiarch: x64 + gccarch: x86_64 makearch: x86_64 - distro: efi-ci-f32 + distro: f33 + - arch: amd64 + efiarch: x64 + gccarch: x86_64 + makearch: x86_64 + distro: f32 + - arch: amd64 + efiarch: ia32 + gccarch: x86_64 + makearch: ia32 + distro: f35 - arch: amd64 efiarch: ia32 + gccarch: x86_64 makearch: ia32 - distro: efi-ci-f34 + distro: f34 - arch: amd64 efiarch: ia32 + gccarch: x86_64 makearch: ia32 - distro: efi-ci-f33 + distro: f33 - arch: amd64 efiarch: ia32 + gccarch: x86_64 makearch: ia32 - distro: efi-ci-f32 + distro: f32 steps: - name: Checkout @@ -47,12 +105,102 @@ jobs: # otherwise we are testing target branch instead of the PR branch (see pull_request_target trigger) ref: ${{ github.event.pull_request.head.sha }} fetch-depth: 0 + submodules: recursive + - name: Update submodules on ${{ matrix.distro }} for ${{ matrix.efiarch }} + id: update-submodules + run: | + make update - name: Do the build on ${{ matrix.distro }} for ${{ matrix.efiarch }} id: build run: | - make update || : + make -s CROSS_COMPILE=${{ matrix.gccarch }}-linux-gnu- ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true clean all || make CROSS_COMPILE=${{ matrix.gccarch }}-linux-gnu- ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true clean all + - name: Install on ${{ matrix.distro }} for ${{ matrix.efiarch }} + id: install + run: | + make -s CROSS_COMPILE=${{ matrix.gccarch }}-linux-gnu- ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true install || make CROSS_COMPILE=${{ matrix.gccarch }}-linux-gnu- ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true install + echo 'results:' + find /destdir -type f + + build-pull-request-intel: + runs-on: ubuntu-20.04 + container: vathpela/efi-ci:${{ matrix.distro }}-x64 + name: ${{ matrix.distro }} ${{ matrix.efiarch }} build + + strategy: + matrix: + include: + - arch: amd64 + efiarch: x64 + makearch: x86_64 + distro: f35 + - arch: amd64 + efiarch: x64 + makearch: x86_64 + distro: f34 + - arch: amd64 + efiarch: x64 + makearch: x86_64 + distro: f33 + - arch: amd64 + efiarch: x64 + makearch: x86_64 + distro: f32 + - arch: amd64 + efiarch: x64 + makearch: x86_64 + distro: centos8 + - arch: amd64 + efiarch: x64 + makearch: x86_64 + distro: centos7 + - arch: amd64 + efiarch: ia32 + makearch: ia32 + distro: f35 + - arch: amd64 + efiarch: ia32 + makearch: ia32 + distro: f34 + - arch: amd64 + efiarch: ia32 + makearch: ia32 + distro: f33 + - arch: amd64 + efiarch: ia32 + makearch: ia32 + distro: f32 + - arch: amd64 + efiarch: ia32 + makearch: ia32 + distro: centos8 + - arch: amd64 + efiarch: ia32 + makearch: ia32 + distro: centos7 + + steps: + - name: Checkout + uses: actions/checkout@v2 + with: + # otherwise we are testing target branch instead of the PR branch (see pull_request_target trigger) + ref: ${{ github.event.pull_request.head.sha }} + fetch-depth: 0 + submodules: recursive + - name: Update submodules on ${{ matrix.distro }} for ${{ matrix.efiarch }} + id: update-submodules + run: | + make update + - name: Run tests on ${{ matrix.distro }} for ${{ matrix.efiarch }} + id: test + run: | make -s ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true test || make ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true test + - name: Do the build on ${{ matrix.distro }} for ${{ matrix.efiarch }} + id: build + run: | make -s ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true clean all || make ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true clean all + - name: Install on ${{ matrix.distro }} for ${{ matrix.efiarch }} + id: install + run: | make -s ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true install || make ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true install echo 'results:' find /destdir -type f diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml deleted file mode 100644 index f902390d..00000000 --- a/.github/workflows/push.yml +++ /dev/null @@ -1,55 +0,0 @@ -name: push-builds - -on: - push: - branches: - - main - schedule: - - cron: '0 3 * * *' - -jobs: - push-request-intel: - runs-on: ubuntu-20.04 - container: vathpela/efi-ci:f34-x64 - name: ${{ matrix.distro }} ${{ matrix.efiarch }} build - - strategy: - matrix: - include: - - arch: amd64 - efiarch: x64 - makearch: x86_64 - distro: efi-ci-f34 - - arch: amd64 - efiarch: x64 - makearch: x86_64 - distro: efi-ci-f33 - - arch: amd64 - efiarch: x64 - makearch: x86_64 - distro: efi-ci-f32 - - arch: amd64 - efiarch: ia32 - makearch: ia32 - distro: efi-ci-f34 - - arch: amd64 - efiarch: ia32 - makearch: ia32 - distro: efi-ci-f33 - - arch: amd64 - efiarch: ia32 - makearch: ia32 - distro: efi-ci-f32 - - steps: - - name: Checkout - uses: actions/checkout@v2 - - name: Do the build on ${{ matrix.distro }} for ${{ matrix.efiarch }} - id: build - run: | - make update || : - make -s ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true test || make ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true test - make -s ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true clean all || make ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true clean all - make -s ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true install || make ARCH=${{ matrix.makearch }} PREFIX=/usr DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true install - echo 'results:' - find /destdir -type f |
