Build
add_executalbe() is for building a executable program. While
add_library() is for building a library.
Both the source files and header files need to be added to executable target.
-
Old fasion: How can i include header files from a directory into cmake
-
Mordern style: parallel101/course - 彭于斌
1 2 3add_executable(MyApp) file(GLOB sources *.cpp *.h) target_source(main PUBLIC ${sources})
(2023-11-16)
Ccache
Speed up recompilation. Docs
Usage refer to parallel101/course
|
|