mirror of
https://github.com/reactos/reactos.git
synced 2024-11-10 00:34:39 +00:00
174808a463
This allows linking to libraries with "-lfoo". svn path=/branches/cmake-bringup/; revision=48796
20 lines
727 B
CMake
20 lines
727 B
CMake
|
|
set(CMAKE_C_CREATE_SHARED_LIBRARY "<CMAKE_C_COMPILER> <CMAKE_SHARED_LIBRARY_C_FLAGS> <LINK_FLAGS> <CMAKE_SHARED_LIBRARY_CREATE_C_FLAGS> -o <TARGET> <OBJECTS> <LINK_LIBRARIES>")
|
|
|
|
add_definitions(-DUNICODE -D_UNICODE)
|
|
|
|
# Possible definitions: CARDSTYLE_DEFAULT or CARDSTYLE_BAVARIAN
|
|
add_definitions(-DCARDSTYLE_DEFAULT)
|
|
|
|
spec2def(cards ${CMAKE_CURRENT_SOURCE_DIR}/cards.spec ${CMAKE_CURRENT_BINARY_DIR}/cards.def)
|
|
|
|
add_library(cards SHARED ${CMAKE_CURRENT_SOURCE_DIR}/cards.c ${CMAKE_CURRENT_SOURCE_DIR}/cards.rc)
|
|
|
|
set_target_properties(cards PROPERTIES LINK_FLAGS "-Wl,-entry,_DllMain@12")
|
|
|
|
target_link_libraries(cards
|
|
${CMAKE_CURRENT_BINARY_DIR}/cards.def
|
|
-luser32
|
|
-lgdi32)
|
|
|
|
add_dependencies(cards cards_def psdk)
|