Skip to content

Commit 84c883e

Browse files
committed
CI: Debian for i386, armhf, arm64
1 parent ee5747c commit 84c883e

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed

.github/workflows/build.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,9 @@ on:
2828
- 'onlinedocs'
2929
workflow_call:
3030

31+
env:
32+
BUILD_TYPE: RelWithDebInfo
33+
3134
jobs:
3235
linux-x86_64-autotools:
3336
runs-on: ubuntu-latest
@@ -73,10 +76,49 @@ jobs:
7376
run: >-
7477
cmake
7578
-B build
79+
-D CMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}
7680
-D CMAKE_INSTALL_PREFIX:PATH=/usr/local
7781
- name: Build
7882
run: cmake --build build
7983
- name: Install
8084
run: sudo cmake --build build --target install DESTDIR=$PWD/_d
8185
- name: List installed files
8286
run: find _d | env LC_ALL=C sort | sed 's|^_d||'
87+
88+
linux:
89+
runs-on: ubuntu-latest
90+
container: debian:11
91+
strategy:
92+
matrix:
93+
include:
94+
- { arch: i386, processor: i686, prefix: i686-linux-gnu, inc-lib: i386-linux-gnu }
95+
- { arch: armhf, processor: armhf, prefix: arm-linux-gnueabihf, inc-lib: arm-linux-gnueabihf }
96+
- { arch: arm64, processor: aarch64, prefix: aarch64-linux-gnu, inc-lib: aarch64-linux-gnu }
97+
steps:
98+
- uses: actions/checkout@v3
99+
- name: Add architecture
100+
run: |
101+
dpkg --add-architecture ${{matrix.arch}}
102+
apt-get update
103+
- name: Install prerequisites
104+
run: >-
105+
apt-get update
106+
107+
apt-get install -y
108+
git
109+
cmake
110+
crossbuild-essential-${{matrix.arch}}
111+
- name: Configure
112+
run: >-
113+
cmake
114+
-D DEBUG_CMAKE=1
115+
-D CMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}
116+
-D CMAKE_SYSTEM_NAME=Linux
117+
-D CMAKE_SYSTEM_PROCESSOR=${{matrix.processor}}
118+
-D CMAKE_C_COMPILER=${{matrix.prefix}}-gcc
119+
-D CMAKE_FIND_ROOT_PATH=/usr/${{matrix.prefix}}
120+
-D CMAKE_INCLUDE_PATH=/usr/include/${{matrix.inc-lib}}
121+
-D CMAKE_LIBRARY_PATH=/usr/lib/${{matrix.inc-lib}}
122+
-B build
123+
- name: Build
124+
run: cmake --build build

0 commit comments

Comments
 (0)