mirror of
https://github.com/flatcar/scripts.git
synced 2025-11-17 08:31:33 +01:00
sys-devel/binutils: Sync with Gentoo
It's from Gentoo commit 68466c8b5bda1cbf82e364763c42c7c9df1dfff0.
This commit is contained in:
parent
8dd4e80f71
commit
6bdec3b6af
@ -281,6 +281,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}"
|
cd "${MY_BUILDDIR}"
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug 637066
|
# bug 637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -274,6 +274,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}"
|
cd "${MY_BUILDDIR}"
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug 637066
|
# bug 637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -275,6 +275,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}"
|
cd "${MY_BUILDDIR}"
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug 637066
|
# bug 637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -299,6 +299,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}"
|
cd "${MY_BUILDDIR}"
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug 637066
|
# bug 637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -294,6 +294,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}"
|
cd "${MY_BUILDDIR}"
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug 637066
|
# bug 637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -313,6 +313,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}"
|
cd "${MY_BUILDDIR}"
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug 637066
|
# bug 637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -321,6 +321,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}"
|
cd "${MY_BUILDDIR}"
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug 637066
|
# bug 637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -336,6 +336,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}" || die
|
cd "${MY_BUILDDIR}" || die
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug #637066
|
# bug #637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -348,6 +348,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}" || die
|
cd "${MY_BUILDDIR}" || die
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug #637066
|
# bug #637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -366,6 +366,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}" || die
|
cd "${MY_BUILDDIR}" || die
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug #637066
|
# bug #637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -366,6 +366,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}" || die
|
cd "${MY_BUILDDIR}" || die
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug #637066
|
# bug #637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -371,6 +371,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}" || die
|
cd "${MY_BUILDDIR}" || die
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug #637066
|
# bug #637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -32,7 +32,7 @@ else
|
|||||||
[[ -z ${PATCH_VER} ]] || SRC_URI="${SRC_URI}
|
[[ -z ${PATCH_VER} ]] || SRC_URI="${SRC_URI}
|
||||||
https://dev.gentoo.org/~${PATCH_DEV}/distfiles/binutils-${PATCH_BINUTILS_VER}-patches-${PATCH_VER}.tar.xz"
|
https://dev.gentoo.org/~${PATCH_DEV}/distfiles/binutils-${PATCH_BINUTILS_VER}-patches-${PATCH_VER}.tar.xz"
|
||||||
SLOT=$(ver_cut 1-2)
|
SLOT=$(ver_cut 1-2)
|
||||||
KEYWORDS="~alpha amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
|
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
#
|
#
|
||||||
@ -371,6 +371,10 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}" || die
|
cd "${MY_BUILDDIR}" || die
|
||||||
|
|
||||||
|
# https://sourceware.org/PR31327
|
||||||
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
# bug #637066
|
# bug #637066
|
||||||
filter-flags -Wall -Wreturn-type
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
|||||||
@ -270,7 +270,7 @@ src_configure() {
|
|||||||
$(use_with zstd)
|
$(use_with zstd)
|
||||||
|
|
||||||
# Disable modules that are in a combined binutils/gdb tree, bug #490566
|
# Disable modules that are in a combined binutils/gdb tree, bug #490566
|
||||||
--disable-{gdb,libdecnumber,readline,sim}
|
--disable-{gdb,gdbserver,libbacktrace,libdecnumber,readline,sim}
|
||||||
# Strip out broken static link flags: https://gcc.gnu.org/PR56750
|
# Strip out broken static link flags: https://gcc.gnu.org/PR56750
|
||||||
--without-stage1-ldflags
|
--without-stage1-ldflags
|
||||||
# Change SONAME to avoid conflict across {native,cross}/binutils, binutils-libs. bug #666100
|
# Change SONAME to avoid conflict across {native,cross}/binutils, binutils-libs. bug #666100
|
||||||
@ -333,10 +333,20 @@ src_configure() {
|
|||||||
)
|
)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if use test || { use pgo && tc-is-lto ; } ; then
|
||||||
|
# -Wa,* needs to be consistent everywhere or lto-wrapper will complain
|
||||||
|
filter-flags '-Wa,*'
|
||||||
|
fi
|
||||||
|
|
||||||
if ! is_cross ; then
|
if ! is_cross ; then
|
||||||
myconf+=( $(use_enable pgo pgo-build lto) )
|
myconf+=( $(use_enable pgo pgo-build $(tc-is-lto && echo "lto" || echo "yes")) )
|
||||||
|
|
||||||
if use pgo ; then
|
if use pgo ; then
|
||||||
|
# We let configure handle it for us because it has to run
|
||||||
|
# the testsuite later on for profiling, and LTO isn't compatible
|
||||||
|
# with the testsuite.
|
||||||
|
filter-lto
|
||||||
|
|
||||||
export BUILD_CFLAGS="${CFLAGS}"
|
export BUILD_CFLAGS="${CFLAGS}"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
@ -374,10 +384,28 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}" || die
|
cd "${MY_BUILDDIR}" || die
|
||||||
|
|
||||||
# bug #637066
|
# https://sourceware.org/PR31327
|
||||||
filter-flags -Wall -Wreturn-type
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
emake -k check
|
(
|
||||||
|
# Tests don't expect LTO
|
||||||
|
filter-lto
|
||||||
|
|
||||||
|
# lto-wrapper warnings which confuse tests
|
||||||
|
filter-flags '-Wa,*'
|
||||||
|
|
||||||
|
# bug #637066
|
||||||
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
emake -k check \
|
||||||
|
CFLAGS_FOR_TARGET="${CFLAGS_FOR_TARGET:-${CFLAGS}}" \
|
||||||
|
CXXFLAGS_FOR_TARGET="${CXXFLAGS_FOR_TARGET:-${CXXFLAGS}}" \
|
||||||
|
LDFLAGS_FOR_TARGET="${LDFLAGS_FOR_TARGET:-${LDFLAGS}}" \
|
||||||
|
CFLAGS="${CFLAGS}" \
|
||||||
|
CXXFLAGS="${CXXFLAGS}" \
|
||||||
|
LDFLAGS="${LDFLAGS}"
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
src_install() {
|
src_install() {
|
||||||
|
|||||||
@ -270,7 +270,7 @@ src_configure() {
|
|||||||
$(use_with zstd)
|
$(use_with zstd)
|
||||||
|
|
||||||
# Disable modules that are in a combined binutils/gdb tree, bug #490566
|
# Disable modules that are in a combined binutils/gdb tree, bug #490566
|
||||||
--disable-{gdb,libdecnumber,readline,sim}
|
--disable-{gdb,gdbserver,libbacktrace,libdecnumber,readline,sim}
|
||||||
# Strip out broken static link flags: https://gcc.gnu.org/PR56750
|
# Strip out broken static link flags: https://gcc.gnu.org/PR56750
|
||||||
--without-stage1-ldflags
|
--without-stage1-ldflags
|
||||||
# Change SONAME to avoid conflict across {native,cross}/binutils, binutils-libs. bug #666100
|
# Change SONAME to avoid conflict across {native,cross}/binutils, binutils-libs. bug #666100
|
||||||
@ -333,10 +333,20 @@ src_configure() {
|
|||||||
)
|
)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if use test || { use pgo && tc-is-lto ; } ; then
|
||||||
|
# -Wa,* needs to be consistent everywhere or lto-wrapper will complain
|
||||||
|
filter-flags '-Wa,*'
|
||||||
|
fi
|
||||||
|
|
||||||
if ! is_cross ; then
|
if ! is_cross ; then
|
||||||
myconf+=( $(use_enable pgo pgo-build lto) )
|
myconf+=( $(use_enable pgo pgo-build $(tc-is-lto && echo "lto" || echo "yes")) )
|
||||||
|
|
||||||
if use pgo ; then
|
if use pgo ; then
|
||||||
|
# We let configure handle it for us because it has to run
|
||||||
|
# the testsuite later on for profiling, and LTO isn't compatible
|
||||||
|
# with the testsuite.
|
||||||
|
filter-lto
|
||||||
|
|
||||||
export BUILD_CFLAGS="${CFLAGS}"
|
export BUILD_CFLAGS="${CFLAGS}"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
@ -374,10 +384,28 @@ src_compile() {
|
|||||||
src_test() {
|
src_test() {
|
||||||
cd "${MY_BUILDDIR}" || die
|
cd "${MY_BUILDDIR}" || die
|
||||||
|
|
||||||
# bug #637066
|
# https://sourceware.org/PR31327
|
||||||
filter-flags -Wall -Wreturn-type
|
local -x XZ_OPT="-T1"
|
||||||
|
local -x XZ_DEFAULTS="-T1"
|
||||||
|
|
||||||
emake -k check
|
(
|
||||||
|
# Tests don't expect LTO
|
||||||
|
filter-lto
|
||||||
|
|
||||||
|
# lto-wrapper warnings which confuse tests
|
||||||
|
filter-flags '-Wa,*'
|
||||||
|
|
||||||
|
# bug #637066
|
||||||
|
filter-flags -Wall -Wreturn-type
|
||||||
|
|
||||||
|
emake -k check \
|
||||||
|
CFLAGS_FOR_TARGET="${CFLAGS_FOR_TARGET:-${CFLAGS}}" \
|
||||||
|
CXXFLAGS_FOR_TARGET="${CXXFLAGS_FOR_TARGET:-${CXXFLAGS}}" \
|
||||||
|
LDFLAGS_FOR_TARGET="${LDFLAGS_FOR_TARGET:-${LDFLAGS}}" \
|
||||||
|
CFLAGS="${CFLAGS}" \
|
||||||
|
CXXFLAGS="${CXXFLAGS}" \
|
||||||
|
LDFLAGS="${LDFLAGS}"
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
src_install() {
|
src_install() {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user