Cross-compiling ROS application without Yocto?
I want to cross-compile ROS packages for BeagleBone Black running ubuntu 14.04. The BBB is running ROS indigo. I have been using meta-ros, which is a layer on top of Yocto (i.e. OpenEmbedded) build system, to cross-compile ROS stack and its dependencies. I followed diving-meta-ros as a road-map to write bitbake recipes for cross-compiling my own ROS packages, which I could successfully run on my target system (BBB).
The only problem in this workflow is the footprint Yocto leaves on the disk - the build directory in which Yocto saves the cross-compiled binaries, fetched archieves of sources and all the byproducts of cross-compilation, grows upto 25 GB with default configuration.
My questions are -
Is there any way that I can reduce the overall amount of disk space utilized by Yocto, so that the above method still works on systems which have lesser resources (primarily disk space)? I would like to have a solution which could take less than 10 GB disk space on the host system.
Is there any other way to cross compile ROS stack and ROS packages which doesn't need Yocto? I found out this answer which basically suggests to do all the things which Yocto and meta-ros do for us, and cross-compile the ROS applications against the cross-compiled libraries. I used some of the instructions which I describe in the next point.
I tried to use
-c populate_sdk
command thebitbake
provides us with, and cross-compiling the ROS packages against the populatedsysroots
with arm-toolchain. I usedcatkin_make
with my owntoolchain.cmake
file (which has all the information about my compilers, compiler flags and locations of cross-compiled libraries) to cross-compile ROS packages, but ran into some issues where catkin couldn't find the ROS packages (such as roscpp) and cross-compiled libraries (such as pthread). Has anyone tried to follow this method to cross-compile ROS packages, where you provide your own toolchain.cmake file to point to the cross-compiled libraries and binaries?
Any pointers regarding these three points (and in-general cross-compiling ROS packages) would be really helpful.
Thanks in advance.