![]() I've had a simmilar issue before while trying to set up my C++ tools on Windows with differnet compilers and build systems, so I think this is just related to CMake.The ns-3 project used Waf build system in the past, but it has moved toĬMake is very verbose and commands can be very long for basic operations. I'm using the stock C++ desktop workload with all default components selected in case that could be a problem. I've also tried including other standard libraries with the samae results to make sure it wasn't just iostream giving me trouble. And I just find it very weird that CMake just isn't able to locate the files anymore. I've looked into manually including the standard libraries manually, but I can't find them anywhere on my machine. ![]() (In case it matters: I incldue GLFW by using the CMAKE file that comes with it and using the add_subdirectory() command.) I've also tried not including GLFW again, but that doens't help either. Set(CMAKE_RUNTIME_OUTPUT_DIR $/include/Graphics Project root cmake_minimum_required (VERSION 3.19) It worked just fine yesterday, but when I opened the project after including GLFW it stopped being able to find the iostream library and shows the following error: Error (active) E0135 namespace "std" has no member "endl" Slash.exe (source\Slash.exe) - 圆4-Debug C:\Users\Daisy\source\repos\CMakeProject1\source\main.cpp 9Įrror (active) E0135 namespace "std" has no member "endl" Slash.exe (source\Slash.exe) - 圆4-Debug C:\Users\Daisy\source\repos\CMakeProject1\source\main.cpp 10Įrror (active) E0135 namespace "std" has no member "cout" Slash.exe (source\Slash.exe) - 圆4-Debug C:\Users\Daisy\source\repos\CMakeProject1\source\main.cpp 9Įrror (active) E0135 namespace "std" has no member "cout" Slash.exe (source\Slash.exe) - 圆4-Debug C:\Users\Daisy\source\repos\CMakeProject1\source\main.cpp 10Įrror (active) E1696 cannot open source file "iostream" Slash.exe (source\Slash.exe) - 圆4-Debug C:\Users\Daisy\source\repos\CMakeProject1\source\main.cpp 1Įrror (active) E1696 cannot open source file "iomanip" Slash.exe (source\Slash.exe) - 圆4-Debug C:\Users\Daisy\source\repos\CMakeProject1\source\main.cpp 2Įrror C1083 Cannot open include file: 'iostream': No such file or directory C:\Users\Daisy\source\repos\CMakeProject1\out\build\圆4-Debug\CMakeProject1 C:\Users\Daisy\source\repos\CMakeProject1\out\source\main.cpp 1 #include // Included to test whether including other libs did work. Here's the content of my main.cpp file #include I installed VS2019 yesterday and compiled a little test program that just writes a number to the console. ![]() As I find it completely unacceptable that all this extra scouring is neccecary to get a project working in a program that should really be an install-and-get-going kind of affair and wish to find either a better solution than copying this snippet into all of my projects or the actual issue. ![]() I don't want to mark this as a solution yet, though. Update 2: I managed to solve the problem by including the following in my top-level CMakeList if(WIN32) Update 1: I started a new project which made the error return, as well as create one additional error: C1034: iostream: no include path set ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |