Browse Source

Do not enable LTO for fftw

Signed-off-by: falkTX <falktx@falktx.com>
master
falkTX 3 months ago
parent
commit
a7512db547
Signed by: falkTX <falktx@falktx.com> GPG Key ID: CDBAA37ABC74FBA0
1 changed files with 23 additions and 5 deletions
  1. +23
    -5
      bootstrap-plugins.sh

+ 23
- 5
bootstrap-plugins.sh View File

@@ -40,17 +40,24 @@ source setup/versions.sh

if [ -z "${PAWPAW_SKIP_FFTW}" ]; then

# fftw is not compatible with LTO
if [ -z "${PAWPAW_SKIP_LTO}" ] || [ "${PAWPAW_SKIP_LTO}" -eq 0 ]; then
export EXTRA_CFLAGS="-fno-lto"
export EXTRA_LDFLAGS="-fno-lto"
fi

FFTW_EXTRAFLAGS="--disable-alloca --disable-fortran --with-our-malloc"

if [ "${TOOLCHAIN_PREFIX}" = "aarch64-linux-gnu" ]; then
FFTW_EXTRAFLAGS+=" --with-slow-timer"
FFTW_EXTRAFLAGS+=" --enable-neon"
elif [ "${TOOLCHAIN_PREFIX}" = "arm-linux-gnueabihf" ]; then
FFTW_EXTRAFLAGS+=" --with-slow-timer"
# FIXME macos-universal proper optimizations
if [ "${MACOS_UNIVERSAL}" -eq 0 ]; then
elif [ "${MACOS_UNIVERSAL}" -eq 0 ]; then
FFTW_EXTRAFLAGS+=" --enable-sse2"
fi

# if [ "${WIN32}" -eq 0 ]; then
# FFTW_EXTRAFLAGS+=" --enable-threads"
# fi

download fftw "${FFTW_VERSION}" "${FFTW_URL}"
build_autoconf fftw "${FFTW_VERSION}" "${FFTW_EXTRAFLAGS}"

@@ -65,8 +72,19 @@ fi # PAWPAW_SKIP_FFTW

if [ -z "${PAWPAW_SKIP_FFTW}" ]; then

# fftw is not compatible with LTO
if [ -z "${PAWPAW_SKIP_LTO}" ] || [ "${PAWPAW_SKIP_LTO}" -eq 0 ]; then
export EXTRA_CFLAGS="-fno-lto"
export EXTRA_LDFLAGS="-fno-lto"
fi

FFTWF_EXTRAFLAGS="${FFTW_EXTRAFLAGS} --enable-single"

if [ "${TOOLCHAIN_PREFIX}" = "aarch64-linux-gnu" ] || [ "${TOOLCHAIN_PREFIX}" = "arm-linux-gnueabihf" ]; then
FFTWF_EXTRAFLAGS+=" --with-slow-timer"
FFTWF_EXTRAFLAGS+=" --enable-neon"
fi

copy_download fftw fftwf "${FFTW_VERSION}"
build_autoconf fftwf "${FFTW_VERSION}" "${FFTWF_EXTRAFLAGS}"



Loading…
Cancel
Save