diff --git a/CMakeLists.txt b/CMakeLists.txt --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -39,6 +39,7 @@ ADD_SUBDIRECTORY(lemon) ADD_SUBDIRECTORY(demo) +ADD_SUBDIRECTORY(tools) ADD_SUBDIRECTORY(doc) ADD_SUBDIRECTORY(test) @@ -56,16 +57,19 @@ SET(CPACK_PACKAGE_INSTALL_REGISTRY_KEY "${PROJECT_NAME} ${PROJECT_VERSION}") - SET(CPACK_COMPONENTS_ALL headers library html_documentation) + SET(CPACK_COMPONENTS_ALL headers library html_documentation bin) SET(CPACK_COMPONENT_HEADERS_DISPLAY_NAME "C++ headers") SET(CPACK_COMPONENT_LIBRARY_DISPLAY_NAME "Dynamic-link library") + SET(CPACK_COMPONENT_BIN_DISPLAY_NAME "Command line utilities") SET(CPACK_COMPONENT_HTML_DOCUMENTATION_DISPLAY_NAME "HTML documentation") SET(CPACK_COMPONENT_HEADERS_DESCRIPTION "C++ header files") SET(CPACK_COMPONENT_LIBRARY_DESCRIPTION "DLL and import library") + SET(CPACK_COMPONENT_BIN_DESCRIPTION + "Command line utilities") SET(CPACK_COMPONENT_HTML_DOCUMENTATION_DESCRIPTION "Doxygen generated documentation") diff --git a/tools/CMakeLists.txt b/tools/CMakeLists.txt new file mode 100644 --- /dev/null +++ b/tools/CMakeLists.txt @@ -0,0 +1,28 @@ +INCLUDE_DIRECTORIES( + ${CMAKE_SOURCE_DIR} + ${CMAKE_BINARY_DIR} +) + +LINK_DIRECTORIES(${CMAKE_BINARY_DIR}/lemon) + +ADD_EXECUTABLE(lgf-gen lgf-gen.cc) +TARGET_LINK_LIBRARIES(lgf-gen lemon) + +ADD_EXECUTABLE(dimacs-to-lgf dimacs-to-lgf.cc) +TARGET_LINK_LIBRARIES(dimacs-to-lgf lemon) + +ADD_EXECUTABLE(dimacs-solver dimacs-solver.cc) +TARGET_LINK_LIBRARIES(dimacs-solver lemon) + +INSTALL( + TARGETS lgf-gen dimacs-to-lgf dimacs-solver + RUNTIME DESTINATION bin + COMPONENT bin +) + +IF(NOT WIN32) + INSTALL( + FILES ${CMAKE_CURRENT_SOURCE_DIR}/lemon-0.x-to-1.x.sh + RUNTIME DESTINATION bin + COMPONENT bin) +ENDIF(NOT WIN32)