xref: /reactos/dll/win32/rpcrt4/CMakeLists.txt (revision 5bfe6a53)
1
2remove_definitions(-D_WIN32_WINNT=0x502)
3add_definitions(-D_WIN32_WINNT=0x600)
4
5add_definitions(
6    -D__WINESRC__
7    -D_RPCRT4_
8    -DCOM_NO_WINDOWS_H
9    -DMSWMSG)
10
11include_directories(BEFORE ${REACTOS_SOURCE_DIR}/sdk/include/reactos/wine)
12spec2def(rpcrt4.dll rpcrt4.spec ADD_IMPORTLIB)
13
14add_rpc_files(client epm.idl)
15add_idl_headers(ndr_types_header ndr_types.idl)
16
17set(OLD_IDL_FLAGS ${IDL_FLAGS})
18set(IDL_FLAGS ${IDL_FLAGS} -Oicf)
19add_rpcproxy_files(ndr_types.idl)
20set(IDL_FLAGS ${OLD_IDL_FLAGS})
21
22list(APPEND SOURCE
23    cproxy.c
24    cpsf.c
25    cstub.c
26    ndr_clientserver.c
27    ndr_contexthandle.c
28    ndr_es.c
29    ndr_fullpointer.c
30    ndr_marshall.c
31    ndr_ole.c
32    ndr_stubless.c
33    rpc_assoc.c
34    rpc_async.c
35    rpc_binding.c
36    rpc_epmap.c
37    rpc_message.c
38    rpcrt4_main.c
39    rpc_server.c
40    rpc_transport.c
41    unix_func.c
42    precomp.h
43    ${CMAKE_CURRENT_BINARY_DIR}/epm_c.c)
44
45if(MSVC AND NOT ARCH STREQUAL "arm")
46    add_asm_files(rpcrt4_asm msvc.S)
47endif()
48
49add_library(rpcrt4 SHARED
50    ${SOURCE}
51    ndr_typelib.c
52    ${CMAKE_CURRENT_BINARY_DIR}/ndr_types_p.c
53    ${CMAKE_CURRENT_BINARY_DIR}/proxy.dlldata.c
54    ${rpcrt4_asm}
55    rpcrt4.rc
56    ${CMAKE_CURRENT_BINARY_DIR}/rpcrt4_stubs.c
57    ${CMAKE_CURRENT_BINARY_DIR}/rpcrt4.def)
58
59set_module_type(rpcrt4 win32dll)
60target_link_libraries(rpcrt4 wine uuid ${PSEH_LIB})
61add_delay_importlibs(rpcrt4 iphlpapi wininet secur32 user32 oleaut32)
62add_importlibs(rpcrt4 advapi32 advapi32_vista kernel32_vista ws2_32 msvcrt kernel32 ntdll)
63add_dependencies(rpcrt4 ndr_types_header)
64add_pch(rpcrt4 precomp.h SOURCE)
65add_cd_file(TARGET rpcrt4 DESTINATION reactos/system32 FOR all)
66