This repository has been archived by the owner on Sep 13, 2024. It is now read-only.
forked from IchthysMaranatha/asterisk-chan-quectel
-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Build DEB packages for other architectures
- Loading branch information
Showing
12 changed files
with
398 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
name: Cross compile | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- master | ||
- cross-compile | ||
|
||
env: | ||
BUILD_TYPE: Release | ||
UBUNTU_DISTRO: ubuntu22.04 | ||
|
||
jobs: | ||
build-pkg: | ||
strategy: | ||
matrix: | ||
arch: [armv7, aarch64] | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- uses: uraimo/run-on-arch-action@v2 | ||
name: Build package (${{ matrix.arch }}) | ||
with: | ||
arch: ${{ matrix.arch }} | ||
distro: ${{ env.UBUNTU_DISTRO }} | ||
githubToken: ${{ github.token }} | ||
install: | | ||
apt-get update -qq -y | ||
apt-get install -qq -y git cmake \ | ||
build-essential \ | ||
libsqlite3-dev libasound2-dev asterisk-dev | ||
git config --global --add safe.directory /home/runner/work/asterisk-chan-quectel/asterisk-chan-quectel | ||
env: | | ||
DEBIAN_FRONTEND: noninteractive | ||
run: | | ||
cmake -P make-build-dir.cmake | ||
cmake -P make-package.cmake | ||
- uses: ./.github/actions/install-required-packages | ||
- name: Install lintian | ||
env: | ||
DEBIAN_FRONTEND: noninteractive | ||
run: sudo apt-get install -qq -y lintian | ||
- name: Check package | ||
run: lintian --verbose --info package/asterisk-chan-quectel_*.deb | ||
- name: Archive DEB | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: pkg-deb-${{ matrix.arch }} | ||
path: | | ||
package/asterisk-chan-quectel_*.deb | ||
package/asterisk-chan-quectel_*.deb.sha256 | ||
retention-days: 1 | ||
if-no-files-found: error | ||
- name: Archive TAR.GZ | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: pkg-tar-gz-${{ matrix.arch }} | ||
path: | | ||
package/asterisk-chan-quectel_*.tar.gz | ||
package/asterisk-chan-quectel_*.tar.gz.sha256 | ||
retention-days: 1 | ||
if-no-files-found: error | ||
- uses: uraimo/run-on-arch-action@v2 | ||
name: Try to instal package (${{ matrix.arch }}) | ||
with: | ||
arch: ${{ matrix.arch }} | ||
distro: ${{ env.UBUNTU_DISTRO }} | ||
setup: | | ||
mkdir -p "${PWD}/package" | ||
dockerRunArgs: | | ||
--volume "${PWD}/package:/package" | ||
install: | | ||
apt-get update -qq -y | ||
apt-get install -qq -y gdebi-core | ||
env: | | ||
DEBIAN_FRONTEND: noninteractive | ||
run: | | ||
gdebi --non-interactive package/asterisk-chan-quectel_*.deb || echo "::error::Could not install package ${{ matrix.arch }}" |
Oops, something went wrong.