Skip to content

Commit

Permalink
fix win-x86 compilation error
Browse files Browse the repository at this point in the history
  • Loading branch information
sdcb committed Jan 30, 2025
1 parent e43ab61 commit 0d94087
Showing 1 changed file with 25 additions and 12 deletions.
37 changes: 25 additions & 12 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,18 +59,31 @@ jobs:
- name: Install Toolchain (arch-specific)
run: |
sudo apt-get update
if [ "${{ matrix.arch }}" = "x86" ]; then
sudo apt-get install -y gcc-multilib g++-multilib
elif [ "${{ matrix.arch }}" = "arm64" ]; then
sudo apt-get install -y gcc-aarch64-linux-gnu g++-aarch64-linux-gnu
sudo apt-get install -y qemu-user
elif [ "${{ matrix.arch }}" = "arm" ]; then
sudo apt-get install -y gcc-arm-linux-gnueabihf g++-arm-linux-gnueabihf
sudo apt-get install -y qemu-user
elif [ "${{ matrix.os }}" = "win" ]; then
sudo apt-get install -y mingw-w64
sudo apt-get install -y wine
fi
TARGET="${{ matrix.os }}-${{ matrix.arch }}"
case "$TARGET" in
"linux-x86")
sudo apt-get install -y gcc-multilib g++-multilib
;;
"linux-arm64")
sudo apt-get install -y gcc-aarch64-linux-gnu g++-aarch64-linux-gnu
sudo apt-get install -y qemu-user
;;
"linux-arm")
sudo apt-get install -y gcc-arm-linux-gnueabihf g++-arm-linux-gnueabihf
sudo apt-get install -y qemu-user
;;
"win-x86" | "win-x64")
sudo apt-get install -y mingw-w64
sudo apt-get install -y wine
;;
"linux-x64")
# 如果有额外需要,可在此处安装
;;
*)
echo "Error: Unsupported OS-Architecture combination: $TARGET"
exit 1
;;
esac
- name: Download GMP Source
run: |
Expand Down

0 comments on commit 0d94087

Please sign in to comment.