diff --git a/etc/cmake/Findsick_scan_base.cmake b/etc/cmake/Findsick_scan_base.cmake deleted file mode 100644 index faef3317d146d5fb44bddda029cf17d85128e3f2..0000000000000000000000000000000000000000 --- a/etc/cmake/Findsick_scan_base.cmake +++ /dev/null @@ -1,61 +0,0 @@ -# - Try to find sick_scan_base -# This module defines the following variables: -# sick_scan_base_FOUND : 1 if sick_scan_base was found, 0 otherwise -# sick_scan_base_INCLUDE_DIRS: directory where the headers can be found - -include(FindPackageHandleStandardArgs) - - -if (DEFINED ENV{sick_scan_base_DIR}) - if(NOT DEFINED sick_scan_base_DIR) - set(sick_scan_base_DIR $ENV{sick_scan_base_DIR}) - endif() -endif() - -#if(NOT "$ENV{sick_scan_base_DIR}" EQUAL "") -# set(sick_scan_base_DIR $ENV{sick_scan_base_DIR} CACHE PATH "Path to sick_scan_base" FORCE) -#endif() - -set(HEADER_SEARCH_PATHS - ${sick_scan_base_DIR}/include/ - ${sick_scan_base_DIR}/include/sick_scan/ - ${sick_scan_base_DIR}/include/tinyxml/ - ${sick_scan_base_DIR}/roswrap/src/include/ - ${sick_scan_base_DIR}/roswrap/src/rossimu/kinetic/include/ - ${sick_scan_base_DIR}/roswrap/src/cfgsimu/ - ENV CPATH - /usr/include/ - #/opt/ros/melodic/include/ - #/opt/ros/melodic/include/sick_scan/ -) - -#find_path(sick_scan_base_INCLUDE_DIR_7 NAMES sick_scan_common.h PATHS ${HEADER_SEARCH_PATHS} NO_DEFAULT_PATH) -#if(sick_scan_base_INCLUDE_DIR_7) -# set(sick_scan_base_INCLUDE_DIRS ${sick_scan_base_INCLUDE_DIR_7}) -#endif() -#find_library(sick_scan_base_LIBRARIES NAMES libsick_scan_lib.so PATHS /opt/ros/melodic/lib/ NO_DEFAULT_PATH) - -find_library(sick_scan_base_LIBRARIES NAMES libsick_scan_generic.so PATHS ${sick_scan_base_DIR}/build NO_DEFAULT_PATH) -message(STATUS "sick_scan_base_LIBRARIES:${sick_scan_base_LIBRARIES}") - -find_path(sick_scan_base_INCLUDE_DIR_0 NAMES sick_scan/sick_scan_common_tcp.h PATHS ${HEADER_SEARCH_PATHS} NO_DEFAULT_PATH) -find_path(sick_scan_base_INCLUDE_DIR_1 NAMES sick_generic_laser.h PATHS ${HEADER_SEARCH_PATHS} NO_DEFAULT_PATH) -find_path(sick_scan_base_INCLUDE_DIR_2 NAMES tinystr.h PATHS ${HEADER_SEARCH_PATHS} NO_DEFAULT_PATH) -find_path(sick_scan_base_INCLUDE_DIR_3 NAMES sick_scan/SickScanConfig.h PATHS ${HEADER_SEARCH_PATHS} NO_DEFAULT_PATH) -find_path(sick_scan_base_INCLUDE_DIR_4 NAMES dynamic_reconfigure/config_tools.h PATHS ${HEADER_SEARCH_PATHS} NO_DEFAULT_PATH) -find_path(sick_scan_base_INCLUDE_DIR_5 NAMES sick_scan/SickScanConfig.h PATHS ${HEADER_SEARCH_PATHS} NO_DEFAULT_PATH) -find_path(sick_scan_base_INCLUDE_DIR_6 NAMES sick_scan/rosconsole_simu.hpp PATHS ${HEADER_SEARCH_PATHS} NO_DEFAULT_PATH) - -if(sick_scan_base_INCLUDE_DIR_0 AND sick_scan_base_INCLUDE_DIR_1 AND sick_scan_base_INCLUDE_DIR_2 AND sick_scan_base_INCLUDE_DIR_3 AND sick_scan_base_INCLUDE_DIR_4 AND sick_scan_base_INCLUDE_DIR_5 AND sick_scan_base_INCLUDE_DIR_6) - set(sick_scan_base_INCLUDE_DIRS ${sick_scan_base_INCLUDE_DIR_0} ${sick_scan_base_INCLUDE_DIR_1} ${sick_scan_base_INCLUDE_DIR_2} ${sick_scan_base_INCLUDE_DIR_3} ${sick_scan_base_INCLUDE_DIR_4} ${sick_scan_base_INCLUDE_DIR_5} ${sick_scan_base_INCLUDE_DIR_6}) -endif() - - -message(STATUS "sick_scan_base_INCLUDE_DIRS:${sick_scan_base_INCLUDE_DIRS}") - -find_package_handle_standard_args(sick_scan_base DEFAULT_MSG sick_scan_base_INCLUDE_DIRS sick_scan_base_LIBRARIES) - -mark_as_advanced(sick_scan_base_INCLUDE_DIRS sick_scan_base_LIBRARIES) - - - diff --git a/source/RobotAPI/drivers/SickLaserUnit/CMakeLists.txt b/source/RobotAPI/drivers/SickLaserUnit/CMakeLists.txt index f1e94f9b2478222809011ad2c150f2b97d0c9e72..001528cc18d893d969f2aa191651c1a39e3040a6 100644 --- a/source/RobotAPI/drivers/SickLaserUnit/CMakeLists.txt +++ b/source/RobotAPI/drivers/SickLaserUnit/CMakeLists.txt @@ -16,8 +16,6 @@ armarx_set_target("Library: ${LIB_NAME}") find_package(sick_scan_base) -armarx_build_if(sick_scan_base_FOUND "sick_scan_base not available") -add_definitions(-DROSSIMU) find_package(Boost COMPONENTS system filesystem thread REQUIRED) armarx_build_if(Boost_FOUND "Boost not available") @@ -40,7 +38,7 @@ armarx_add_component( # This component ## SickLaserUnitInterfaces # If you defined a component ice interface above. - ${sick_scan_base_LIBRARIES} + sick_scan_base::sick_scan_generic ${Boost_LIBRARIES} SOURCES