[CMAKE] Use modules instead of shared libraries
[reactos.git] / dll / win32 / iphlpapi / CMakeLists.txt
1
2 include_directories(
3 ${REACTOS_SOURCE_DIR}/sdk/include/reactos/wine
4 ${REACTOS_SOURCE_DIR}/dll/win32/dhcpcsvc/include
5 ${REACTOS_SOURCE_DIR}/sdk/lib/tdilib)
6
7 spec2def(iphlpapi.dll iphlpapi.spec ADD_IMPORTLIB)
8
9 add_definitions(-DGetAdaptersAddressesV2)
10 list(APPEND SOURCE
11 address.c
12 dhcp_reactos.c
13 icmp.c
14 ifenum_reactos.c
15 ipstats_reactos.c
16 iphlpapi_reactos.c
17 iphlpapi_main.c
18 media.c
19 registry.c
20 resinfo_reactos.c
21 route_reactos.c
22 iphlpapi_private.h
23 ${CMAKE_CURRENT_BINARY_DIR}/iphlpapi_stubs.c)
24
25 add_library(iphlpapi MODULE
26 ${SOURCE}
27 iphlpapi.rc
28 iphlpapi_fakestubs.c
29 iphlpapi.spec
30 ${CMAKE_CURRENT_BINARY_DIR}/iphlpapi.def)
31
32 set_module_type(iphlpapi win32dll UNICODE)
33 target_link_libraries(iphlpapi wine tdilib)
34 add_importlibs(iphlpapi dhcpcsvc advapi32 psapi ws2_32 msvcrt kernel32 ntdll)
35 add_pch(iphlpapi iphlpapi_private.h SOURCE)
36 add_cd_file(TARGET iphlpapi DESTINATION reactos/system32 FOR all)