Skip to content

Commit

Permalink
Disable LTO, since runtime errors occur with GCC 11
Browse files Browse the repository at this point in the history
Upstream Bug: nodejs/node#38501
Gentoo Bug: https://bugs.gentoo.org/787158

Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
  • Loading branch information
phmccarty committed May 13, 2021
1 parent 0612c2a commit 51c5850
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 10 deletions.
1 change: 0 additions & 1 deletion build_prepend
Expand Up @@ -19,7 +19,6 @@ export PYTHON=/usr/bin/python2
--shared-openssl \
--shared-zlib \
--use-largepages \
--enable-lto \
--shared-nghttp2 \
--shared-libuv \
--verbose \
Expand Down
12 changes: 4 additions & 8 deletions nodejs.spec
Expand Up @@ -125,7 +125,6 @@ export PYTHON=/usr/bin/python2
--shared-openssl \
--shared-zlib \
--use-largepages \
--enable-lto \
--shared-nghttp2 \
--shared-libuv \
--verbose \
Expand All @@ -137,13 +136,10 @@ export no_proxy=localhost,127.0.0.1,0.0.0.0
export LANG=C.UTF-8
export SOURCE_DATE_EPOCH=1620853173
export GCC_IGNORE_WERROR=1
export AR=gcc-ar
export RANLIB=gcc-ranlib
export NM=gcc-nm
export CFLAGS="$CFLAGS -O3 -falign-functions=32 -ffat-lto-objects -flto=4 -fno-math-errno -fno-semantic-interposition -fno-trapping-math "
export FCFLAGS="$FFLAGS -O3 -falign-functions=32 -ffat-lto-objects -flto=4 -fno-math-errno -fno-semantic-interposition -fno-trapping-math "
export FFLAGS="$FFLAGS -O3 -falign-functions=32 -ffat-lto-objects -flto=4 -fno-math-errno -fno-semantic-interposition -fno-trapping-math "
export CXXFLAGS="$CXXFLAGS -O3 -falign-functions=32 -ffat-lto-objects -flto=4 -fno-math-errno -fno-semantic-interposition -fno-trapping-math "
export CFLAGS="$CFLAGS -O3 -falign-functions=32 -fno-lto -fno-math-errno -fno-semantic-interposition -fno-trapping-math "
export FCFLAGS="$FFLAGS -O3 -falign-functions=32 -fno-lto -fno-math-errno -fno-semantic-interposition -fno-trapping-math "
export FFLAGS="$FFLAGS -O3 -falign-functions=32 -fno-lto -fno-math-errno -fno-semantic-interposition -fno-trapping-math "
export CXXFLAGS="$CXXFLAGS -O3 -falign-functions=32 -fno-lto -fno-math-errno -fno-semantic-interposition -fno-trapping-math "
make %{?_smp_mflags}


Expand Down
2 changes: 1 addition & 1 deletion options.conf
Expand Up @@ -58,7 +58,7 @@ use_avx512 = false
# add clang flags
use_clang = false
# configure build for lto
use_lto = true
use_lto = false
# require package verification for build
verify_required = false

0 comments on commit 51c5850

Please sign in to comment.