commit: 43acae5fae6ec15456039f9be02ddec40f916b67 Author: Alexis Ballier <aballier <AT> gentoo <DOT> org> AuthorDate: Tue Aug 3 13:46:20 2021 +0000 Commit: Alexis Ballier <aballier <AT> gentoo <DOT> org> CommitDate: Tue Aug 3 14:12:20 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=43acae5f
dev-ros/image_cb_detector: fix python script Closes: https://bugs.gentoo.org/803011 Package-Manager: Portage-3.0.20, Repoman-3.0.3 Signed-off-by: Alexis Ballier <aballier <AT> gentoo.org> dev-ros/image_cb_detector/files/py3.patch | 22 ++++++++++++++++++++++ ....ebuild => image_cb_detector-0.10.15-r1.ebuild} | 2 +- .../image_cb_detector-9999.ebuild | 2 +- 3 files changed, 24 insertions(+), 2 deletions(-) diff --git a/dev-ros/image_cb_detector/files/py3.patch b/dev-ros/image_cb_detector/files/py3.patch new file mode 100644 index 00000000000..54475afd66d --- /dev/null +++ b/dev-ros/image_cb_detector/files/py3.patch @@ -0,0 +1,22 @@ +Index: image_cb_detector/src/image_cb_detector/cb_detector.py +=================================================================== +--- image_cb_detector.orig/src/image_cb_detector/cb_detector.py ++++ image_cb_detector/src/image_cb_detector/cb_detector.py +@@ -39,7 +39,7 @@ NAME = 'image_cb_detector_node' + import roslib; roslib.load_manifest(PKG) + + import rospy +-import cv ++import cv2 as cv + import math + + from sensor_msgs.msg import Image +@@ -130,7 +130,7 @@ class ImageCbDetectorNode: + #we need to convert the ros image to an opencv image + try: + image = self.bridge.imgmsg_to_cv(ros_image, "mono8") +- except CvBridgeError, e: ++ except CvBridgeError as e: + rospy.logerror("Error importing image %s" % e) + return + diff --git a/dev-ros/image_cb_detector/image_cb_detector-0.10.15.ebuild b/dev-ros/image_cb_detector/image_cb_detector-0.10.15-r1.ebuild similarity index 91% rename from dev-ros/image_cb_detector/image_cb_detector-0.10.15.ebuild rename to dev-ros/image_cb_detector/image_cb_detector-0.10.15-r1.ebuild index 72b5cebfd88..3cb98fba9da 100644 --- a/dev-ros/image_cb_detector/image_cb_detector-0.10.15.ebuild +++ b/dev-ros/image_cb_detector/image_cb_detector-0.10.15-r1.ebuild @@ -30,4 +30,4 @@ DEPEND="${RDEPEND} dev-ros/sensor_msgs[${CATKIN_MESSAGES_CXX_USEDEP}] dev-ros/calibration_msgs[${CATKIN_MESSAGES_CXX_USEDEP}] " -PATCHES=( "${FILESDIR}/gcc6.patch" "${FILESDIR}/c11.patch" ) +PATCHES=( "${FILESDIR}/gcc6.patch" "${FILESDIR}/c11.patch" "${FILESDIR}/py3.patch" ) diff --git a/dev-ros/image_cb_detector/image_cb_detector-9999.ebuild b/dev-ros/image_cb_detector/image_cb_detector-9999.ebuild index 72b5cebfd88..3cb98fba9da 100644 --- a/dev-ros/image_cb_detector/image_cb_detector-9999.ebuild +++ b/dev-ros/image_cb_detector/image_cb_detector-9999.ebuild @@ -30,4 +30,4 @@ DEPEND="${RDEPEND} dev-ros/sensor_msgs[${CATKIN_MESSAGES_CXX_USEDEP}] dev-ros/calibration_msgs[${CATKIN_MESSAGES_CXX_USEDEP}] " -PATCHES=( "${FILESDIR}/gcc6.patch" "${FILESDIR}/c11.patch" ) +PATCHES=( "${FILESDIR}/gcc6.patch" "${FILESDIR}/c11.patch" "${FILESDIR}/py3.patch" )
