From f30c1d6f474eb9bbdfac7f554115c2ff0aafd15f Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Sun, 29 Oct 2023 22:08:22 -0500 Subject: [PATCH] Fix microarchitecture specific code in common code paths --- scripts/before_ci_build.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/before_ci_build.sh b/scripts/before_ci_build.sh index 48141588..2472ff76 100644 --- a/scripts/before_ci_build.sh +++ b/scripts/before_ci_build.sh @@ -7,7 +7,12 @@ if [ ! -f finish_before_ci_build ]; then if [[ "$OSTYPE" == "linux-gnu" || "$OSTYPE" == "linux-musl" || "$OSTYPE" == "darwin"* ]]; then curl -s -O https://ftp.gnu.org/gnu/gmp/gmp-${GMP_VERSION}.tar.xz tar -xf gmp-${GMP_VERSION}.tar.xz - cd gmp-${GMP_VERSION} && ./configure --enable-fat && make -j4 && make install && cd ../ + cd gmp-${GMP_VERSION} + # config.guess uses microarchitecture and configfsf.guess doesn't + # We replace config.guess with configfsf.guess to avoid microarchitecture + # specific code in common code. + rm config.guess && mv configfsf.guess config.guess && chmod +x config.guess + ./configure --enable-fat && make -j4 && make install && cd ../ curl -s -O https://ftp.gnu.org/gnu/mpfr/mpfr-${MPFR_VERSION}.tar.gz tar -xf mpfr-${MPFR_VERSION}.tar.gz cd mpfr-${MPFR_VERSION} && ./configure && make -j4 && make install && cd ../