🔒 Repository is read-only – file editing is disabled.
123456789101112131415161718192021
#!/bin/bash
set +e
cd /tmp
echo "=== GMP EMPTY CFLAGS ==="
rm -rf g2 && mkdir g2 && tar -xJf /tmp/gmp-6.3.0.tar.xz -C g2
cd g2/gmp-6.3.0
./configure --prefix=/usr --build=x86_64-unknown-linux-gnu --enable-cxx > /tmp/g2.log 2>&1
echo "EMPTY_CFLAGS_RC=$?"
tail -2 /tmp/g2.log
echo "=== GMP -D_GNU_SOURCE only ==="
cd /tmp && rm -rf g3 && mkdir g3 && tar -xJf /tmp/gmp-6.3.0.tar.xz -C g3
cd g3/gmp-6.3.0
CFLAGS=-D_GNU_SOURCE ./configure --prefix=/usr --build=x86_64-unknown-linux-gnu --enable-cxx > /tmp/g3.log 2>&1
echo "GNUSOURCE_RC=$?"
tail -2 /tmp/g3.log
echo "=== GMP full pagbuild CFLAGS but no -Wno-error=maybe-uninitialized ==="
cd /tmp && rm -rf g4 && mkdir g4 && tar -xJf /tmp/gmp-6.3.0.tar.xz -C g4
cd g4/gmp-6.3.0
CFLAGS="-D_GNU_SOURCE -Wno-error=implicit-function-declaration -Wno-error=int-conversion -Wno-error=return-type -Wno-error=incompatible-pointer-types -Wno-error=discarded-qualifiers" ./configure --prefix=/usr --build=x86_64-unknown-linux-gnu --enable-cxx > /tmp/g4.log 2>&1
echo "NOWERR_MAYBEUNINIT_RC=$?"
tail -2 /tmp/g4.log