Catkin cross-compilation of ros-groovy for Zynq ARM target
I'm attempting to cross-compile ROS src to a Zynq based ARM system running a version of Angstrom Linux. I've download src (groovy-ros-comm) based on the install from source instructions and created a catkin workspace. I've set up my rostoolchain.cmake file (embedded below) and successfully cross-compiled boost, apr, apr-util and log4cxx.
set(CMAKE_C_COMPILER /home/adminuser/CodeSourcery/Sourcery_G++_Lite/bin/arm-none-linux-gnueabi-gcc)
set(CMAKE_CXX_COMPILER /home/adminuser/CodeSourcery/Sourcery_G++_Lite/bin/arm-none-linux-gnueabi-g++)
set(CMAKE_FIND_ROOT_PATH /home/adminuser/CodeSourcery/Sourcery_G++_Lite)
set(CMAKE_LIBRARY_PATH /home/adminuser/CodeSourcery/Sourcery_G++_Lite/arm-none-linux-gnueabi/libc/usr/lib /home/adminuser/boost-1_50/gcc-4.4-arm /home/adminuser/ros_catkin_ws/ros_ext_deps/lib)
set(CMAKE_INCLUDE_PATH /home/adminuser/boost-1_50/includes usr/include /home/adminuser/ros_catkin_ws/ros_ext_deps/include)
set(BOOST_LIBRARYDIR /home/adminuser/boost-1_50/gcc-4.4-arm/)
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM BOTH)
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE BOTH)
set(BOOST_ROOT /home/adminuser/boost-1_50)
set(BOOST_INCLUDEDIR /home/adminuser/boost-1_50/includes)
set(Boost_REALPATH TRUE)
set(Boost_ADDITIONAL_VERSIONS "1.50" "1.50.0")
set(Boost_USE_STATIC_LIBS ON)
set(Boost_USE_STATIC_RUNTIME OFF)
set(Boost_COMPILER "-gcc44")
set(Boost_INCLUDE_DIR /home/adminuser/boost-1_50/includes)
set(Boost_LIBRARY_DIRS /home/adminuser/boost-1_50/gcc-4.4-arm/)
I'm running into problems with the compilation when it comes to rospack as follows.
-- Boost version: 1.50.0
-- Found the following Boost libraries:
-- filesystem
-- program_options
-- system
-- Found PythonLibs: /usr/lib/libpython2.7.so
-- Configuring done
-- Generating done
-- Build files have been written to: /home/adminuser/ros_catkin_ws/build_isolated/rospack
==> make -j1 -l1 in '/home/adminuser/ros_catkin_ws/build_isolated/rospack'
Scanning dependencies of target rospack
[ 16%] Building CXX object CMakeFiles/rospack.dir/src/rospack.cpp.o
cc1plus: warning: include location "/usr/include/python2.7" is unsafe for cross-compilation
/home/adminuser/ros_catkin_ws/src/rospack/src/rospack.cpp:30: fatal error: tinyxml.h: No such file or directory
compilation terminated.
make[2]: *** [CMakeFiles/rospack.dir/src/rospack.cpp.o] Error 1
make[1]: *** [CMakeFiles/rospack.dir/all] Error 2
make: *** [all] Error 2
Traceback (most recent call last):
File "./src/catkin/bin/../python/catkin/builder.py", line 717, in build_workspace_isolated
number=index + 1, of=len(ordered_packages)
File "./src/catkin/bin/../python/catkin/builder.py", line 497, in build_package
install, force_cmake, quiet, last_env, cmake_args, make_args + catkin_make_args
File "./src/catkin/bin/../python/catkin/builder.py", line 353, in build_catkin_package
run_command(make_cmd, build_dir, quiet)
File "./src/catkin/bin/../python/catkin/builder.py", line 198, in run_command
raise subprocess.CalledProcessError(proc.returncode, ' '.join(cmd))
CalledProcessError: Command '/home/adminuser/ros_catkin_ws/install_isolated/env.sh make -j1 -l1' returned non-zero exit status 2
<== Failed to process package 'rospack':
Command '/home/adminuser/ros_catkin_ws/install_isolated/env.sh make -j1 -l1' returned non-zero exit status 2
Reproduce this error by running:
==> /home/adminuser/ros_catkin_ws/install_isolated/env.sh make -j1 -l1**
Do I also need a ARM python library to link against?
I have read that tinyxml was included with the rospack src, but don't see it and the build process complains it can't find it. Do I need to download its src separately?
If the eventual goal is to compile something like the beginner_tutorials to my target do I need rospack? From rospack depends it appears even the simple ...