github-action: Add RISC-V build
authorMyungJoo Ham <myungjoo.ham@samsung.com>
Thu, 24 Nov 2022 04:46:19 +0000 (13:46 +0900)
committerSangjung Woo <again4you@gmail.com>
Thu, 1 Dec 2022 02:01:24 +0000 (11:01 +0900)
This tries to enable RISC-V build in github-action
based on https://github.com/marketplace/actions/run-on-architecture-riscv64-alpine

In order to build in more primitive distro,
configure bixon/flex optional.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
.github/workflows/risc-v.yml [new file with mode: 0644]

diff --git a/.github/workflows/risc-v.yml b/.github/workflows/risc-v.yml
new file mode 100644 (file)
index 0000000..12bfaa9
--- /dev/null
@@ -0,0 +1,28 @@
+name: Run on architecture (RISCV64 Alpine)
+
+on:
+  push:
+    branches: [ main ]
+  pull_request:
+    branches: [ main ]
+
+jobs:
+  build_job:
+    runs-on: ubuntu-18.04
+    name: Build on alpine RISC-V
+    steps:
+      - uses: actions/checkout@v2.1.0
+      - uses: ProtoByter/run-on-arch-action@master
+        name: Run commands
+        id: Build
+        with:
+          arch: riscv64
+          distro: alpine_latest
+          githubToken: ${{ github.token }}
+          run: |
+            uname -a
+            echo ::set-output name=uname::$(uname -a)
+            apk update
+            apk add meson ninja glib-dev gstreamer-dev gst-plugins-base-dev gcc g++ bash python3 lua-dev
+            meson build
+            ninja -C build test