Summary: | www-client/chromium-135.0.7049.41: pkg_pretend fails: x86_64-pc-linux-gnu-gcc: error: unrecognized command-line option | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Blacktea Hamburger <blackteahamburger> |
Component: | Current packages | Assignee: | Chromium Project <chromium> |
Status: | UNCONFIRMED --- | ||
Severity: | normal | CC: | blackteahamburger, kangie |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: |
build.log
emerge --info |
Created attachment 923279 [details]
emerge --info
|
Created attachment 923278 [details] build.log I set the following flags: CFLAGS="-march=native -O2 -mllvm=-polly -pipe" CXXFLAGS="${CFLAGS}" FCFLAGS="${CFLAGS}" FFLAGS="${CFLAGS}" LDFLAGS="-Wl,-O1 -Wl,--as-needed" This error occurs when there are options that gcc does not recognize in CFLAGS only. This is because tc-is-lto is called in pkg_pretend, which calls the compiler to compile to confirm whether tc is lto. But clang has not yet been forced, so it call the default compiler gcc, which results in not being able to specify clang-specific options in CFLAGS (reasonable if custom-cflags is set), unless to force clang manually: CC="clang" CXX="clang++" CPP="clang-cpp" AR="llvm-ar" NM="llvm-nm" RANLIB="llvm-ranlib" This is annoying because forcing clang in the ebuild would have been enough.