[CMake] Best way to show/include CMake files in IDE

Eric Wing ewmailing at gmail.com
Mon Mar 7 18:34:57 EST 2016


I have a bunch of .cmake support files in my project that I have split
off from CMakeLists.txt (using INCLUDE to combine them) to separate
concerns. (Source files, application assets, script files, platform
settings, codesigning, etc.)

This works, but they don't show up in IDEs (Visual Studio, Xcode,
etc). I realized it would be nice to see these files in the IDE and be
able to edit them there. (I assume the CMake bootstrap will still just
work.)

What is the best way to include/show these files in the IDE (and won't
break the Makefile or other non-IDE generators)?

Thanks,
Eric


More information about the CMake mailing list