- Fix the usage of 'python' to get rid of the implicit lang/python
dependency
This commit is contained in:
parent
1af613cfd7
commit
89b7dc8cdb
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=334746
5 changed files with 35 additions and 10 deletions
|
@ -5,7 +5,7 @@ PORTNAME= ros-common_msgs
|
|||
PORTVERSION= 1.4.0
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= devel
|
||||
MASTER_SITES= https://code.ros.org/svn/release/download/stacks/common_msgs/common_msgs-${PORTVERSION}/
|
||||
MASTER_SITES= https://code.ros.org/svn/release/download/stacks/common_msgs/common_msgs-${PORTVERSION}/
|
||||
DISTNAME= common_msgs-${PORTVERSION}
|
||||
DIST_SUBDIR= ros
|
||||
|
||||
|
@ -20,10 +20,18 @@ BUILD_DEPENDS= rosmake:${PORTSDIR}/devel/ros \
|
|||
${LOCALBASE}/ros/stacks/ros_comm/stack.xml:${PORTSDIR}/devel/ros_comm
|
||||
RUN_DEPENDS= roscore:${PORTSDIR}/devel/ros \
|
||||
${LOCALBASE}/ros/stacks/ros_comm/stack.xml:${PORTSDIR}/devel/ros_comm
|
||||
USE_PYTHON= yes
|
||||
|
||||
USES= shebangfix
|
||||
USE_PYTHON= 2
|
||||
USE_BZIP2= yes
|
||||
USE_LDCONFIG= yes
|
||||
|
||||
python_OLD_CMD= /usr/bin/env python
|
||||
python_CMD= /usr/bin/env python2
|
||||
SHEBANG_FILES= actionlib_msgs/genaction.py \
|
||||
stereo_msgs/migration_rules/split_rawstereo.py \
|
||||
test_common_msgs/test/test_common_msgs_migration.py
|
||||
|
||||
# rosmake does its own threading
|
||||
MAKE_JOBS_UNSAFE= yes
|
||||
|
||||
|
@ -55,7 +63,7 @@ do-install:
|
|||
${INSTALL_DATA} ${WRKSRC}/${f} ${PREFIX}/ros/stacks/${STACKNAME}
|
||||
.endfor
|
||||
#strip and symlink ELF libraries
|
||||
.for f in sensor_msgs/lib/libsensor_msgs.so
|
||||
.for f in sensor_msgs/lib/libsensor_msgs.so
|
||||
${STRIP_CMD} ${PREFIX}/ros/stacks/${STACKNAME}/${f}
|
||||
${LN} -s ${PREFIX}/ros/stacks/${STACKNAME}/${f} ${PREFIX}/lib
|
||||
.endfor
|
||||
|
|
|
@ -23,7 +23,7 @@ RUN_DEPENDS= rosrun:${PORTSDIR}/devel/ros \
|
|||
sphinx-build:${PORTSDIR}/textproc/py-sphinx \
|
||||
doxygen:${PORTSDIR}/devel/doxygen \
|
||||
epydoc:${PORTSDIR}/devel/epydoc
|
||||
USE_PYTHON= yes
|
||||
USE_PYTHON= 2
|
||||
USE_BZIP2= yes
|
||||
|
||||
# rosmake does its own threading
|
||||
|
@ -40,6 +40,8 @@ MAKE_ARGS= -i --no-rosdep --status-rate=0 --disable-logging
|
|||
|
||||
NO_STAGE= yes
|
||||
post-patch:
|
||||
@${GREP} -l -r "^#\!/usr/bin/env python" ${WRKSRC} | ${XARGS} \
|
||||
${REINPLACE_CMD} -E -e "s|#!/usr/bin/env python|#!/usr/bin/env python2|"
|
||||
# fix path to bash
|
||||
${GREP} -l -r "^#\! /bin/bash" ${WRKSRC} | ${XARGS} \
|
||||
${REINPLACE_CMD} -E -e "s|#! /bin/bash|#!${LOCALBASE}/bin/bash|"
|
||||
|
|
|
@ -36,7 +36,7 @@ RUN_DEPENDS= roscore:${PORTSDIR}/devel/ros \
|
|||
${LOCALBASE}/ros/stacks/common_msgs/stack.xml:${PORTSDIR}/devel/ros-common_msgs \
|
||||
${LOCALBASE}/ros/stacks/geometry/stack.xml:${PORTSDIR}/math/ros-geometry \
|
||||
${PYTHON_SITELIBDIR}/usb.so:${PORTSDIR}/devel/py-usb
|
||||
USE_PYTHON= yes
|
||||
USE_PYTHON= 2
|
||||
USE_BZIP2= yes
|
||||
|
||||
# rosmake does its own threading
|
||||
|
@ -67,6 +67,12 @@ post-extract:
|
|||
# and keeping it here breaks rospack
|
||||
${RM} -rf ${WRKSRC}/nxt_rviz_plugin
|
||||
|
||||
post-patch:
|
||||
@${GREP} -l -r "^#\!/usr/bin/env python" ${WRKSRC} | ${XARGS} \
|
||||
${REINPLACE_CMD} -E -e "s|#!/usr/bin/env python|#!/usr/bin/env python2|"
|
||||
@${REINPLACE_CMD} -e 's|python setup.py|python2 setup.py|' \
|
||||
${WRKSRC}/nxt_python/Makefile
|
||||
|
||||
do-build:
|
||||
(cd ${WRKSRC} ; ${MAKE_ENV} ${LOCALBASE}/bin/rosmake ${MAKE_ARGS})
|
||||
|
||||
|
|
|
@ -30,7 +30,7 @@ RUN_DEPENDS= ${PYTHON_SITELIBDIR}/yaml/__init__.py:${PORTSDIR}/devel/py-yaml \
|
|||
gmake:${PORTSDIR}/devel/gmake \
|
||||
sudo:${PORTSDIR}/security/sudo \
|
||||
wget:${PORTSDIR}/ftp/wget
|
||||
USE_PYTHON= yes
|
||||
USE_PYTHON= 2
|
||||
USE_BZIP2= yes
|
||||
USE_LDCONFIG= yes
|
||||
USES= pkgconfig
|
||||
|
@ -56,12 +56,19 @@ PORTDOCS= AUTHORS README
|
|||
|
||||
NO_STAGE= yes
|
||||
post-patch:
|
||||
${GREP} -l -r "^#! /usr/bin/env python" ${WRKSRC} | ${XARGS} \
|
||||
${REINPLACE_CMD} -E -e "s|^#! /usr/bin/env python$$|#!/usr/bin/env python2|;"
|
||||
${GREP} -l -r "^#!/usr/bin/env python$$" ${WRKSRC} | ${XARGS} \
|
||||
${REINPLACE_CMD} -E -e "s|^#!/usr/bin/env python$$|#!/usr/bin/env python2|;"
|
||||
# fix path to bash
|
||||
${GREP} -l -r "^#\!/bin/bash" ${WRKSRC} | ${XARGS} \
|
||||
${REINPLACE_CMD} -E -e "s|#!/bin/bash|#!${LOCALBASE}/bin/bash|"
|
||||
${REINPLACE_CMD} -E -e "s|#!/bin/bash|#!${LOCALBASE}/bin/bash|"
|
||||
# temporarily alter how ROS is built for the port build
|
||||
${REINPLACE_CMD} -E -e "s|rosmake --rosdep-install|bin/rosmake --no-rosdep --disable-logging -i -a|" \
|
||||
${WRKSRC}/Makefile
|
||||
${WRKSRC}/Makefile
|
||||
${REINPLACE_CMD} -e 's|COMMAND python|COMMAND python2|' \
|
||||
${WRKSRC}/core/rosbuild/public.cmake \
|
||||
${WRKSRC}/core/rosbuild/private.cmake
|
||||
|
||||
post-build:
|
||||
# restore original ROS Makefile
|
||||
|
|
|
@ -22,7 +22,7 @@ BUILD_DEPENDS= rosmake:${PORTSDIR}/devel/ros \
|
|||
RUN_DEPENDS= roscore:${PORTSDIR}/devel/ros \
|
||||
f2py:${PORTSDIR}/math/py-numpy \
|
||||
pilconvert.py:${PORTSDIR}/graphics/py-imaging
|
||||
USE_PYTHON= yes
|
||||
USE_PYTHON= 2
|
||||
USE_BZIP2= yes
|
||||
USE_LDCONFIG= yes
|
||||
|
||||
|
@ -43,6 +43,8 @@ post-patch:
|
|||
# fix path to bash
|
||||
${GREP} -l -r "^#\!/bin/bash" ${WRKSRC} | ${XARGS} \
|
||||
${REINPLACE_CMD} -E -e "s|#!/bin/bash|#!${LOCALBASE}/bin/bash|"
|
||||
${GREP} -l -r "^#\!/usr/bin/env python" ${WRKSRC} | ${XARGS} \
|
||||
${REINPLACE_CMD} -E -e "s|#!/usr/bin/env python|#!/usr/bin/env python2|"
|
||||
|
||||
do-build:
|
||||
(cd ${WRKSRC} ; ${MAKE_ENV} ${LOCALBASE}/bin/rosmake ${MAKE_ARGS})
|
||||
|
@ -58,7 +60,7 @@ do-install:
|
|||
${FIND} ${WRKSRC}/${d} -name build -type d -or -name \*.bak -type f \
|
||||
-or -name .svnignore -type f -or -name .cvsignore -type f \
|
||||
-or -name \*.orig -type f | ${XARGS} ${RM} -rf
|
||||
(cd ${WRKSRC} && ${COPYTREE_SHARE} ${d} ${PREFIX}/ros/stacks/${STACKNAME})
|
||||
(cd ${WRKSRC} && ${COPYTREE_SHARE} ${d} ${PREFIX}/ros/stacks/${STACKNAME})
|
||||
.endfor
|
||||
# strip and symlink ELF libraries
|
||||
.for f in clients/cpp/roscpp/lib/libros.so \
|
||||
|
|
Loading…
Reference in a new issue