I am trying to build bkchaind . One build option is to use cmake, so I installed it using Homebrew (OSX 10.9.1). When I do cmake , I get:
[ 2%] Building C object json-rpc-cpp/src/jsonrpc/CMakeFiles/jsonrpcStatic.dir/connectors/mongoose.co error: invalid argument '-std=c++11' not allowed with 'C/ObjC'
I'm not sure why cmake will try to pass the C ++ - specific compiler option to the C / ObjC file. If I comment on this line in the main CMakeLists.txt file:
ADD_DEFINITIONS(-std=c++11)
then it no longer passes the flag to any file. However, C ++ files are really needed. How do I get cmake to enable a flag for C ++ files, but not for C files?
c ++ c ++ 11 build cmake
Claudiu
source share