bdf18cd3fa0283e9621448d48b78a89c47c6ef1c
[reactos.git] / reactos / base / applications / msconfig_new / CMakeLists.txt
1
2 PROJECT(msconfig_new)
3
4 # Currently, C++ files are the exception in this project. Therefore we
5 # manually set up only what's needed for C++ support. If the project
6 # is converted to C++, then we'll need to use the general C++ set-up.
7 set_cpp(WITH_RUNTIME)
8 set(IS_CPP 0) # Disable C++ for PCH
9
10 include_directories(
11 .
12 comctl32ex
13 ${REACTOS_SOURCE_DIR}/include/c++)
14
15 list(APPEND C_SOURCE
16 comctl32ex/listviewfuncs.c
17 # toolspage.c
18 # srvpage.c
19 # systempage.c
20 # startuppage.c
21 # freeldrpage.c
22 generalpage.c
23 msconfig.c
24 stringutils.c
25 utils.c
26 precomp.h)
27
28 list(APPEND CPP_SOURCE
29 toolspage.cpp
30 xmldomparser.cpp)
31
32 add_rc_deps(msconfig.rc ${CMAKE_CURRENT_SOURCE_DIR}/res/msconfig.ico)
33 add_executable(msconfig_new ${C_SOURCE} ${CPP_SOURCE} msconfig.rc)
34
35 # Retrieve the COMPILE_FLAGS property for the .cpp files only
36 get_property(cpp_file1_flag SOURCE toolspage.cpp PROPERTY COMPILE_FLAGS)
37 get_property(cpp_file2_flag SOURCE xmldomparser.cpp PROPERTY COMPILE_FLAGS)
38 # Define PCH usage (see 'add_pch' macro code for more information)
39 add_pch(msconfig_new precomp.h C_SOURCE)
40 # Remove PCH usage for the .cpp files only (set the original COMPILE_FLAGS property)
41 set_property(SOURCE toolspage.cpp PROPERTY COMPILE_FLAGS ${cpp_file1_flag})
42 set_property(SOURCE xmldomparser.cpp PROPERTY COMPILE_FLAGS ${cpp_file2_flag})
43
44 set_module_type(msconfig_new win32gui UNICODE)
45 target_link_libraries(msconfig_new comsupp)
46 add_importlibs(msconfig_new user32 advapi32 version comctl32 ole32 oleaut32 msxml3 shell32 shlwapi msvcrt kernel32)
47 add_cd_file(TARGET msconfig_new DESTINATION reactos/system32 FOR all)