Gentoo Archives: gentoo-commits

From: Alexis Ballier <aballier@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-ros/pluginlib/, dev-ros/pluginlib/files/
Date: Mon, 28 Nov 2016 15:11:37
Message-Id: 1480345468.2701f4e2ecddcdce15248edf2f4d66936b3187ef.aballier@gentoo
1 commit: 2701f4e2ecddcdce15248edf2f4d66936b3187ef
2 Author: Alexis Ballier <aballier <AT> gentoo <DOT> org>
3 AuthorDate: Mon Nov 28 15:04:16 2016 +0000
4 Commit: Alexis Ballier <aballier <AT> gentoo <DOT> org>
5 CommitDate: Mon Nov 28 15:04:28 2016 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2701f4e2
7
8 dev-ros/pluginlib: look for package.xml in ros_packages too for plugins.
9
10 Package-Manager: portage-2.3.2
11
12 dev-ros/pluginlib/files/gentoo.patch | 34 ++++++++++++++++++++++
13 ...ib-1.10.4.ebuild => pluginlib-1.10.4-r1.ebuild} | 1 +
14 dev-ros/pluginlib/pluginlib-9999.ebuild | 1 +
15 3 files changed, 36 insertions(+)
16
17 diff --git a/dev-ros/pluginlib/files/gentoo.patch b/dev-ros/pluginlib/files/gentoo.patch
18 new file mode 100644
19 index 00000000..6737f76
20 --- /dev/null
21 +++ b/dev-ros/pluginlib/files/gentoo.patch
22 @@ -0,0 +1,34 @@
23 +Find package.xml in ros_packages/package_name too as we moved it here.
24 +
25 +Index: pluginlib-1.10.4/include/pluginlib/class_loader_imp.h
26 +===================================================================
27 +--- pluginlib-1.10.4.orig/include/pluginlib/class_loader_imp.h
28 ++++ pluginlib-1.10.4/include/pluginlib/class_loader_imp.h
29 +@@ -444,6 +444,7 @@ namespace pluginlib
30 + std::string package_name;
31 + boost::filesystem::path p(plugin_xml_file_path);
32 + boost::filesystem::path parent = p.parent_path();
33 ++ boost::filesystem::path basename = p.filename();
34 +
35 + //Figure out exactly which package the passed XML file is exported by.
36 + while (true)
37 +@@ -453,6 +454,11 @@ namespace pluginlib
38 + std::string package_file_path = (boost::filesystem::path(parent / "package.xml")).string();
39 + return(extractPackageNameFromPackageXML(package_file_path));
40 + }
41 ++ else if(boost::filesystem::exists(parent / "ros_packages" / basename / "package.xml"))
42 ++ {
43 ++ std::string package_file_path = (boost::filesystem::path(parent / "ros_packages" / basename / "package.xml")).string();
44 ++ return(extractPackageNameFromPackageXML(package_file_path));
45 ++ }
46 + else if (boost::filesystem::exists(parent / "manifest.xml"))
47 + {
48 + #if BOOST_FILESYSTEM_VERSION >= 3
49 +@@ -470,6 +476,7 @@ namespace pluginlib
50 + }
51 +
52 + //Recursive case - hop one folder up
53 ++ basename = parent.filename();
54 + parent = parent.parent_path().string();
55 +
56 + //Base case - reached root and cannot find what we're looking for
57
58 diff --git a/dev-ros/pluginlib/pluginlib-1.10.4.ebuild b/dev-ros/pluginlib/pluginlib-1.10.4-r1.ebuild
59 similarity index 93%
60 rename from dev-ros/pluginlib/pluginlib-1.10.4.ebuild
61 rename to dev-ros/pluginlib/pluginlib-1.10.4-r1.ebuild
62 index 2791a4d..a96bdae 100644
63 --- a/dev-ros/pluginlib/pluginlib-1.10.4.ebuild
64 +++ b/dev-ros/pluginlib/pluginlib-1.10.4-r1.ebuild
65 @@ -25,3 +25,4 @@ RDEPEND="
66 "
67 DEPEND="${RDEPEND}
68 test? ( dev-cpp/gtest )"
69 +PATCHES=( "${FILESDIR}/gentoo.patch" )
70
71 diff --git a/dev-ros/pluginlib/pluginlib-9999.ebuild b/dev-ros/pluginlib/pluginlib-9999.ebuild
72 index 2791a4d..a96bdae 100644
73 --- a/dev-ros/pluginlib/pluginlib-9999.ebuild
74 +++ b/dev-ros/pluginlib/pluginlib-9999.ebuild
75 @@ -25,3 +25,4 @@ RDEPEND="
76 "
77 DEPEND="${RDEPEND}
78 test? ( dev-cpp/gtest )"
79 +PATCHES=( "${FILESDIR}/gentoo.patch" )