#################################
# Set up environment variables: #
#################################

cd src

# When SAGE_FAT_BINARY is set, disable processor-specific optimizations
if [ "$SAGE_FAT_BINARY" = yes ]; then
    GIVARO_CONFIGURE="--disable-sse --disable-sse2 --disable-sse3 --disable-ssse3 --disable-sse41 --disable-sse42 --disable-fma --disable-fma4 --disable-avx --disable-avx2  $GIVARO_CONFIGURE"
fi

cp "$SAGE_ROOT"/config/config.* build-aux/
sdh_configure $SAGE_CONFIGURE_GMP --enable-shared $GIVARO_CONFIGURE
sdh_make
sdh_make_install
