Permalink
Browse files

creating stack and adding OMPL

  • Loading branch information...
Ioan Sucan
Ioan Sucan committed Oct 12, 2011
0 parents commit 206e93c555a6ddcdbe826809c30b90b89bbb52d8
@@ -0,0 +1,17 @@
cmake_minimum_required(VERSION 2.4.6)
include($ENV{ROS_ROOT}/core/rosbuild/rosbuild.cmake)
# Append to CPACK_SOURCE_IGNORE_FILES a semicolon-separated list of
# directories (or patterns, but directories should suffice) that should
# be excluded from the distro. This is not the place to put things that
# should be ignored everywhere, like "build" directories; that happens in
# rosbuild/rosbuild.cmake. Here should be listed packages that aren't
# ready for inclusion in a distro.
#
# This list is combined with the list in rosbuild/rosbuild.cmake. Note
# that CMake 2.6 may be required to ensure that the two lists are combined
# properly. CMake 2.4 seems to have unpredictable scoping rules for such
# variables.
#list(APPEND CPACK_SOURCE_IGNORE_FILES /core/experimental)
rosbuild_make_distribution(0.1.0)
@@ -0,0 +1 @@
include $(shell rospack find mk)/cmake_stack.mk
@@ -0,0 +1,22 @@
cmake_minimum_required(VERSION 2.4.6)
include($ENV{ROS_ROOT}/core/rosbuild/rosbuild.cmake)
set(ROS_BUILD_TYPE Release)
rosbuild_init()
execute_process(COMMAND cmake -E chdir ${PROJECT_SOURCE_DIR} make -f Makefile.ompl
RESULT_VARIABLE _make_failed)
if(_make_failed)
message(FATAL_ERROR "Build of ompl failed")
endif(_make_failed)
message("Using ompl from ${OMPL_SOURCE}")
set(PROJECT_SOURCE_DIR ${PROJECT_SOURCE_DIR}/${OMPL_SOURCE})
option(OMPL_IN_ROS "Build OMPL against ROS" ON)
option(OMPL_BUILD_DEMOS "Build OMPL demos" OFF)
option(OMPL_BUILD_PYBINDINGS "Build OMPL Python bindings" OFF)
option(OMPL_BUILD_DOC "Build OMPL documentation" OFF)
add_subdirectory(${OMPL_SOURCE})
@@ -0,0 +1,26 @@
include Makefile.params
INSTALL_LOCATION=installation
EXTRA_CMAKE_FLAGS=-DCMAKE_INSTALL_PREFIX=`pwd`/../$(INSTALL_LOCATION) -DOMPL_SOURCE:string="$(SOURCE_DIR)"
ompltoplevel: all installed
include $(shell rospack find mk)/cmake.mk
clean: extra-clean
installed:
cd build && make install
touch installed
extra-clean:
make -f Makefile.ompl clean
rm -f installed
wipeNoClean:
make -f Makefile.ompl wipe
rm -rf $(INSTALL_LOCATION) $(SOURCE_DIR)
wipe: wipeNoClean clean
-rm -rf bin
@@ -0,0 +1,19 @@
include Makefile.params
all: copied
# We build from a tarball from the latest version of ompl
include $(shell rospack find mk)/download_unpack_build.mk
copied: wiped $(SOURCE_DIR)/unpacked
touch copied
wipe:
rm -rf copied patched
wiped: Makefile.ompl Makefile.params
make -f Makefile wipeNoClean
touch wiped
clean:
@@ -0,0 +1,8 @@
FILENAME = ompl-1237.tar.gz
TARBALL = build/$(FILENAME)
TARBALL_URL = https://code.ros.org/svn/release/download/thirdparty/ompl/$(FILENAME)
TARBALL_PATCH = console.patch
SOURCE_DIR = build/ompl_arch
UNPACK_CMD = tar xzf
MD5SUM_FILE = $(FILENAME).md5sum
@@ -0,0 +1,15 @@
# These are instructions for updating the ROS package that wraps the release of OMPL from Rice University.
# These instructions are only intended for and useful to the maintainers (Willow Garage) of the OMPL ROS wrapper package and have limited to no utility for users.
# Get the ROS package for OMPL as provided by Rice:
svn co https://rice-ros-pkg.svn.sourceforge.net/svnroot/rice-ros-pkg/ompl
cd ompl
# To get the latest version of the library, do:
make arch
# To get a particular tag/revision of the library, do:
OMPL_REVISION=1001 make arch
This will create a file of the form ompl-*.tar.gz and a file ompl-*.tar.gz.md5sum that can be used in the Willow Garage ROS package.
Copy this into the location for thirdparty packages at https://code.ros.org/svn/release/download/thirdparty/ompl/
@@ -0,0 +1,48 @@
Index: src/ompl/util/src/Console.cpp
===================================================================
--- src/ompl/util/src/Console.cpp
+++ src/ompl/util/src/Console.cpp
@@ -33,6 +33,7 @@
*********************************************************************/
/* Author: Ioan Sucan */
+#include <ros/console.h>
#include "ompl/util/Console.h"
#include <boost/thread/mutex.hpp>
@@ -41,7 +42,34 @@
#include <cstdio>
#include <cstdarg>
-static ompl::msg::OutputHandlerSTD DEFAULT_OUTPUT_HANDLER;
+namespace ompl
+{
+
+ namespace msg
+ {
+
+ class OutputHandlerROS : public OutputHandler
+ {
+ public:
+
+ OutputHandlerROS(void) : OutputHandler()
+ {
+ }
+
+ virtual void error(const std::string &text) { ROS_ERROR("%s", text.c_str()); }
+
+ virtual void warn(const std::string &text) { ROS_WARN("%s", text.c_str()); }
+
+ virtual void inform(const std::string &text) { ROS_INFO("%s", text.c_str()); }
+
+ virtual void debug(const std::string &text) { ROS_DEBUG("%s", text.c_str()); }
+
+ };
+
+ }
+}
+
+static ompl::msg::OutputHandlerROS DEFAULT_OUTPUT_HANDLER;
static ompl::msg::OutputHandler *OUTPUT_HANDLER = static_cast<ompl::msg::OutputHandler*>(&DEFAULT_OUTPUT_HANDLER);
static ompl::msg::OutputHandler *PREVIOUS_OH = OUTPUT_HANDLER;
static boost::mutex LOCK; // it is likely the outputhandler does some I/O, so we serialize it
@@ -0,0 +1,23 @@
<package>
<description brief="Open Motion Planning Library (OMPL)">
A library of sampling-based motion planning algorithms
</description>
<author>Ioan Sucan/isucan@rice.edu, Mark Moll/mmoll@rice.edu, Lydia Kavraki/kavraki@rice.edu</author>
<license>BSD</license>
<review status="unreviewed" notes=""/>
<url>http://ros.org/wiki/ompl</url>
<depend package="rosconsole" />
<export>
<cpp cflags="-I${prefix}/installation/include `rosboost-cfg --cflags`" lflags="-Wl,-rpath,${prefix}/installation/lib -L${prefix}/installation/lib -lompl `rosboost-cfg --lflags date_time,thread`"/>
</export>
<platform os="ubuntu" version="9.04"/>
<platform os="ubuntu" version="9.10"/>
<platform os="ubuntu" version="10.04"/>
<platform os="ubuntu" version="10.10"/>
</package>
@@ -0,0 +1 @@
cdd2fede7f7b45f8625035cc0649b46a ompl-1237.tar.gz
@@ -0,0 +1,11 @@
<stack>
<description brief="moveit">Implementation of generic components for planning and execution of motions.</description>
<author>Maintained by Sachin Chitta, Ioan Sucan</author>
<license>BSD</license>
<review status="unreviewed" notes=""/>
<url>http://ros.org/wiki/moveit</url>
<depend stack="ros" />
<depend stack="ros_comm" /> <!-- rosconsole -->
<depend stack="robot_model" />
</stack>

0 comments on commit 206e93c

Please sign in to comment.