[UMPNPMGR]
[reactos.git] / reactos / base / services / umpnpmgr / CMakeLists.txt
index 9667d98..c361e5e 100644 (file)
@@ -1,18 +1,16 @@
 
-include_directories(${REACTOS_SOURCE_DIR}/include/reactos/idl)
+include_directories(${REACTOS_SOURCE_DIR}/sdk/include/reactos/idl)
+add_rpc_files(server ${REACTOS_SOURCE_DIR}/sdk/include/reactos/idl/pnp.idl)
+spec2def(umpnpmgr.dll umpnpmgr.spec ADD_IMPORTLIB)
 
-add_rpc_files(server ${REACTOS_SOURCE_DIR}/include/reactos/idl/pnp.idl)
-
-
-add_executable(umpnpmgr
+add_library(umpnpmgr SHARED
     umpnpmgr.c
     umpnpmgr.rc
-    ${CMAKE_CURRENT_BINARY_DIR}/pnp_s.c)
-
-target_link_libraries(umpnpmgr
-    wdmguid
-    ${PSEH_LIB})
+    ${CMAKE_CURRENT_BINARY_DIR}/pnp_s.c
+    ${CMAKE_CURRENT_BINARY_DIR}/umpnpmgr_stubs.c
+    ${CMAKE_CURRENT_BINARY_DIR}/umpnpmgr.def)
 
-set_module_type(umpnpmgr win32cui UNICODE)
-add_importlibs(umpnpmgr advapi32 rpcrt4 userenv shlwapi msvcrt kernel32 ntdll)
+target_link_libraries(umpnpmgr wdmguid ${PSEH_LIB})
+set_module_type(umpnpmgr win32dll UNICODE)
+add_importlibs(umpnpmgr advapi32 rpcrt4 userenv shlwapi msvcrt user32 kernel32 ntdll)
 add_cd_file(TARGET umpnpmgr DESTINATION reactos/system32 FOR all)