mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-24 11:16:51 +00:00
use a distinct sysroot per toolchain
Using one for all yields all sorts of issues: build/gcc-aarch64-14.2.0/.x86_64-linux-gnu/./gcc/xgcc -Bbuild/gcc-aarch64-14.2.0/.x86_64-linux-gnu/./gcc/ -Btoolchain/aarch64-none-elf/bin/ -Btoolchain/aarch64-none-elf/lib/ -isystem toolchain/aarch64-none-elf/include -isystem toolchain/aarch64-none-elf/sys-include -g -O2 -O2 -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include -g -DIN_LIBGCC2 -fbuilding-libgcc -fno-stack-protector -Dinhibit_libc -I. -I. -I../.././gcc -Ibuild/gcc-aarch64-14.2.0/libgcc -Ibuild/gcc-aarch64-14.2.0/libgcc/. -Ibuild/gcc-aarch64-14.2.0/libgcc/../gcc -Ibuild/gcc-aarch64-14.2.0/libgcc/../include -DHAVE_CC_TLS -o cpuinfo.o -MT cpuinfo.o -MD -MP -MF cpuinfo.dep -c build/gcc-aarch64-14.2.0/libgcc/config/aarch64/cpuinfo.c -fvisibility=hidden -DHIDE_EXPORTS In file included from toolchain/armv8a-libreelec-linux-gnueabihf/sysroot/usr/include/features.h:548, from toolchain/armv8a-libreelec-linux-gnueabihf/sysroot/usr/include/bits/libc-header-start.h:33, from toolchain/armv8a-libreelec-linux-gnueabihf/sysroot/usr/include/stdint.h:26, from build/gcc-aarch64-14.2.0/.x86_64-linux-gnu/gcc/include/stdint.h:9, from toolchain/armv8a-libreelec-linux-gnueabihf/sysroot/usr/include/elf.h:24, from toolchain/armv8a-libreelec-linux-gnueabihf/sysroot/usr/include/sys/auxv.h:22, from build/gcc-aarch64-14.2.0/libgcc/config/aarch64/cpuinfo.c:28: toolchain/armv8a-libreelec-linux-gnueabihf/sysroot/usr/include/gnu/stubs.h:7:11: fatal error: gnu/stubs-soft.h: No such file or directory 7 | # include <gnu/stubs-soft.h> | ^~~~~~~~~~~~~~~~~~ compilation terminated. Notice the mix of paths from two architectures. Additionally the armv8a fpu config leaks into aarch64.
This commit is contained in:
parent
4f29da4919
commit
a555d81121
@ -12,8 +12,7 @@ PKG_DEPENDS_UNPACK+=" binutils"
|
||||
PKG_PATCH_DIRS+=" $(get_pkg_directory binutils)/patches"
|
||||
|
||||
PKG_CONFIGURE_OPTS_HOST="--target=aarch64-none-elf \
|
||||
--with-sysroot=${SYSROOT_PREFIX} \
|
||||
--with-lib-path=${SYSROOT_PREFIX}/lib:${SYSROOT_PREFIX}/usr/lib \
|
||||
--with-sysroot=${TOOLCHAIN}/aarch64-none-elf/sysroot \
|
||||
--without-ppl \
|
||||
--enable-static \
|
||||
--without-cloog \
|
||||
@ -47,9 +46,5 @@ make_host() {
|
||||
}
|
||||
|
||||
makeinstall_host() {
|
||||
cp -v ../include/libiberty.h ${SYSROOT_PREFIX}/usr/include
|
||||
make -C libsframe install # bfd is reliant on libsframe
|
||||
make -C bfd install # fix parallel build with libctf requiring bfd
|
||||
# override the makeinfo binary with true - this does not build the documentation
|
||||
make MAKEINFO=true install
|
||||
}
|
||||
|
@ -12,8 +12,7 @@ PKG_DEPENDS_UNPACK+=" binutils"
|
||||
PKG_PATCH_DIRS+=" $(get_pkg_directory binutils)/patches"
|
||||
|
||||
PKG_CONFIGURE_OPTS_HOST="--target=arm-none-eabi \
|
||||
--with-sysroot=${SYSROOT_PREFIX} \
|
||||
--with-lib-path=${SYSROOT_PREFIX}/lib:${SYSROOT_PREFIX}/usr/lib \
|
||||
--with-sysroot=${TOOLCHAIN}/arm-none-eabi/sysroot \
|
||||
--without-ppl \
|
||||
--enable-static \
|
||||
--without-cloog \
|
||||
@ -47,9 +46,6 @@ make_host() {
|
||||
}
|
||||
|
||||
makeinstall_host() {
|
||||
cp -v ../include/libiberty.h ${SYSROOT_PREFIX}/usr/include
|
||||
make -C libsframe install # bfd is reliant on libsframe
|
||||
make -C bfd install # fix parallel build with libctf requiring bfd
|
||||
# override the makeinfo binary with true - this does not build the documentation
|
||||
make MAKEINFO=true install
|
||||
}
|
||||
|
@ -12,8 +12,7 @@ PKG_DEPENDS_UNPACK+=" binutils"
|
||||
PKG_PATCH_DIRS+=" $(get_pkg_directory binutils)/patches"
|
||||
|
||||
PKG_CONFIGURE_OPTS_HOST="--target=bpf \
|
||||
--with-sysroot=${SYSROOT_PREFIX} \
|
||||
--with-lib-path=${SYSROOT_PREFIX}/lib:${SYSROOT_PREFIX}/usr/lib \
|
||||
--with-sysroot=${TOOLCHAIN}/bpf/sysroot \
|
||||
--without-ppl \
|
||||
--enable-static \
|
||||
--without-cloog \
|
||||
@ -47,9 +46,6 @@ make_host() {
|
||||
}
|
||||
|
||||
makeinstall_host() {
|
||||
cp -v ../include/libiberty.h ${SYSROOT_PREFIX}/usr/include
|
||||
make -C libsframe install # bfd is reliant on libsframe
|
||||
make -C bfd install # fix parallel build with libctf requiring bfd
|
||||
# override the makeinfo binary with true - this does not build the documentation
|
||||
make MAKEINFO=true install
|
||||
}
|
||||
|
@ -12,8 +12,7 @@ PKG_DEPENDS_UNPACK+=" binutils"
|
||||
PKG_PATCH_DIRS+=" $(get_pkg_directory binutils)/patches"
|
||||
|
||||
PKG_CONFIGURE_OPTS_HOST="--target=or1k-none-elf \
|
||||
--with-sysroot=${SYSROOT_PREFIX} \
|
||||
--with-lib-path=${SYSROOT_PREFIX}/lib:${SYSROOT_PREFIX}/usr/lib \
|
||||
--with-sysroot=${TOOLCHAIN}/or1k-none-elf/sysroot \
|
||||
--without-ppl \
|
||||
--enable-static \
|
||||
--without-cloog \
|
||||
@ -47,8 +46,6 @@ make_host() {
|
||||
}
|
||||
|
||||
makeinstall_host() {
|
||||
cp -v ../include/libiberty.h ${SYSROOT_PREFIX}/usr/include
|
||||
make -C bfd install # fix parallel build with libctf requiring bfd
|
||||
# override the makeinfo binary with true - this does not build the documentation
|
||||
make MAKEINFO=true install
|
||||
}
|
||||
|
@ -16,7 +16,7 @@ if [ "${MOLD_SUPPORT}" = "yes" ]; then
|
||||
fi
|
||||
|
||||
PKG_CONFIGURE_OPTS_HOST="--target=aarch64-none-elf \
|
||||
--with-sysroot=${SYSROOT_PREFIX} \
|
||||
--with-sysroot=${TOOLCHAIN}/aarch64-none-elf/sysroot \
|
||||
--with-gmp=${TOOLCHAIN} \
|
||||
--with-mpfr=${TOOLCHAIN} \
|
||||
--with-mpc=${TOOLCHAIN} \
|
||||
@ -57,6 +57,13 @@ unpack() {
|
||||
tar --strip-components=1 -xf ${SOURCES}/gcc/gcc-${PKG_VERSION}.tar.xz -C ${PKG_BUILD}
|
||||
}
|
||||
|
||||
pre_configure_host() {
|
||||
unset CPPFLAGS
|
||||
unset CFLAGS
|
||||
unset CXXFLAGS
|
||||
unset LDFLAGS
|
||||
}
|
||||
|
||||
post_makeinstall_host() {
|
||||
PKG_GCC_PREFIX="${TOOLCHAIN}/bin/aarch64-none-elf-"
|
||||
GCC_VERSION=$(${PKG_GCC_PREFIX}gcc -dumpversion)
|
||||
|
@ -16,7 +16,7 @@ if [ "${MOLD_SUPPORT}" = "yes" ]; then
|
||||
fi
|
||||
|
||||
PKG_CONFIGURE_OPTS_HOST="--target=arm-none-eabi \
|
||||
--with-sysroot=${SYSROOT_PREFIX} \
|
||||
--with-sysroot=${TOOLCHAIN}/arm-none-eabi/sysroot \
|
||||
--with-gmp=${TOOLCHAIN} \
|
||||
--with-mpfr=${TOOLCHAIN} \
|
||||
--with-mpc=${TOOLCHAIN} \
|
||||
@ -56,6 +56,13 @@ unpack() {
|
||||
tar --strip-components=1 -xf ${SOURCES}/gcc/gcc-${PKG_VERSION}.tar.xz -C ${PKG_BUILD}
|
||||
}
|
||||
|
||||
pre_configure_host() {
|
||||
unset CPPFLAGS
|
||||
unset CFLAGS
|
||||
unset CXXFLAGS
|
||||
unset LDFLAGS
|
||||
}
|
||||
|
||||
post_makeinstall_host() {
|
||||
PKG_GCC_PREFIX="${TOOLCHAIN}/bin/arm-none-eabi-"
|
||||
GCC_VERSION=$(${PKG_GCC_PREFIX}gcc -dumpversion)
|
||||
|
@ -16,7 +16,7 @@ if [ "${MOLD_SUPPORT}" = "yes" ]; then
|
||||
fi
|
||||
|
||||
PKG_CONFIGURE_OPTS_HOST="--target=bpf \
|
||||
--with-sysroot=${SYSROOT_PREFIX} \
|
||||
--with-sysroot=${TOOLCHAIN}/bpf/sysroot \
|
||||
--with-gmp=${TOOLCHAIN} \
|
||||
--with-mpfr=${TOOLCHAIN} \
|
||||
--with-mpc=${TOOLCHAIN} \
|
||||
@ -56,3 +56,10 @@ unpack() {
|
||||
mkdir -p ${PKG_BUILD}
|
||||
tar --strip-components=1 -xf ${SOURCES}/gcc/gcc-${PKG_VERSION}.tar.xz -C ${PKG_BUILD}
|
||||
}
|
||||
|
||||
pre_configure_host() {
|
||||
unset CPPFLAGS
|
||||
unset CFLAGS
|
||||
unset CXXFLAGS
|
||||
unset LDFLAGS
|
||||
}
|
||||
|
@ -16,7 +16,7 @@ if [ "${MOLD_SUPPORT}" = "yes" ]; then
|
||||
fi
|
||||
|
||||
PKG_CONFIGURE_OPTS_HOST="--target=or1k-none-elf \
|
||||
--with-sysroot=${SYSROOT_PREFIX} \
|
||||
--with-sysroot=${TOOLCHAIN}/or1k-none-elf/sysroot \
|
||||
--with-gmp=${TOOLCHAIN} \
|
||||
--with-mpfr=${TOOLCHAIN} \
|
||||
--with-mpc=${TOOLCHAIN} \
|
||||
@ -57,6 +57,13 @@ unpack() {
|
||||
tar --strip-components=1 -xf ${SOURCES}/gcc/gcc-${PKG_VERSION}.tar.xz -C ${PKG_BUILD}
|
||||
}
|
||||
|
||||
pre_configure_host() {
|
||||
unset CPPFLAGS
|
||||
unset CFLAGS
|
||||
unset CXXFLAGS
|
||||
unset LDFLAGS
|
||||
}
|
||||
|
||||
post_makeinstall_host() {
|
||||
PKG_GCC_PREFIX="${TOOLCHAIN}/bin/or1k-none-elf-"
|
||||
GCC_VERSION=$(${PKG_GCC_PREFIX}gcc -dumpversion)
|
||||
|
Loading…
x
Reference in New Issue
Block a user