bellande_functionality_api/web_api_bellande_probabilistic/CMakeLists.txt

62 lines
2.0 KiB
CMake
Raw Normal View History

2024-04-26 00:25:51 +00:00
# Copyright (C) 2024 Bellande Robotics Sensors Research Innovation Center, Ronaldson Bellande
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
2024-03-28 23:54:22 +00:00
cmake_minimum_required(VERSION 3.8)
2024-12-12 21:43:52 +00:00
project(web_api_bellande_probabilistic)
2024-03-28 23:54:22 +00:00
# Find ROS
if($ENV{ROS_VERSION} EQUAL 1)
find_package(catkin REQUIRED COMPONENTS
roscpp
rospy
)
else()
find_package(ament_cmake REQUIRED COMPONENTS
rclcpp
rclpy
)
endif()
if($ENV{ROS_VERSION} EQUAL 1)
catkin_package(
INCLUDE_DIRS
LIBRARIES ${PROJECT_NAME}
CATKIN_DEPENDS
roscpp
rospy
)
endif()
2024-05-23 23:30:40 +00:00
# Install Python scripts for both ROS 1
if($ENV{ROS_VERSION} EQUAL 1)
catkin_install_python(
PROGRAMS
2024-12-12 21:43:52 +00:00
src/bellande_probabilistic_api_2d.py
2024-05-23 23:30:40 +00:00
DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)
endif()
2024-03-28 23:54:22 +00:00
# Install Python scripts, configuration files, and launch files
if($ENV{ROS_VERSION} EQUAL "1")
2024-12-12 21:43:52 +00:00
install(PROGRAMS src/bellande_probabilistic_api_2d.py DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION})
2024-03-28 23:54:22 +00:00
install(DIRECTORY config/ DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}/config)
install(DIRECTORY launch/ DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}/launch)
elseif($ENV{ROS_VERSION} EQUAL "2")
2024-12-12 21:43:52 +00:00
install(PROGRAMS src/bellande_probabilistic_api_2d.py DESTINATION lib/${PROJECT_NAME})
2024-03-28 23:54:22 +00:00
install(DIRECTORY config/ DESTINATION share/${PROJECT_NAME}/config)
install(DIRECTORY launch/ DESTINATION share/${PROJECT_NAME}/launch)
2024-05-23 23:30:40 +00:00
ament_package()
2024-03-28 23:54:22 +00:00
endif()