b1d9c0db30fce11f2eb54df4de47f2759fbfe103
[reactos.git] / reactos / dll / win32 / msi / CMakeLists.txt
1
2 if(NOT MSVC)
3
4 include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine)
5 add_definitions(-D__WINESRC__ -DMSIRUNMODE=MSIRUNMODE_T)
6
7 remove_definitions(-D_WIN32_WINNT=0x502)
8 add_definitions(-D_WIN32_WINNT=0x600)
9
10 set_rc_compiler()
11 spec2def(msi.dll msi.spec ADD_IMPORTLIB)
12
13 generate_idl_iids(msiserver.idl)
14
15 list(APPEND SOURCE
16 action.c
17 alter.c
18 appsearch.c
19 assembly.c
20 automation.c
21 classes.c
22 cond.tab.c
23 create.c
24 custom.c
25 database.c
26 delete.c
27 dialog.c
28 distinct.c
29 drop.c
30 events.c
31 files.c
32 font.c
33 format.c
34 handle.c
35 insert.c
36 install.c
37 media.c
38 msi.c
39 msi_main.c
40 msiquery.c
41 package.c
42 patch.c
43 record.c
44 registry.c
45 script.c
46 select.c
47 source.c
48 sql.tab.c
49 storages.c
50 streams.c
51 string.c
52 suminfo.c
53 table.c
54 tokenize.c
55 update.c
56 upgrade.c
57 where.c
58 msi.rc
59 ${CMAKE_CURRENT_BINARY_DIR}/msiserver_i.c
60 ${CMAKE_CURRENT_BINARY_DIR}/msi_stubs.c
61 ${CMAKE_CURRENT_BINARY_DIR}/msi.def)
62
63 if(MSVC)
64 set_source_files_properties(custom.c PROPERTIES COMPILE_FLAGS /FImsvchelper.h)
65 endif()
66
67 add_library(msi SHARED ${SOURCE})
68
69 add_idl_headers(msi_idlheader msiserver.idl)
70 add_typelib(msiserver.idl)
71
72 set_source_files_properties(msi.rc PROPERTIES OBJECT_DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/msiserver.tlb)
73
74 set_module_type(msi win32dll)
75 target_link_libraries(msi uuid ${PSEH_LIB} wine)
76 add_dependencies(msi msi_idlheader)
77 add_delay_importlibs(msi odbccp32 crypt32 wintrust)
78 add_importlibs(msi
79 advapi32
80 cabinet
81 comctl32
82 gdi32
83 ole32
84 oleaut32
85 shell32
86 shlwapi
87 urlmon
88 user32
89 version
90 wininet
91 #fixme : should be in delayed imports
92 imagehlp
93 msvcrt
94 kernel32
95 ntdll)
96
97 add_pch(msi msipriv.h)
98 add_cd_file(TARGET msi DESTINATION reactos/system32 FOR all)
99
100 endif(NOT MSVC)
101
102