mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-11-09 06:37:10 -08:00
37dded9b48c93a67b9a32b5eca2b1ef0fc6e8b9e
Using lu_zero's repro instructions ... ``` $ crossdev -C riscv64 $ crossdev riscv64 -s3 $ find /usr -name pthread.h # to make sure glibc isn't doing something strange $ riscv64-unknown-linux-gnu-gcc -E - <<<"#include <pthread.h>" # this should work $ crossdev -C riscv64 $ crossdev riscv64 -s3 --g 15.0.1_pre20250418-r1 $ find /usr -name pthread.h # to make sure glibc isn't doing something strange $ riscv64-unknown-linux-gnu-gcc -E - <<<"#include <pthread.h>" # this should fail because it looks only on the compiler dir ``` ... we see that openmp.h is missing and --disable-libgomp was passed because our test in toolchain.eclass was failing: ``` # Make sure target has pthreads support: bug #326757, bug #335883 # There shouldn't be a chicken & egg problem here as openmp won't # build without a C library, and you can't build that w/o # already having a compiler... if ! is_crosscompile || $(tc-getCPP ${CTARGET}) -E - <<<"#include <pthread.h>" >& /dev/null ; then confgcc+=( $(use_enable openmp libgomp) ) else # Force disable as the configure script can be dumb, bug #359855 confgcc+=( --disable-libgomp ) fi ``` Adding in the gcc-13-fix-cross-fixincludes.patch patch we're already using for other versions fixes it by adding /usr/${CHOST}/usr/include in the search path of the stage1 crossdev GCC. We may still want to add a workaround in toolchain.eclass like: ``` - $(tc-getCPP ${CTARGET}) -E - <<<"#include <pthread.h>" >& /dev/null + $(tc-getCPP ${CTARGET}) -I/usr/${CTARGET}/usr/include -E - <<<"#include <pthread.h>" >& /dev/null ``` Or maybe add some warning if it failed when weren't expecting it to on some targets. I'll move this patch to gcc-patches at some point. Bug: https://gcc.gnu.org/PR115416 Bug: https://bugs.gentoo.org/326757 Bug: https://bugs.gentoo.org/335883 Bug: https://bugs.gentoo.org/905118 Bug: https://bugs.gentoo.org/909453 Bug: https://bugs.gentoo.org/925204 Bug: https://bugs.gentoo.org/926059 Thanks-to: Luca Barbato <lu_zero@gentoo.org> Signed-off-by: Sam James <sam@gentoo.org>
…
…
…
…
…
Description
No description provided
9.8 GiB
Languages
Shell
98%
Roff
1.3%
Emacs Lisp
0.2%
C
0.1%