mirror of
https://github.com/flatcar/scripts.git
synced 2026-05-05 04:06:33 +02:00
eclass/toolchain-funcs: Sync with Gentoo
It's from Gentoo commit 99ab39a4c9e7f7c1f6277032ea391f6045ffc751. Signed-off-by: Flatcar Buildbot <buildbot@flatcar-linux.org>
This commit is contained in:
parent
ee406c5f1d
commit
f82d378e68
@ -1,10 +1,10 @@
|
||||
# Copyright 2002-2025 Gentoo Authors
|
||||
# Copyright 2002-2026 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
# @ECLASS: toolchain-funcs.eclass
|
||||
# @MAINTAINER:
|
||||
# Toolchain Ninjas <toolchain@gentoo.org>
|
||||
# @SUPPORTED_EAPIS: 7 8
|
||||
# @SUPPORTED_EAPIS: 7 8 9
|
||||
# @BLURB: functions to query common info about the toolchain
|
||||
# @DESCRIPTION:
|
||||
# The toolchain-funcs aims to provide a complete suite of functions
|
||||
@ -17,7 +17,7 @@ if [[ -z ${_TOOLCHAIN_FUNCS_ECLASS} ]]; then
|
||||
_TOOLCHAIN_FUNCS_ECLASS=1
|
||||
|
||||
case ${EAPI} in
|
||||
7|8) ;;
|
||||
7|8|9) ;;
|
||||
*) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;;
|
||||
esac
|
||||
|
||||
@ -1248,7 +1248,7 @@ tc-is-lto() {
|
||||
;;
|
||||
gcc)
|
||||
$(tc-getCC) ${CFLAGS} -c -o "${f}" -x c - <<<"" || die
|
||||
[[ $($(tc-getREADELF) -S "${f}") == *.gnu.lto* ]] && ret=0
|
||||
[[ $($(tc-getOBJDUMP) -s "${f}") == *.gnu.lto* ]] && ret=0
|
||||
;;
|
||||
esac
|
||||
rm -f "${f}" || die
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user