no message
parent
b8989fc4c3
commit
375470b1cc
|
@ -1,7 +1,7 @@
|
|||
cmake_minimum_required(VERSION 3.5)
|
||||
message("CMAKE VERSION " ${VERSION})
|
||||
include_directories(third/include)
|
||||
link_directories(third/lib)
|
||||
|
||||
include_directories(third/lua/include)
|
||||
link_directories(third/lua/lib)
|
||||
link_libraries(lua)
|
||||
|
||||
project(protoDebuger LANGUAGES CXX)
|
||||
|
@ -17,15 +17,16 @@ set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
|||
|
||||
find_package(Qt5 COMPONENTS Core Quick Widgets REQUIRED)
|
||||
|
||||
include(D:\\project\\c++qt\\qsswraper\\CMakeLists.txt)
|
||||
|
||||
set(HEADERS # 待预编译的cpp头文件
|
||||
dialog.h
|
||||
)
|
||||
|
||||
set(SOURCES # 待预编译的cpp代码
|
||||
dialog.cpp
|
||||
main.cpp
|
||||
)
|
||||
set(NO_MOC_SOURCES
|
||||
|
||||
)
|
||||
|
||||
set(RESOURCES
|
||||
qml.qrc
|
||||
|
@ -36,35 +37,23 @@ set(QMLS
|
|||
)
|
||||
|
||||
set (UIS
|
||||
${QsswraperUI}
|
||||
)
|
||||
|
||||
include(D:\\project\\qt\\qsswraper\\CMakeLists.txt)
|
||||
include(D:\\project\\qt\\qsswraper\\extserial\\src\\qextserialport.cmake)
|
||||
"dialog.ui"
|
||||
${QsswraperUI})
|
||||
|
||||
QT5_WRAP_CPP(MOC ${SOURCES} ) # moc预编译代码
|
||||
QT5_WRAP_CPP(MOCHEADER ${HEADERS} ) # moc预编译代码
|
||||
QT5_ADD_RESOURCES(RCC ${RESOURCES}) # rcc生成资源cpp
|
||||
QT5_WRAP_UI(UIC ${UIS}) # uic生成ui_x.h
|
||||
|
||||
FOREACH(list ${SOURCES})
|
||||
message("SOURCES file " ${list})
|
||||
ENDFOREACH(list)
|
||||
|
||||
FOREACH(list ${MOCHEADER})
|
||||
message("MOCHEADER file" ${list})
|
||||
ENDFOREACH(list)
|
||||
|
||||
FOREACH(list ${NO_MOC_SOURCES})
|
||||
message("NO_MOC_SOURCES file" ${list})
|
||||
ENDFOREACH(list)
|
||||
message("MOC " ${MOC} ${MOCHEADER})
|
||||
message("UIC " ${UIC})
|
||||
message("RCC " ${RCC})
|
||||
|
||||
add_executable(protoDebuger #最后需要参与链接生成的是
|
||||
${SOURCES} #1. 原先的cpp代码,
|
||||
${MOC} #2. 预编译后的cpp
|
||||
${RCC} #3. 资源cpp代码
|
||||
${UIC}
|
||||
${NO_MOC_SOURCES}
|
||||
)
|
||||
|
||||
target_compile_definitions(protoDebuger
|
||||
|
|
Loading…
Reference in New Issue