File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -200,8 +200,15 @@ timestamp=$(git log -1 --format=%ct)
200200# Build mold in a container.
201201mkdir -p dist
202202
203+ # If the host is ARM64, `uname -m` in an ARM32 container running on it
204+ # reports it not as ARM32 but as ARM64, which confuses BLAKE3's cmake script
205+ # and erroneously enables NEON SIMD instructions. `setarch` can be used
206+ # to change the output of `uname -m`.
207+ [ $arch = arm ] && setarch=' setarch linux32'
208+
203209podman run --arch $arch -it --rm --userns=host --pids-limit=-1 --network=none \
204- --pull=never -v " $( pwd) :/mold:ro" -v " $( pwd) /dist:/dist" $image bash -c "
210+ --pull=never -v " $( pwd) :/mold:ro" -v " $( pwd) /dist:/dist" $image \
211+ $setarch bash -c "
205212set -e
206213export SOURCE_DATE_EPOCH=$timestamp
207214mkdir /build
You can’t perform that action at this time.
0 commit comments