]> vaikene.ee Git - evaf/blob - src/main/GUI/CMakeLists.txt
Ported to Qt5
[evaf] / src / main / GUI / CMakeLists.txt
1 # Name of the target
2 set(TARGET eVafGUI)
3
4 # Include files
5 include_directories(${eVaf_INCLUDE})
6
7 # Required eVaf libraries
8 set(eVaf_LIBRARIES CommonLib PluginsLib)
9
10 # Source files
11 set(SRCS
12 main.cpp
13 exithandler.cpp
14 fatalerr.cpp
15 #version.cpp
16 )
17 if(WIN32)
18 set(SRCS
19 ${SRCS}
20 winconsole.cpp
21 )
22 endif(WIN32)
23
24 # Header files for the meta-object compiler
25 set(MOC_HDRS
26 main.h
27 fatalerr.h
28 #version_p.h
29 )
30
31 # Resources
32 set(RCCS
33 gui.qrc
34 )
35
36 # Version info resource file for Windows builds
37 if(WIN32 AND NOT MINGW)
38 set(SRCS ${SRCS} version.rc gui.rc)
39 endif(WIN32 AND NOT MINGW)
40
41 qt5_add_resources(RCC_SRCS ${RCCS})
42
43 qt5_wrap_cpp(MOC_SRCS ${MOC_HDRS})
44
45 add_executable(${TARGET} WIN32 ${SRCS} ${MOC_SRCS} ${RCC_SRCS})
46
47 qt5_use_modules(${TARGET} Core Widgets)
48
49 target_link_libraries(${TARGET} ${eVaf_LIBRARIES})
50
51 install(TARGETS ${TARGET} DESTINATION bin)