Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 688730 - dev-libs/flatbuffers-1.10.0 - CMake Error at /usr/share/cmake/Modules/CMakeTestCCompiler.cmake:60 (message): The C compiler "/usr/bin/x86_64-pc-linux-gnu-clang" is not able to compile a simple test program. x86_64-pc-linux-gnu-clang: error: invalid argume
Summary: dev-libs/flatbuffers-1.10.0 - CMake Error at /usr/share/cmake/Modules/CMakeTe...
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo KDE team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: systemwide-clang
  Show dependency tree
 
Reported: 2019-06-26 06:18 UTC by Michael Martis
Modified: 2019-06-27 11:46 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
Output of `emerge dev-libs/flatbuffers` (emerge-flatbuffers.log,5.44 KB, text/plain)
2019-06-26 06:18 UTC, Michael Martis
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Martis 2019-06-26 06:18:13 UTC
Created attachment 580962 [details]
Output of `emerge dev-libs/flatbuffers`

Configuration of flatbuffers-1.10.0 with Clang fails with the following error:
> error: invalid argument '-std=c++11' not allowed with 'C'
when checking for a working C compiler.

IIUC this is because Clang is stricter than GCC with compile flags; it doesn't allow a C++ standard to be specified when compiling C code.

A fix would be to replace the line
> append-cppflags -std=c++11
with
> append-cxxflags -std=c++11
in src_configure, as CXX flags are passed exactly when C++ code is being compiled.

Attached are the emerge logs for Chromium OS (which uses Clang).
Comment 1 Andreas Sturmlechner gentoo-dev 2019-06-27 11:46:09 UTC
Just use 1.11.0 instead.