[CMAKE] Allow overriding the .dll extension for delay imports in MSVC builds.
[reactos.git] / dll / win32 / setupapi / CMakeLists.txt
1
2 include_directories(
3 ${REACTOS_SOURCE_DIR}/sdk/include/reactos/wine
4 ${REACTOS_SOURCE_DIR}/sdk/include/reactos/idl
5 ${CMAKE_CURRENT_BINARY_DIR})
6
7 add_definitions(
8 -D_SETUPAPI_
9 -D_CFGMGR32_
10 -Dwcsnicmp=_wcsnicmp)
11
12 add_rpc_files(client ${REACTOS_SOURCE_DIR}/sdk/include/reactos/idl/pnp.idl)
13 spec2def(setupapi.dll setupapi.spec ADD_IMPORTLIB)
14
15 list(APPEND SOURCE
16 cfgmgr.c
17 devclass.c
18 devinst.c
19 dialog.c
20 dirid.c
21 diskspace.c
22 driver.c
23 install.c
24 interface.c
25 misc.c
26 parser.c
27 query.c
28 queue.c
29 setupcab.c
30 stringtable.c
31 stubs.c
32 rpc.c
33 setupapi_private.h
34 ${CMAKE_CURRENT_BINARY_DIR}/pnp_c.c)
35
36 add_library(setupapi SHARED
37 ${SOURCE}
38 setupapi.rc
39 ${CMAKE_CURRENT_BINARY_DIR}/setupapi_stubs.c
40 ${CMAKE_CURRENT_BINARY_DIR}/setupapi.def)
41
42 set_module_type(setupapi win32dll UNICODE)
43 target_link_libraries(setupapi uuid wine ${PSEH_LIB})
44 add_delay_importlibs(setupapi comdlg32 shell32 winspool.drv wintrust)
45 add_importlibs(setupapi gdi32 comctl32 advapi32 user32 rpcrt4 version msvcrt kernel32 ntdll)
46 add_pch(setupapi setupapi_private.h SOURCE)
47 add_cd_file(TARGET setupapi DESTINATION reactos/system32 FOR all)