aboutsummaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorKenjiro Nakayama <nakayamakenjiro@gmail.com>2026-08-08 16:01:21 +0900
committerKenjiro Nakayama <nakayamakenjiro@gmail.com>2026-08-08 16:35:19 +0900
commit71aba26edb2c3951c5c9f9fcb2ae3bb40ac291c6 (patch)
tree2a18718c23ce741a32f7df214c720ad0d084dda2 /.github
parent8430c1d169b83d5bfef4651e4bdacc8925dce2d1 (diff)
downloadportable-71aba26edb2c3951c5c9f9fcb2ae3bb40ac291c6.tar.gz
portable-71aba26edb2c3951c5c9f9fcb2ae3bb40ac291c6.tar.bz2
portable-71aba26edb2c3951c5c9f9fcb2ae3bb40ac291c6.zip
Install CI dependencies in workflows
Move APT package installation from scripts/test to the CI workflows. Build the Linux package list based on the target architecture so that CMake, Ninja, QEMU, and the required cross-compilers are installed together. This makes the packages required by each target explicit and avoids repeated apt-get operations within each CI job.
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/android.yml5
-rw-r--r--.github/workflows/linux.yml25
2 files changed, 28 insertions, 2 deletions
diff --git a/.github/workflows/android.yml b/.github/workflows/android.yml
index 5e5cf66..a2faa94 100644
--- a/.github/workflows/android.yml
+++ b/.github/workflows/android.yml
@@ -27,6 +27,11 @@ jobs:
27 - name: "Checkout repository" 27 - name: "Checkout repository"
28 uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 28 uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
29 29
30 - name: "Install build dependencies"
31 run: |
32 sudo apt-get update
33 sudo apt-get install -y cmake ninja-build
34
30 - name: "Run CI script" 35 - name: "Run CI script"
31 run: ./scripts/test 36 run: ./scripts/test
32 env: 37 env:
diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml
index 197e894..ad13ed8 100644
--- a/.github/workflows/linux.yml
+++ b/.github/workflows/linux.yml
@@ -48,8 +48,29 @@ jobs:
48 48
49 - name: "Install test dependencies" 49 - name: "Install test dependencies"
50 run: | 50 run: |
51 packages=(cmake ninja-build libio-socket-ssl-perl)
52 case "${{ matrix.arch }}" in
53 mingw32|mingw64)
54 packages+=(mingw-w64)
55 ;;
56 arm32)
57 packages+=(qemu-user-static binfmt-support g++-arm-linux-gnueabihf)
58 ;;
59 arm64)
60 packages+=(qemu-user-static binfmt-support g++-aarch64-linux-gnu)
61 ;;
62 loong64)
63 packages+=(qemu-user-static binfmt-support g++-14-loongarch64-linux-gnu)
64 ;;
65 mips32)
66 packages+=(qemu-user-static binfmt-support g++-mips-linux-gnu)
67 ;;
68 mips64)
69 packages+=(qemu-user-static binfmt-support g++-mips64el-linux-gnuabi64)
70 ;;
71 esac
51 sudo apt-get update 72 sudo apt-get update
52 sudo apt-get install -y libio-socket-ssl-perl 73 sudo apt-get install -y "${packages[@]}"
53 perl -MIO::Socket::SSL::Utils -e 1 74 perl -MIO::Socket::SSL::Utils -e 1
54 75
55 - name: "Run tests" 76 - name: "Run tests"
@@ -77,7 +98,7 @@ jobs:
77 - name: "Install test dependencies" 98 - name: "Install test dependencies"
78 run: | 99 run: |
79 sudo apt-get update 100 sudo apt-get update
80 sudo apt-get install -y libio-socket-ssl-perl 101 sudo apt-get install -y cmake ninja-build libio-socket-ssl-perl
81 perl -MIO::Socket::SSL::Utils -e 1 102 perl -MIO::Socket::SSL::Utils -e 1
82 103
83 - name: "Run tests" 104 - name: "Run tests"