Skip to content

Commit

Permalink
Format package.xml and CMakeLists.txt according to ros_control pkgs
Browse files Browse the repository at this point in the history
  • Loading branch information
mateus-amarante authored and bmagyar committed Sep 25, 2020
1 parent b78b932 commit 96d114e
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 9 deletions.
33 changes: 25 additions & 8 deletions ackermann_steering_controller/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ if(NOT CMAKE_CXX_STANDARD)
set(CMAKE_CXX_STANDARD 14)
endif()

# Load catkin and all dependencies required for this package
find_package(catkin REQUIRED COMPONENTS
controller_interface
diff_drive_controller
Expand All @@ -21,6 +22,7 @@ find_package(Boost REQUIRED COMPONENTS system thread)

find_package(urdfdom REQUIRED)

# Declare a catkin package
catkin_package(
LIBRARIES ${PROJECT_NAME}
CATKIN_DEPENDS
Expand All @@ -34,6 +36,11 @@ catkin_package(
DEPENDS Boost
)

###########
## Build ##
###########

# Specify header include paths
include_directories(
include
${Boost_INCLUDE_DIRS}
Expand All @@ -44,14 +51,9 @@ include_directories(
add_library(${PROJECT_NAME} src/ackermann_steering_controller.cpp src/odometry.cpp)
target_link_libraries(${PROJECT_NAME} ${catkin_LIBRARIES} ${Boost_LIBRARIES} ${urdfdom_LIBRARIES})

install(TARGETS ${PROJECT_NAME}
ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)

install(FILES ${PROJECT_NAME}_plugins.xml
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION})
#############
## Testing ##
#############

if (CATKIN_ENABLE_TESTING)
find_package(controller_manager REQUIRED)
Expand Down Expand Up @@ -125,3 +127,18 @@ if (CATKIN_ENABLE_TESTING)
add_rostest(test/ackermann_steering_controller_radius_param_fail_test/ackermann_steering_controller_radius_param_fail.test)
add_rostest(test/ackermann_steering_controller_separation_param_test/ackermann_steering_controller_separation_param.test)
endif()

#############
## Install ##
#############

# Install targets
install(TARGETS ${PROJECT_NAME}
ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)

# Install plugins
install(FILES ${PROJECT_NAME}_plugins.xml
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION})
7 changes: 6 additions & 1 deletion ackermann_steering_controller/package.xml
Original file line number Diff line number Diff line change
@@ -1,15 +1,20 @@
<?xml version="1.0"?>
<package format="2">
<?xml-model
href="http://download.ros.org/schema/package_format3.xsd"
schematypens="http://www.w3.org/2001/XMLSchema"?>
<package format="3">
<name>ackermann_steering_controller</name>
<version>0.17.0</version>
<description>Controller for a steer drive mobile base.</description>

<maintainer email="[email protected]">Masaru Morita</maintainer>
<maintainer email="[email protected]">Bence Magyar</maintainer>

<license>BSD</license>

<url type="bugtracker">https://github.com/ros-controls/ros_controllers/issues</url>
<url type="repository">https://github.com/ros-controls/ros_controllers/ackermann_steering_controller</url>

<author email="[email protected]">Masaru Morita</author>

<buildtool_depend>catkin</buildtool_depend>
Expand Down

0 comments on commit 96d114e

Please sign in to comment.