Skip to content

Commit

Permalink
[debian] Use a single rules file
Browse files Browse the repository at this point in the history
  • Loading branch information
gergondet committed Apr 8, 2023
1 parent 5281802 commit 6d4ae83
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 23 deletions.
27 changes: 25 additions & 2 deletions debian/rules
Original file line number Diff line number Diff line change
@@ -1,13 +1,36 @@
#!/usr/bin/make -f
# -*- makefile -*-

TMP = $(CURDIR)/debian/tmp
TMP:=$(CURDIR)/debian/tmp

export ROS_DISTRO=@ROS_DISTRO@
ifeq (${ROS_DISTRO},)
export ROS_PYTHON_VERSION:=$(shell . /opt/ros/${ROS_DISTRO}/setup.sh && echo $$ROS_PYTHON_VERSION)
ifeq (${ROS_PYTHON_VERSION}, 3)
export PYTHONPATH:=/opt/ros/${ROS_DISTRO}/lib/python3/dist-packages:${PYTHONPATH}
export PYTHON_EXECUTABLE=python3
else
export PYTHONPATH:=/opt/ros/${ROS_DISTRO}/lib/python2.7/dist-packages:${PYTHONPATH}
export PYTHON_EXECUTABLE=python2
endif
export PKG_CONFIG_PATH=/opt/ros/${ROS_DISTRO}/lib/pkgconfig:$PKG_CONFIG_PATH
export ROS_MASTER_URI=http://localhost:11311
export ROS_PACKAGE_PATH=/opt/ros/${ROS_DISTRO}/share
export CMAKE_PREFIX_PATH=/opt/ros/${ROS_DISTRO}:$CMAKE_PREFIX_PATH
export CMAKE_OPTIONS=-DCMAKE_INSTALL_PREFIX=/opt/ros/${ROS_DISTRO} -DBUILD_ROS_FREE_GUI:BOOL=ON -DPYTHON_EXECUTABLE=${PYTHON_EXECUTABLE}
export EXTRA_STEPS=mkdir -p $(TMP) && mv $(TMP)/opt/ros/${ROS_DISTRO}/lib/mc_rtc_rviz_panel/mc_rtc_gui_noros $(TMP)/usr/bin/mc_rtc_gui
else
export CMAKE_OPTIONS=
export EXTRA_STEPS=
endif


%:
dh $@

override_dh_auto_configure:
dh_auto_configure --
dh_auto_configure -- ${CMAKE_OPTIONS}

override_dh_auto_install:
dh_auto_install --destdir=$(TMP)
${EXTRA_STEPS}
21 changes: 0 additions & 21 deletions debian/rules.ros

This file was deleted.

0 comments on commit 6d4ae83

Please sign in to comment.