ci: add musl build targets for .deb generation (#1061)

* ci: add musl build targets for .deb generation

* add missing container

* try to fix musl rename condition
This commit is contained in:
Clement Tsang 2023-03-13 03:25:40 -04:00 committed by GitHub
parent 10b8673c04
commit 61fec230fc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 22 additions and 2 deletions

View File

@ -282,13 +282,14 @@ jobs:
path: release
build-deb:
name: "Build Debian installers"
name: "Build Debian .deb software packages"
runs-on: "ubuntu-20.04"
strategy:
fail-fast: false
matrix:
info:
- { target: "x86_64-unknown-linux-gnu", cross: false, dpkg: amd64 }
- { target: "x86_64-unknown-linux-musl", cross: false, dpkg: amd64 }
- {
target: "aarch64-unknown-linux-gnu",
cross: true,
@ -301,6 +302,18 @@ jobs:
dpkg: armhf,
container: "ghcr.io/clementtsang/cargo-deb-armv7-unknown-linux-gnueabihf",
}
- {
target: "aarch64-unknown-linux-musl",
cross: true,
dpkg: arm64,
container: "ghcr.io/clementtsang/cargo-deb-aarch64-unknown-linux-gnu",
}
- {
target: "armv7-unknown-linux-musleabihf",
cross: true,
dpkg: armhf,
container: "ghcr.io/clementtsang/cargo-deb-armv7-unknown-linux-gnueabihf",
}
steps:
- name: Checkout repository
uses: actions/checkout@v3
@ -356,10 +369,17 @@ jobs:
VERSION=${{ matrix.info.dpkg }}
mv $TMP_NAME $(echo $TMP_NAME | sed "s/-$VERSION//")
- name: Rename if it is a musl target
if: contains(matrix.info.target, 'musl')
run: |
TMP_NAME=$(find bottom_*.deb)
mv $TMP_NAME $(echo $TMP_NAME | sed "s/bottom/bottom-musl/")
# TODO: Maybe rename version if nightly?
- name: Verify Debian release
id: verify
run: |
DEB_FILE=$(find bottom_*.deb)
DEB_FILE=$(find bottom*_*.deb)
dpkg -I $DEB_FILE
dpkg -I $DEB_FILE | grep ${{ matrix.info.dpkg }} && echo "Found correct architecture"
echo "DEB_FILE=$DEB_FILE" >> $GITHUB_OUTPUT