roscore and rosnodes working

Up until now the nodes launched from the meta-ros code weren’t working (they hang) but after the work at the issue #68 they seem to work properly.

I created a patch that fixes this situation. If you’re interested you can just apply it to oe-core but hopefully this patch get be pushed to the Angstrom oe-core.

From 30b73ddd1c3ddbd03a083c2ad9c4fcedf7749d32 Mon Sep 17 00:00:00 2001
From: victor 
Date: Mon, 1 Jul 2013 14:46:42 +0200
Subject: [PATCH] apr_cv_mutex_recursive=yes added to to make
 rosnodes work
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Working with the meta-ros project we detected that the ROS nodes didn't launch properly
the reason was that by default apr_cv_mutex_recursive in apr is set to no and this leads
to the APRENOTIMPL return value of apr_thread_mutex_create in thread_mutex.c when
APR_THREAD_MUTEX_NESTED is requested via flags.

Added CACHED_CONFIGUREVARS += "apr_cv_mutex_recursive=yes" to sources/openembedded-core/meta/recipes-support/apr/
to fix this issue. It has also been removed the mention of this variable in

Signed-off-by: Víctor Mayoral Vilches 
 meta/recipes-support/apr/ |    3 +++
 meta/site/powerpc32-linux             |    1 -
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/meta/recipes-support/apr/ b/meta/recipes-support/apr/
index 896f79f..ba59639 100644
--- a/meta/recipes-support/apr/
+++ b/meta/recipes-support/apr/
@@ -23,6 +23,9 @@ inherit autotools lib_package binconfig multilib_header
 OE_BINCONFIG_EXTRA_MANGLE = " -e 's:location=source:location=installed:'"
+# Added to fix some issues with cmake. Refer to
+CACHED_CONFIGUREVARS += "apr_cv_mutex_recursive=yes"
 do_configure_prepend() {
 	cd ${S}
diff --git a/meta/site/powerpc32-linux b/meta/site/powerpc32-linux
index 4550df3..b3973c9 100644
--- a/meta/site/powerpc32-linux
+++ b/meta/site/powerpc32-linux
@@ -203,7 +203,6 @@ apr_cv_use_lfs64=${apr_cv_use_lfs64=yes}

Update: Make sure you check the source to get the latest version of the patch


19 thoughts on “roscore and rosnodes working

  1. Les Oakes says:

    excellent find!!! I had started attacking this problem in May with no success. Congratulations! And much success with your project!

  2. HvN says:

    I’m using a BeagleBoard-xM (Angstrom, 2.6.32 arm7l) and want to install ROS. So far neither opkg nor git is working for me. Can you please tell me how to install ROS ?

  3. hvn says:

    Since the heanet document keeps giving library problems, and will go to building recipes. However, after downloading en unpacking the master zip, I get this:

    $ MACHINE=beagleboard-xm ./ config beagleboard-xm
    BASE_VERSION mismatch, recreating /home/huub/.oe/environment-angstromv2012.12
    There now is a sourceable script in ~/.oe/enviroment. You can do ‘. /home/huub/.oe/environment-angstromv2012.12’ and run ‘bitbake something’ without using ./ as wrapper
    env: gawk: No such file or directory

    Setup for beagleboard-xm completed
    huub@Lubuntu-cross:~/PERA$ . /home/huub/.oe/environment-angstromv2012.12
    $ bitbake roscore
    Traceback (most recent call last):
    File “/usr/bin/bitbake”, line 35, in
    import bb
    File “/usr/lib/pymodules/python2.7/bb/”, line 71, in
    from bb import fetch2 as fetch
    ImportError: cannot import name fetch2
    /usr/lib/pymodules/python2.7/bb/ RuntimeWarning: Parent module ‘bb’ not found while handling absolute import
    from bb.msg import BBLogFormatter
    Error in atexit._run_exitfuncs:
    Traceback (most recent call last):
    File “/usr/lib/python2.7/”, line 24, in _run_exitfuncs
    func(*targs, **kargs)
    File “/usr/lib/pymodules/python2.7/bb/”, line 87, in print_ui_queue
    from bb.msg import BBLogFormatter
    File “/usr/lib/pymodules/python2.7/bb/”, line 71, in
    from bb import fetch2 as fetch

    Could you tell me what I’m doing wrong ? Thank you.

  4. hvn says:

    I obviously was acting too fast on that. However, after installing awk and dependencies, I still get the message that it can’t import fetch2 which would have something to do with bb (which isn’t in the zip). I searched for this and there is no fetch2 or fetch package. Is there still a missing package or script ?

    • hvn, great hearing that you fixed the dependencies.

      I haven’t tested the code in the Beagleboard-xm (don’t have access to one) but i would guess it should work as well.

      To me it seems like you still have some missing dependencies. According to your log, bitbake doesn’t even read the recipes. That’s probably an Angstrom installation issue. Make sure you followed properly

      Try posting your error log and i might be able to help you a little.

  5. hvn says:

    Well, like I said in my first comment, I do have Angstrom running on the xM, and it’s prepared to run using the DSP (which is tested ok). So steps 1 and 2 of that building-angstrom link have been completed, be it not by me. All I actually want to do is to install ROS and some ROS-using software I wrote myself. What would be your suggestion to do in this case? Tried to find a log in the build directory but there is none.

  6. Having Angstrom running in your board and having a “properly” Angstrom build setup are totally different things hvn.

    I suspect you’re having trouble with the second.

    Could you at least post the complete error you get?

  7. hvn says:

    I have tried posting questions to the angstrom mailing list, but I get them all back for “taking to too long reach” the email address.
    I set up .profile and I’m trying to follow this page: and have a question about bitbake: is it supposed to come with e.g. meta-oe and oe-core? I get this error: Error: “The bitbake directory (/home/hvn/OE/oe-core/bitbake) does not exist! Please ensure a copy of bitbake exists at this location”. While I also get this:
    /OE$ find . -name bitbake
    Do I again miss some instructions ?

  8. hvn says:

    Trying to bitbake roscore, it gives this error: “ERROR: no recipe files to build, check your BBPATH and BBFILES?” Since the recipes are clearly there, I checked and find that in layer.conf BBPATH .= “:${LAYERDIR}”, but LAYERDIR is empty (checked with echo) and I can’t find where it is set. Searching on the net has given no clue either.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s