games-util/xone: Set KERNEL_CC to clang uncondtionally, fix ld.lld
* Final fix for Ref #43 Signed-off-by: Alfred Wingate <parona@protonmail.com>
This commit is contained in:
parent
a42d120419
commit
0f558c188d
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
EAPI=8
|
EAPI=8
|
||||||
|
|
||||||
inherit toolchain-funcs linux-mod
|
inherit linux-mod
|
||||||
|
|
||||||
DESCRIPTION="Linux kernel driver for Xbox One and Xbox Series X|S accessories"
|
DESCRIPTION="Linux kernel driver for Xbox One and Xbox Series X|S accessories"
|
||||||
|
|
||||||
@ -45,18 +45,17 @@ pkg_setup() {
|
|||||||
BUILD_PARAMS="KERNEL_DIR=${KERNEL_DIR} V=1"
|
BUILD_PARAMS="KERNEL_DIR=${KERNEL_DIR} V=1"
|
||||||
|
|
||||||
# TODO: more robust solution in linux-mod would be ideal
|
# TODO: more robust solution in linux-mod would be ideal
|
||||||
KERNEL_CC="$(tc-getCC)"
|
|
||||||
if linux_chkconfig_present CC_IS_CLANG; then
|
if linux_chkconfig_present CC_IS_CLANG; then
|
||||||
tc-is-clang || : "${KERNEL_CC:=${CHOST}-clang}"
|
"${KERNEL_CC:=${CHOST}-clang}"
|
||||||
if linux_chkconfig_present LD_IS_LLD; then
|
if linux_chkconfig_present LD_IS_LLD; then
|
||||||
: "${KERNEL_LD:=ld.ldd}"
|
: "${KERNEL_LD:=ld.lld}"
|
||||||
if linux_chkconfig_present LTO_CLANG_THIN; then
|
if linux_chkconfig_present LTO_CLANG_THIN; then
|
||||||
BUILD_PARAMS+=" ldflags-y=--thinlto-cache-dir= LDFLAGS_MODULE=--thinlto-cache-dir="
|
BUILD_PARAMS+=" ldflags-y=--thinlto-cache-dir= LDFLAGS_MODULE=--thinlto-cache-dir="
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
BUILD_PARAMS+=" CC=${KERNEL_CC} ${KERNEL_LD:+LD=${KERNEL_LD}}"
|
BUILD_PARAMS+=" ${KERNEL_CC:+CC=${KERNEL_CC}} ${KERNEL_LD:+LD=${KERNEL_LD}}"
|
||||||
}
|
}
|
||||||
|
|
||||||
src_unpack() {
|
src_unpack() {
|
||||||
|
Loading…
Reference in New Issue
Block a user