* Sync up to trunk head (r64829).
[reactos.git] / dll / win32 / oleaut32 / CMakeLists.txt
1
2 remove_definitions(-D_WIN32_WINNT=0x502)
3 add_definitions(-D_WIN32_WINNT=0x600)
4
5 add_definitions(
6 -D__WINESRC__
7 -DCOM_NO_WINDOWS_H
8 -D_OLEAUT32_
9 -DPROXY_DELEGATION
10 -DWINE_REGISTER_DLL
11 -DENTRY_PREFIX=OLEAUTPS_
12 -DPROXY_CLSID=CLSID_PSFactoryBuffer)
13
14 include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine)
15 spec2def(oleaut32.dll oleaut32.spec ADD_IMPORTLIB)
16 add_rpcproxy_files(oleaut32_oaidl.idl oleaut32_ocidl.idl)
17
18 list(APPEND SOURCE
19 connpt.c
20 dispatch.c
21 hash.c
22 oleaut.c
23 olefont.c
24 olepicture.c
25 olepropframe.c
26 recinfo.c
27 safearray.c
28 tmarshal.c
29 typelib.c
30 usrmarshal.c
31 varformat.c
32 variant.c
33 vartype.c
34 precomp.h)
35
36 if(MSVC)
37 add_asm_files(oleaut32_asm msvc.S)
38 endif()
39
40 add_library(oleaut32 SHARED
41 ${SOURCE}
42 ${oleaut32_asm}
43 oleaut32.rc
44 ${CMAKE_CURRENT_BINARY_DIR}/oleaut32_stubs.c
45 ${CMAKE_CURRENT_BINARY_DIR}/proxy.dlldata.c
46 ${CMAKE_CURRENT_BINARY_DIR}/oleaut32_oaidl_p.c
47 ${CMAKE_CURRENT_BINARY_DIR}/oleaut32_ocidl_p.c
48 ${CMAKE_CURRENT_BINARY_DIR}/oleaut32.def)
49
50 if(CMAKE_C_COMPILER_ID STREQUAL "Clang")
51 target_link_libraries(oleaut32 mingwex)
52 #FIXME: http://llvm.org/bugs/show_bug.cgi?id=19027
53 set_property(SOURCE vartype.c APPEND_STRING PROPERTY COMPILE_FLAGS " -no-integrated-as")
54 endif()
55
56 add_idl_headers(oleaut32_idlheader oleaut32_oaidl.idl)
57 add_dependencies(oleaut32 oleaut32_idlheader)
58 set_module_type(oleaut32 win32dll)
59 target_link_libraries(oleaut32 wine wineldr uuid ${PSEH_LIB})
60 add_delay_importlibs(oleaut32 comctl32 urlmon windowscodecs)
61 add_importlibs(oleaut32 ole32 rpcrt4 user32 gdi32 advapi32 msvcrt kernel32 ntdll)
62 add_pch(oleaut32 precomp.h SOURCE)
63 add_cd_file(TARGET oleaut32 DESTINATION reactos/system32 FOR all)