Skip to content

Commit 704d64b

Browse files
committed
Add Github workflow for the sigrok-cli x86_64 AppImage build
1 parent 458d0eb commit 704d64b

File tree

1 file changed

+86
-0
lines changed

1 file changed

+86
-0
lines changed

.github/workflows/build.yml

Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -267,6 +267,91 @@ jobs:
267267
path: sigrok-build/ci/appimage/appimage-build/PulseView-*.AppImage
268268

269269

270+
build_sigrok-cli_appimage:
271+
name: sigrok-cli AppImage build (${{ matrix.target.target }})
272+
273+
runs-on: ubuntu-latest
274+
container:
275+
image: ghcr.io/knarfs/sigrok-appimage-${{ matrix.target.container }}:latest
276+
277+
strategy:
278+
matrix:
279+
target:
280+
# - target: "i386"
281+
# container: "x86_64-i386"
282+
# cc: "gcc -m32"
283+
# cxx: "g++ -m32"
284+
# ld: "ld -melf_i386"
285+
# ldflags: "-m32"
286+
- target: "x86_64"
287+
container: "x86_64"
288+
cc: "gcc"
289+
cxx: "g++"
290+
ld: "ld"
291+
ldflags: ""
292+
293+
env:
294+
TARGET: ${{ matrix.target.target }}
295+
CC: ${{ matrix.target.cc }}
296+
CXX: ${{ matrix.target.cxx }}
297+
LD: ${{ matrix.target.ld }}
298+
LDFLAGS: ${{ matrix.target.ldflags }}
299+
APP_DIR: "${{ github.workspace }}/AppDir"
300+
# Artifact infos
301+
ARTIFACT_TITLE: "sigrok-cli"
302+
ARTIFACT_BIN_NAME: "sigrok-cli"
303+
ARTIFACT_VERSION: "NIGHTLY"
304+
305+
steps:
306+
- name: Update dependencies
307+
run: |
308+
sudo apt-get update
309+
sudo apt-get upgrade -y
310+
# Temp!
311+
sudo apt-get install -y libffi-dev
312+
# Temp!
313+
sudo apt-get install -y python3.6-dev
314+
315+
- name: Checkout sigrok-build
316+
uses: actions/checkout@v3
317+
with:
318+
path: sigrok-build
319+
320+
- name: Build dependencies
321+
run: |
322+
cd sigrok-build/ci/appimage
323+
source sigrok-appimage-init-toolchain.sh
324+
./sigrok-appimage-build-dependencies.sh
325+
326+
- name: Checkout sigrok-cli
327+
uses: actions/checkout@v3
328+
with:
329+
repository: sigrokproject/sigrok-cli
330+
path: sigrok-cli
331+
332+
- name: Build sigrok-cli
333+
run: |
334+
source sigrok-build/ci/appimage/sigrok-appimage-init-toolchain.sh
335+
mkdir -p "$APP_DIR"
336+
cd sigrok-cli
337+
./autogen.sh
338+
PKG_CONFIG_PATH=$P ./configure --prefix="$APP_DIR"/usr
339+
make $PARALLEL $V
340+
make install $V
341+
342+
- name: Build AppImage
343+
run: |
344+
cd sigrok-build/ci/appimage
345+
source sigrok-appimage-init-toolchain.sh
346+
./sigrok-appimage-create-appimage.sh
347+
348+
- name: Upload artifact
349+
uses: actions/upload-artifact@v3
350+
with:
351+
name: artifacts
352+
path: sigrok-build/ci/appimage/appimage-build/sigrok-cli-*.AppImage
353+
354+
270355
build_pulseview_macos:
271356
name: PulseView macOS build
272357

@@ -410,6 +495,7 @@ jobs:
410495
- build_pulseview_mxe
411496
- build_sigrok-cli_mxe
412497
- build_pulseview_appimage
498+
- build_sigrok-cli_appimage
413499
- build_pulseview_macos
414500
- build_sigrok-cli_macos
415501

0 commit comments

Comments
 (0)