c_cpp_properties.json
: 컴파일러 경로 및 IntelliSense 설정
tasks.json
: 빌드 지침
launch.json
: 디버거 설정
tasks.json
수정해서 여러 C++ 파일 빌드 가능
"{file}".This will build all .cpp files in your current folder. You can also modify the output filename by replacing "{fileBasenameNoExtension}" with a hard-coded filename (for example 'helloworld.out').
CMake 로 시작하기
CMake: Quick Start
CMake: Select a Kit
로 Kit 선택 (툴체인)cmake-tools-kits.json
파일에서 수정 가능. (커멘트 팔레트에서 CMake: Edit User-Local CMake Kits
)Select a variant
Debug, Release, MinRelSize, RelWithDebInfo
build type 을 가짐.Debug
: disables optimizations and includes debug info. Release
: Includes optimizations but no debug info. MinRelSize
: Optimizes for size. No debug info. RelWithDebInfo
: Optimizes for speed and includes debug info.CMake: Select Variant
로 선택 가능kit, variant 선택 했으니 (반드시 해야 함) 커멘드 팔레트에서 CMake: Configure
커멘드 실행해서 프로젝트 build folder 에 build file 생성.
출처 :
https://code.visualstudio.com/docs/cpp/config-wsl
https://code.visualstudio.com/docs/cpp/cmake-linux