mirror of
https://github.com/reactos/reactos.git
synced 2025-01-12 01:00:06 +00:00
c702cc0d5a
Generalize CMAKE_C_CREATE_SHARED_LIBRARY and remove per project instances. Thanks to Amine for regexxer tool discovery ;) svn path=/branches/cmake-bringup/; revision=48804
41 lines
873 B
CMake
41 lines
873 B
CMake
|
|
|
|
|
|
include_directories(include)
|
|
|
|
spec2def(dhcpcsvc ${CMAKE_CURRENT_SOURCE_DIR}/dhcpcsvc.spec ${CMAKE_CURRENT_BINARY_DIR}/dhcpcsvc.def)
|
|
|
|
list(APPEND SOURCE
|
|
dhcp/adapter.c
|
|
dhcp/alloc.c
|
|
dhcp/api.c
|
|
dhcp/compat.c
|
|
dhcp/dhclient.c
|
|
dhcp/dispatch.c
|
|
dhcp/hash.c
|
|
dhcp/options.c
|
|
dhcp/pipe.c
|
|
dhcp/socket.c
|
|
dhcp/tables.c
|
|
dhcp/util.c
|
|
dhcpcsvc.c
|
|
dhcpcsvc.rc)
|
|
|
|
add_library(dhcpcsvc SHARED
|
|
${CMAKE_CURRENT_BINARY_DIR}/dhcpcsvc_rosdhcp.h.gch
|
|
${SOURCE})
|
|
|
|
set_target_properties(dhcpcsvc PROPERTIES LINK_FLAGS "-Wl,-entry,_DllMain@12")
|
|
|
|
target_link_libraries(dhcpcsvc
|
|
${CMAKE_CURRENT_BINARY_DIR}/dhcpcsvc.def
|
|
-lmsvcrt
|
|
-lws2_32
|
|
-liphlpapi
|
|
-ladvapi32
|
|
oldnames
|
|
-lkernel32
|
|
-lntdll)
|
|
|
|
add_pch(dhcpcsvc ${CMAKE_CURRENT_SOURCE_DIR}/include/rosdhcp.h ${SOURCE})
|
|
add_dependencies(dhcpcsvc dhcpcsvc_def psdk)
|