[ros-ros-comm] 01/01: Add patch for roswtf
Jochen Sprickerhof
jspricke-guest at moszumanska.debian.org
Sun Nov 15 20:35:17 UTC 2015
This is an automated email from the git hooks/post-receive script.
jspricke-guest pushed a commit to branch master
in repository ros-ros-comm.
commit e5d40c6eeda96ae5c358b5b710f134358e109096
Author: Jochen Sprickerhof <git at jochen.sprickerhof.de>
Date: Sun Nov 15 21:18:57 2015 +0100
Add patch for roswtf
---
debian/patches/0005-Add-defaults-to-roswtf.patch | 59 ++++++++++++++++++++++++
debian/patches/series | 1 +
2 files changed, 60 insertions(+)
diff --git a/debian/patches/0005-Add-defaults-to-roswtf.patch b/debian/patches/0005-Add-defaults-to-roswtf.patch
new file mode 100644
index 0000000..d194bd6
--- /dev/null
+++ b/debian/patches/0005-Add-defaults-to-roswtf.patch
@@ -0,0 +1,59 @@
+From: Jochen Sprickerhof <git at jochen.sprickerhof.de>
+Date: Sun, 15 Nov 2015 21:18:11 +0100
+Subject: Add defaults to roswtf
+
+---
+ utilities/roswtf/src/roswtf/__init__.py | 2 +-
+ utilities/roswtf/src/roswtf/context.py | 8 ++++----
+ utilities/roswtf/src/roswtf/rosdep_db.py | 4 ++--
+ 3 files changed, 7 insertions(+), 7 deletions(-)
+
+diff --git a/utilities/roswtf/src/roswtf/__init__.py b/utilities/roswtf/src/roswtf/__init__.py
+index 8527cfb..ac2da80 100644
+--- a/utilities/roswtf/src/roswtf/__init__.py
++++ b/utilities/roswtf/src/roswtf/__init__.py
+@@ -140,7 +140,7 @@ def _roswtf_main():
+ static_plugins, online_plugins = [], []
+
+ # - do a ros_root check first and abort if it fails as rest of tests are useless after that
+- error = ros_root_check(None, ros_root=os.environ['ROS_ROOT'])
++ error = ros_root_check(None, ros_root=os.environ.get('ROS_ROOT', '/usr/share/ros'))
+ if error:
+ print("ROS_ROOT is invalid: "+str(error))
+ sys.exit(1)
+diff --git a/utilities/roswtf/src/roswtf/context.py b/utilities/roswtf/src/roswtf/context.py
+index fdab98d..82f0e3b 100644
+--- a/utilities/roswtf/src/roswtf/context.py
++++ b/utilities/roswtf/src/roswtf/context.py
+@@ -296,11 +296,11 @@ def _load_env(ctx, env):
+ """
+ ctx.env = env
+ try:
+- ctx.ros_root = env[rospkg.environment.ROS_ROOT]
++ ctx.ros_root = env.get(rospkg.environment.ROS_ROOT, '/usr/share/ros')
+ except KeyError:
+ raise WtfException("ROS_ROOT is not set")
+- ctx.ros_package_path = env.get(rospkg.environment.ROS_PACKAGE_PATH, None)
+- ctx.pythonpath = env.get('PYTHONPATH', None)
+- ctx.ros_master_uri = env.get(rosgraph.ROS_MASTER_URI, None)
++ ctx.ros_package_path = env.get(rospkg.environment.ROS_PACKAGE_PATH, '/usr/share/ros')
++ ctx.pythonpath = env.get('PYTHONPATH', '/usr/lib/python2.7/dist-packages/')
++ ctx.ros_master_uri = env.get(rosgraph.ROS_MASTER_URI, 'http://localhost:11311')
+
+
+diff --git a/utilities/roswtf/src/roswtf/rosdep_db.py b/utilities/roswtf/src/roswtf/rosdep_db.py
+index 3173a91..b166e53 100644
+--- a/utilities/roswtf/src/roswtf/rosdep_db.py
++++ b/utilities/roswtf/src/roswtf/rosdep_db.py
+@@ -46,9 +46,9 @@ def rosdep_database_initialized_check(ctx):
+ if not os.path.exists((os.path.join(get_user_home_directory(), '.ros', 'rosdep', 'sources.cache', 'index'))):
+ return "Please initialize rosdep database with sudo rosdep init."
+
+-warnings = []
++errors = []
+
+-errors = [(rosdep_database_initialized_check,
++warnings = [(rosdep_database_initialized_check,
+ "ROS Dep database not initialized: "),
+ ]
+
diff --git a/debian/patches/series b/debian/patches/series
index fc61e4e..f49d041 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -2,3 +2,4 @@
0002-Add-Debian-specific-SONAMEs.patch
0003-Add-default-ROS_MASTER_URI.patch
0004-Fix-executable-not-elf-or-script.patch
+0005-Add-defaults-to-roswtf.patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/ros/ros-ros-comm.git
More information about the debian-science-commits
mailing list