Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update cmake to pass along console_bridge #1

Merged
merged 1 commit into from
Dec 5, 2012
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 17 additions & 18 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,30 +1,29 @@
cmake_minimum_required(VERSION 2.8.3)
project(rosconsole_bridge)

find_package(catkin COMPONENTS rosconsole REQUIRED)
include_directories(${catkin_INCLUDE_DIRS})
find_package(catkin COMPONENTS rosconsole console_bridge REQUIRED)

include_directories(include ${catkin_INCLUDE_DIRS})
link_directories(${catkin_LIBRARY_DIRS})

catkin_package(
LIBRARIES ${PROJECT_NAME}
INCLUDE_DIRS include
)

include_directories(include)

find_package(console_bridge REQUIRED)
include_directories(${console_bridge_INCLUDE_DIR})

add_library(${PROJECT_NAME}
src/bridge.cpp)
CATKIN_DEPENDS console_bridge rosconsole
)

target_link_libraries(${PROJECT_NAME} ${console_bridge_LIBRARIES} ${catkin_LIBRARIES})
add_library(${PROJECT_NAME} src/bridge.cpp)

install(TARGETS ${PROJECT_NAME}
ARCHIVE DESTINATION lib
LIBRARY DESTINATION lib)
target_link_libraries(${PROJECT_NAME} ${catkin_LIBRARIES})

install(DIRECTORY include/
DESTINATION include
FILES_MATCHING PATTERN "*.h")
install(
TARGETS ${PROJECT_NAME}
ARCHIVE DESTINATION lib
LIBRARY DESTINATION lib
)

install(
DIRECTORY include/
DESTINATION include
FILES_MATCHING PATTERN "*.h"
)