reactos/dll/win32/setupapi/CMakeLists.txt
Jérôme Gardou 23373acbb9 [CMAKE] Use modules instead of shared libraries
There is no need to compile our DLLs as shared libraries since we are
managing symbols exports and imports through spec files.

On my system, this reduces the configure-time by a factor of two.
2019-04-06 17:43:38 +02:00

47 lines
1.2 KiB
CMake

include_directories(
${REACTOS_SOURCE_DIR}/sdk/include/reactos/wine
${REACTOS_SOURCE_DIR}/sdk/include/reactos/idl
${CMAKE_CURRENT_BINARY_DIR})
add_definitions(
-D_SETUPAPI_
-D_CFGMGR32_
-Dwcsnicmp=_wcsnicmp)
add_rpc_files(client ${REACTOS_SOURCE_DIR}/sdk/include/reactos/idl/pnp.idl)
spec2def(setupapi.dll setupapi.spec ADD_IMPORTLIB)
list(APPEND SOURCE
cfgmgr.c
devclass.c
devinst.c
dialog.c
dirid.c
diskspace.c
driver.c
install.c
interface.c
misc.c
parser.c
query.c
queue.c
setupcab.c
stringtable.c
stubs.c
rpc.c
setupapi_private.h
${CMAKE_CURRENT_BINARY_DIR}/pnp_c.c)
add_library(setupapi MODULE
${SOURCE}
setupapi.rc
${CMAKE_CURRENT_BINARY_DIR}/setupapi_stubs.c
${CMAKE_CURRENT_BINARY_DIR}/setupapi.def)
set_module_type(setupapi win32dll UNICODE)
target_link_libraries(setupapi uuid wine ${PSEH_LIB})
add_delay_importlibs(setupapi comdlg32 shell32 winspool.drv wintrust)
add_importlibs(setupapi gdi32 comctl32 advapi32 user32 rpcrt4 version msvcrt kernel32 ntdll)
add_pch(setupapi setupapi_private.h SOURCE)
add_cd_file(TARGET setupapi DESTINATION reactos/system32 FOR all)