aboutsummaryrefslogtreecommitdiff
path: root/.github/workflows/linux.yml
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/workflows/linux.yml
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/workflows/linux.yml')
-rw-r--r--.github/workflows/linux.yml25
1 files changed, 23 insertions, 2 deletions
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"