Summary: | sys-devel/gcc: fails to cross-compile with "The directory that should contain system headers does not exist: /usr/lib/gcc/armv7a-unknown-linux-musleabihf/13/include" (make[2]: *** [Makefile:3308: stmp-fixinc] Error) | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Sam James <sam> |
Component: | Current packages | Assignee: | Gentoo Toolchain Maintainers <toolchain> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | herrtimson, mike, praveen |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
See Also: |
https://bugs.gentoo.org/show_bug.cgi?id=925204 https://bugs.gentoo.org/show_bug.cgi?id=926059 https://bugs.gentoo.org/show_bug.cgi?id=932195 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115416 |
||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: |
build.log.xz
cross-x86_64-w64-mingw32-gcc-stage1.log.xz cross-x86_64-w64-mingw32-gcc-stage1.log.xz |
Description
Sam James
2023-04-26 13:52:59 UTC
Something probably went wrong in https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=be9dd80f9334800300a80268dbb92cf3fafcfcf8 ... or maybe https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=59e4c98173a79fcaa2c33253261409f38856c384, actually. The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=79519252e88f8ad8c8ddf627ff9a473e99222e7b commit 79519252e88f8ad8c8ddf627ff9a473e99222e7b Author: Sam James <sam@gentoo.org> AuthorDate: 2023-04-26 14:13:21 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2023-04-26 14:13:56 +0000 sys-devel/gcc: fix 13 cross builds w/ fixincludes Add workaround for now. Bug: https://bugs.gentoo.org/905118 Signed-off-by: Sam James <sam@gentoo.org> .../gcc/files/gcc-13-fix-cross-fixincludes.patch | 19 +++++++++++++++++++ sys-devel/gcc/gcc-13.1.0-r1.ebuild | 1 + 2 files changed, 20 insertions(+) The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=456eee6e374b50a4d9108a642ca29c5573ac5cb8 commit 456eee6e374b50a4d9108a642ca29c5573ac5cb8 Author: Sam James <sam@gentoo.org> AuthorDate: 2024-02-19 05:05:19 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2024-02-19 05:05:36 +0000 sys-devel/gcc: drop obsolete cross fixincludes patch for 13 We should be able to do this now after 0b75d3ce0bae8240c28c6a8f191f5130548f8475. Bug: https://bugs.gentoo.org/905118 Signed-off-by: Sam James <sam@gentoo.org> .../gcc/files/gcc-13-fix-cross-fixincludes.patch | 19 ------------------- sys-devel/gcc/gcc-13.2.1_p20230826.ebuild | 3 +-- sys-devel/gcc/gcc-13.2.1_p20231216.ebuild | 3 +-- sys-devel/gcc/gcc-13.2.1_p20240113-r1.ebuild | 1 - sys-devel/gcc/gcc-13.2.1_p20240120.ebuild | 1 - sys-devel/gcc/gcc-13.2.1_p20240127.ebuild | 1 - sys-devel/gcc/gcc-13.2.1_p20240203.ebuild | 1 - sys-devel/gcc/gcc-13.2.1_p20240210.ebuild | 1 - sys-devel/gcc/gcc-13.2.1_p20240217.ebuild | 1 - 9 files changed, 2 insertions(+), 29 deletions(-) https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0b75d3ce0bae8240c28c6a8f191f5130548f8475 commit 0b75d3ce0bae8240c28c6a8f191f5130548f8475 Author: Sam James <sam@gentoo.org> AuthorDate: 2024-02-19 05:02:09 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2024-02-19 05:05:32 +0000 toolchain.eclass: rework fixincludes again * Only run fixincludes for >= GCC 13 with <sys-libs/glibc-2.38. * Refactor the logic while at it to make it easier to control (as we do some bits depending on it in src_install). Doing this after getting for cross: ``` The directory (BUILD_SYSTEM_HEADER_DIR) that should contain system headers does not exist: /usr/lib/gcc/aarch64_be-unknown-linux-gnu/14/include make[2]: *** [Makefile:3448: stmp-fixinc] Error 1 make[2]: *** Waiting for unfinished jobs.... ``` This should also let us drop the patch for bug #905118 now. Bug: https://bugs.gentoo.org/905118 Bug: https://gcc.gnu.org/PR107128 Signed-off-by: Sam James <sam@gentoo.org> eclass/toolchain.eclass | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4ccbec18b76ff3c48f3d32f1b1760ca568ddc615 commit 4ccbec18b76ff3c48f3d32f1b1760ca568ddc615 Author: Sam James <sam@gentoo.org> AuthorDate: 2024-02-19 05:07:11 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2024-02-19 05:07:11 +0000 toolchain.eclass: explicitly disable fixincludes for cross too Just in case, although the condition is unlikely there now. Bug: https://bugs.gentoo.org/905118 Signed-off-by: Sam James <sam@gentoo.org> eclass/toolchain.eclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0c5af65cfb92b7702f170999488c970fc278d9a2 commit 0c5af65cfb92b7702f170999488c970fc278d9a2 Author: Sam James <sam@gentoo.org> AuthorDate: 2024-02-23 07:16:07 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2024-02-23 07:46:08 +0000 toolchain.eclass: allow fixincludes for mingw & special MIPS target config/i386/t-cygming always sets STMP_FIXINC regardless of the configure arg for fixincludes, so don't disable it there. The only other case is config/mips/t-sdemtk which I've handled too. Exposed by 0b75d3ce0bae8240c28c6a8f191f5130548f8475. Bug: https://bugs.gentoo.org/905118 Closes: https://bugs.gentoo.org/925204 Signed-off-by: Sam James <sam@gentoo.org> eclass/toolchain.eclass | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) I am still seeing this issue for MinGW on the gentoo Live ISO with: -rw-r--r-- 1 root root 32 Mar 2 00:40 /var/db/repos/gentoo/metadata/timestamp Running `crossdev --target x86_64-w64-mingw32` after setting up the overlay (as in the wiki) fails with the same error. Will attach logs shortly. Created attachment 886563 [details]
cross-x86_64-w64-mingw32-gcc-stage1.log.xz
Can you file a new bug please? Thanks. (Also, I can't decompress that file.) Created attachment 886564 [details]
cross-x86_64-w64-mingw32-gcc-stage1.log.xz
The previous xz got garbled somehow. Here's another.
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e4dfb164264174461dd6ac8a826fb01b00e5dbf8 commit e4dfb164264174461dd6ac8a826fb01b00e5dbf8 Author: Sam James <sam@gentoo.org> AuthorDate: 2024-03-07 18:36:18 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2024-03-07 18:36:18 +0000 Revert "sys-devel/gcc: drop obsolete cross fixincludes patch for 13" This reverts commit 456eee6e374b50a4d9108a642ca29c5573ac5cb8. Restore the fixincludes revert. The situation has improved a bit though, because we now only run fixincludes when it's truly needed, so having this patch is less risky to begin with. Caveat emptor for trying to remove this in future: make sure to test clean builds without mingw already built, and with. Bug: https://bugs.gentoo.org/905118 Bug: https://bugs.gentoo.org/925204 Closes: https://bugs.gentoo.org/926059 Signed-off-by: Sam James <sam@gentoo.org> .../gcc/files/gcc-13-fix-cross-fixincludes.patch | 19 +++++++++++++++++++ sys-devel/gcc/gcc-12.3.1_p20240223.ebuild | 1 + sys-devel/gcc/gcc-12.3.1_p20240301.ebuild | 1 + sys-devel/gcc/gcc-13.2.1_p20240113-r1.ebuild | 1 + sys-devel/gcc/gcc-13.2.1_p20240210.ebuild | 1 + sys-devel/gcc/gcc-13.2.1_p20240224.ebuild | 1 + sys-devel/gcc/gcc-13.2.1_p20240302.ebuild | 1 + sys-devel/gcc/gcc-14.0.1_pre20240225.ebuild | 1 + sys-devel/gcc/gcc-14.0.1_pre20240303-r1.ebuild | 1 + 9 files changed, 27 insertions(+) The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=37b5a2fe628275e617272c5094e7dfc8cb9f0d4e commit 37b5a2fe628275e617272c5094e7dfc8cb9f0d4e Author: Sam James <sam@gentoo.org> AuthorDate: 2024-06-10 15:37:45 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2024-06-10 15:38:19 +0000 sys-devel/gcc: add bug ref to fixincludes issue MacPorts folks have kindly reported the issue upstream so add a ref to the bug (https://gcc.gnu.org/PR115416). Bug: https://gcc.gnu.org/PR115416 Bug: https://bugs.gentoo.org/905118 Bug: https://bugs.gentoo.org/925204 Bug: https://bugs.gentoo.org/926059 Signed-off-by: Sam James <sam@gentoo.org> sys-devel/gcc/files/gcc-13-fix-cross-fixincludes.patch | 1 + 1 file changed, 1 insertion(+) |