dfhack/plugins/server/CMakeLists.txt

42 lines
1.2 KiB
CMake

2011-11-25 14:14:36 -07:00
PROJECT (server)
SET(PROJECT_SRCS
main.cpp
)
include_directories( ${CMAKE_SOURCE_DIR} )
IF(UNIX)
OPTION(SERVER_INTERNAL_SO "Link with prebuilt internal zeromq lib and headers." ON)
IF(SERVER_INTERNAL_SO)
SET(PROJECT_LIBS
${server_SOURCE_DIR}/zeromq/libzmq.so.1
${PROJECT_LIBS}
)
include_directories (
${include_directories}
${server_SOURCE_DIR}/zeromq
)
install(PROGRAMS ${server_SOURCE_DIR}/zeromq/libzmq.so.1 DESTINATION "hack/deplibs")
ELSE()
SET(PROJECT_LIBS
zmq
${PROJECT_LIBS}
)
ENDIF()
ELSE()
2011-11-25 15:21:31 -07:00
SET(PROJECT_LIBS
${server_SOURCE_DIR}/zeromq/libzmq.lib
${PROJECT_LIBS}
)
include_directories (
${include_directories}
${server_SOURCE_DIR}/zeromq
)
install(PROGRAMS ${server_SOURCE_DIR}/zeromq/libzmq.dll DESTINATION ".")
2011-11-25 14:14:36 -07:00
ENDIF()
DFHACK_PLUGIN(server ${PROJECT_SRCS} LINK_LIBRARIES ${PROJECT_LIBS})
add_executable ( helloclient hello.cpp )
2011-11-25 15:21:31 -07:00
target_link_libraries ( helloclient ${PROJECT_LIBS})
2011-11-25 14:14:36 -07:00
install(TARGETS helloclient RUNTIME DESTINATION . )