[CMAKE]
[reactos.git] / dll / win32 / dnsapi / CMakeLists.txt
1
2 include_directories(
3 include
4 ${REACTOS_SOURCE_DIR}/lib/3rdparty/adns/src
5 ${REACTOS_SOURCE_DIR}/lib/3rdparty/adns/adns_win32)
6
7 add_definitions(
8 -D_DLL -D__USE_CRTIMP
9 -DADNS_JGAA_WIN32)
10
11 spec2def(dnsapi.dll dnsapi.spec)
12
13 list(APPEND SOURCE
14 dnsapi/adns.c
15 dnsapi/context.c
16 dnsapi/memory.c
17 dnsapi/names.c
18 dnsapi/query.c
19 dnsapi/record.c
20 dnsapi/stubs.c
21 dnsapi.rc
22 ${CMAKE_CURRENT_BINARY_DIR}/dnsapi.def)
23
24 add_library(dnsapi SHARED
25 ${CMAKE_CURRENT_BINARY_DIR}/dnsapi_precomp.h.gch
26 ${SOURCE})
27
28 set_entrypoint(dnsapi 0)
29
30 target_link_libraries(dnsapi adns)
31 if(MSVC)
32 target_link_libraries(dnsapi msvcsup)
33 endif()
34
35 add_importlibs(dnsapi user32 ws2_32 iphlpapi msvcrt kernel32 ntdll)
36 add_pch(dnsapi ${CMAKE_CURRENT_SOURCE_DIR}/dnsapi/precomp.h ${SOURCE})
37 add_dependencies(dnsapi psdk)
38 add_cd_file(TARGET dnsapi DESTINATION reactos/system32)
39 add_importlib_target(dnsapi.spec)