Hi! I'm getting link error… > x86_64-pc-linux-gnu-g++: error: l1-cache-size=32: linker input file not found: No such file or directory …when trying to install x11-libs/wxGTK-3.2.2.1-r1. The build system apparently has trouble with my CXXFLAGS: > # portageq envvar CXXFLAGS > -march=sandybridge -maes --param l1-cache-line-size=64 --param l1-cache-size=32 --param l2-cache-size=3072 -O2 -pipe -frecord-gcc-switches I'll attach the build log in a minute.
Created attachment 859394 [details] Build log
Try with --param=l1-cache-line-size=64 etc. (frankly, I had no idea you could use a space there) It *should* be equivalent if I'm understanding the space case right.
Good idea about "=", seems to work judging from: > # echo 'int main() { return 0; }' > main.c > # gcc --param=l1-cache-line-size=64 main.c I guess the ebuild should filter "--param [..]" with spaces though, all other ebuilds handle them fine.
sigh... dnl Set the flags to be used for the library build itself using the flag names dnl used everywhere above. dnl dnl Also get rid of duplicates in the flags, which results in dramatically dnl shorter build logs and so is well worth it (but preserve some special dnl flags which are explicitly allowed to occur multiple times, as all their dnl occurrences must be preserved). dedup_flags() { printf "%s " "$@" | awk 'BEGIN { RS=" "; ORS=" " } { if ($0=="-arch" || $0=="-framework" || !seen[[$0]]++) print }' }
Nice finding! > # dedup_flags --param l1-cache-line-size=64 --param l1-cache-size=32 > --param l1-cache-line-size=64 l1-cache-size=32 That's it, confirming. I guess we could either patch the whole thing out or add ' || $0=="--param"', either upstream first or in Gentoo. My guess is that the list will not be complete after adding --param, e.g. linker flag -l seems to allow pattern "-l<space>name" also, from what I can see from GCC 11. So better patch out altogether? What do you think?
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=23a6d260ee7a72fc42d36d6311a137fa3c55bcdc commit 23a6d260ee7a72fc42d36d6311a137fa3c55bcdc Author: Arsen Arsenović <arsen@gentoo.org> AuthorDate: 2023-04-02 11:34:00 +0000 Commit: Arsen Arsenović <arsen@gentoo.org> CommitDate: 2023-04-02 19:57:13 +0000 x11-libs/wxGTK: Remove broken flag deduplication logic in 3.2.2.1 Closes: https://bugs.gentoo.org/903668 Signed-off-by: Arsen Arsenović <arsen@gentoo.org> .../files/wxGTK-3.2.2.1-dont-break-flags.patch | 48 ++++++++++++++++++++++ x11-libs/wxGTK/wxGTK-3.2.2.1-r1.ebuild | 1 + 2 files changed, 49 insertions(+)