I am having problems with enabling clang compiler in my CLion. I added following entries in my CMakeLists.txt
set(CMAKE_CXX_COMPILER "/usr/bin/clang-3.4") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -stdlib=libc++")
When I compile my code (empty main with #include ) I constantly get folllowing error:
/home/igleyy/ClionProjects/tasks/main.cpp:1:10: fatal error: 'chrono' file not found #include <chrono> ^ 1 error generated.
It seems that standard C++ headers for clang cannot be found. How can I fix this? It works fine when I use g++ compiler.
Aucun commentaire:
Enregistrer un commentaire