Skip to content

Commit

Permalink
Catkinize csm
Browse files Browse the repository at this point in the history
  • Loading branch information
Enrique Fernandez committed May 23, 2017
1 parent d8ce2bf commit 5518627
Show file tree
Hide file tree
Showing 3 changed files with 91 additions and 79 deletions.
87 changes: 85 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,88 @@
## This CMakeLists.txt file exists only for building as ROS 3rd-party package. Building for other purpose is not tested. See https://github.com/AndreaCensi/csm/pull/10
cmake_minimum_required(VERSION 2.8)
project(csm)

INSTALL(FILES package.xml DESTINATION share/csm)
find_package(catkin REQUIRED COMPONENTS
cmake_modules
roscpp
)

find_package(Eigen REQUIRED)

if(WIN32)
add_definitions(-DWINDOWS)
if(MSVC)
# SSE2 optimizations
add_definitions("/arch:SSE2")
endif()
endif()

catkin_package(
INCLUDE_DIRS include
LIBRARIES ${PROJECT_NAME}
CATKIN_DEPENDS
roscpp
DEPENDS Eigen
)

include_directories(
include
src
${catkin_INCLUDE_DIRS}
${EIGEN_INCLUDE_DIRS})

set(CSM_SRC
src/csm/laser_data.cpp
src/csm/math_utils.cpp
src/csm/math_utils_gsl.cpp
src/csm/utils.cpp
src/csm/logging.cpp
src/csm/sm_options.cpp
src/csm/orientation.cpp
src/csm/clustering.cpp)

set(EGSL_SRC
src/egsl/egsl.cpp
src/egsl/egsl_conversions.cpp
src/egsl/egsl_misc.cpp
src/egsl/egsl_ops.cpp)

set(GPC_SRC
src/gpc/gpc.cpp
src/gpc/gpc_utils.cpp)

set(ICP_SRC
src/icp/icp.cpp
src/icp/icp_corr_dumb.cpp
src/icp/icp_corr_tricks.cpp
src/icp/icp_covariance.cpp
src/icp/icp_debug.cpp
src/icp/icp_loop.cpp
src/icp/icp_outliers.cpp)

set(OPTIONS_SRC
src/options/options.cpp
src/options/options_interface.cpp)

add_library(${PROJECT_NAME}
${CSM_SRC}
${EGSL_SRC}
${GPC_SRC}
${ICP_SRC}
${OPTIONS_SRC})

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

install(DIRECTORY include/${PROJECT_NAME}/
DESTINATION ${CATKIN_PACKAGE_INCLUDE_DESTINATION}
FILES_MATCHING PATTERN "*.h"
)

install(DIRECTORY include/gsl_eigen/
DESTINATION ${CATKIN_PACKAGE_INCLUDE_DESTINATION}/../gsl_eigen
FILES_MATCHING PATTERN "*.h"
)
12 changes: 6 additions & 6 deletions package.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0"?>
<package>
<package format="2">
<name>csm</name>
<version>1.0.0</version>
<description>
Expand All @@ -22,9 +22,9 @@
<url type="bugtracker">https://github.com/AndreaCensi/csm/issues</url>
<maintainer email="[email protected]">Isaac I.Y. Saito</maintainer>

<buildtool_depend>cmake</buildtool_depend>
<run_depend>catkin</run_depend>
<export>
<build_type>cmake</build_type>
</export>
<buildtool_depend>catkin</buildtool_depend>

<build_depend>cmake_modules</build_depend>

<depend>roscpp</depend>
</package>
71 changes: 0 additions & 71 deletions src/CMakeLists.txt

This file was deleted.

0 comments on commit 5518627

Please sign in to comment.