[CMAKE] Implement PCH builds with target_precompile_headers. CORE-16905
[reactos.git] / dll / win32 / msgina / CMakeLists.txt
1
2 set_cpp(WITH_RUNTIME)
3
4 add_definitions(
5 -D_ATL_NO_EXCEPTIONS)
6
7 include_directories(
8 ${REACTOS_SOURCE_DIR}/sdk/lib/atl
9 ${REACTOS_SOURCE_DIR}/sdk/include/reactos/wine)
10
11 spec2def(msgina.dll msgina.spec)
12
13 list(APPEND SOURCE
14 gui.c
15 lsa.c
16 msgina.c
17 shutdown.c
18 stubs.c
19 tui.c)
20
21 list(APPEND PCH_SKIP_SOURCE
22 dimmedwindow.cpp
23 ${CMAKE_CURRENT_BINARY_DIR}/msgina_stubs.c)
24
25 add_library(msgina MODULE
26 ${SOURCE}
27 ${PCH_SKIP_SOURCE}
28 msgina.rc
29 ${CMAKE_CURRENT_BINARY_DIR}/msgina.def)
30
31 set_module_type(msgina win32dll UNICODE)
32 target_link_libraries(msgina wine uuid ${PSEH_LIB})
33 add_delay_importlibs(msgina secur32)
34 add_importlibs(msgina advapi32 user32 gdi32 powrprof userenv msvcrt kernel32 ntdll)
35 add_pch(msgina msgina.h "${PCH_SKIP_SOURCE}")
36 add_cd_file(TARGET msgina DESTINATION reactos/system32 FOR all)