4
0
mirror of https://github.com/RT-Thread/rt-thread.git synced 2025-01-19 05:43:31 +08:00

cmake默认开启生成编译数据库

tools/cmake: Add CMAKE_EXPORT_COMPILE_COMMANDS ON

Signed-off-by: SunJ <jsun@bouffalolab.com>
This commit is contained in:
SunJ 2022-04-29 15:05:19 +08:00 committed by guo
parent c14dbe8a2e
commit 8c18ec64bd

View File

@ -65,6 +65,7 @@ def GenerateCFiles(env,project):
cm_file.write("SET(CMAKE_SYSTEM_NAME Generic)\n")
cm_file.write("SET(CMAKE_SYSTEM_PROCESSOR " + rtconfig.CPU +")\n")
cm_file.write("#SET(CMAKE_VERBOSE_MAKEFILE ON)\n\n")
cm_file.write("SET(CMAKE_EXPORT_COMPILE_COMMANDS ON)\n\n")
cm_file.write("SET(CMAKE_C_COMPILER \""+ CC + "\")\n")
cm_file.write("SET(CMAKE_ASM_COMPILER \""+ AS + "\")\n")