try fix build

This commit is contained in:
2025-09-16 12:24:51 +08:00
parent 9873241be1
commit 86192056c4

View File

@@ -28,41 +28,12 @@ jobs:
arch=${{ matrix.arch }}
arch=${arch/-unknown/}
export PATH="$PWD/musl-toolchain/bin:$PATH"
echo '#!/bin/bash
VALID_ARGS=()
for arg in "$@"; do
if [[ $arg == -m* ]]; then
if [[ ! $arg == *'='* ]] && (( ${#arg} < 5 )); then
continue
fi
fi
VALID_ARGS+=("$arg")
done
exec '"${arch}-cc"' "${VALID_ARGS[@]}"' > "$PWD/${arch}-cc"
chmod +x "$PWD/${arch}-cc"
echo '#!/bin/bash
VALID_ARGS=()
for arg in "$@"; do
if [[ $arg == -m* ]]; then
if [[ ! $arg == *'='* ]] && (( ${#arg} < 5 )); then
continue
fi
fi
VALID_ARGS+=("$arg")
done
exec '"${arch}-g++"' "${VALID_ARGS[@]}"' > "$PWD/${arch}-g++"
chmod +x "$PWD/${arch}-g++"
export CC="$PWD/${arch}-cc"
export CXX="$PWD/${arch}-g++"
export CC="${arch}-cc"
export HOST_CC="cc"
export CXX="${arch}-g++"
export HOST_CXX="cxx"
export AR="${arch}-ar"
export HOST_AR="ar"
export RUSTFLAGS="-C linker=${CC}"
cargo build --release --target ${{ matrix.arch }}
version=${{ github.event.release.tag_name }}