Files
oatmeal/cmake/compileCommands.cmake
2026-04-11 17:29:03 -04:00

15 lines
361 B
CMake

##### SETUP COMPILE COMMANDS #####
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
set(CMAKE_EXPORT_COMPILE_COMMANDS on)
endif()
if(EXISTS "${CMAKE_BINARY_DIR}/compile_commands.json")
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
file(
COPY "${CMAKE_BINARY_DIR}/compile_commands.json"
DESTINATION "${CMAKE_BINARY_DIR}/../"
)
endif()
endif()