From 7e48276050cab98999be6ac07d4076d500900e23 Mon Sep 17 00:00:00 2001 From: Kei Okada Date: Tue, 6 Jan 2015 12:49:38 +0900 Subject: [PATCH] add ROS_PARALLEL_JOBS to -j2 --- .travis.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index e595b9b5..e30bbd68 100644 --- a/.travis.yml +++ b/.travis.yml @@ -33,6 +33,7 @@ before_install: # Use this to prepare the system to install prerequisites or dep # Define some config vars - export CI_SOURCE_PATH=$(pwd) - export REPOSITORY_NAME=${PWD##*/} + - export ROS_PARALLEL_JOBS="-j2 -l2" - echo "Testing branch $TRAVIS_BRANCH of $REPOSITORY_NAME" - sudo sh -c 'echo "deb http://packages.ros.org/ros-shadow-fixed/ubuntu precise main" > /etc/apt/sources.list.d/ros-latest.list' - wget http://packages.ros.org/ros.key -O - | sudo apt-key add - @@ -81,13 +82,13 @@ before_script: # Use this to prepare your build for testing e.g. copy database c - if [ $BUILDER == rosbuild ]; then rospack profile ; fi script: # All commands must exit with code 0 on success. Anything else is considered failure. # for catkin - - if [ $BUILDER == catkin ]; then catkin_make -j8 -l8 ; fi + - if [ $BUILDER == catkin ]; then catkin_make ${ROS_PARALLEL_JOBS} ; fi - if [ $BUILDER == catkin ]; then export TARGET_PKG=`find build/$REPOSITORY_NAME -name Makefile -print | sed s@.*/\\\\\([^\/]*\\\\\)/Makefile@\\\1@g` ; fi # - if [ $BUILDER == catkin ]; then source devel/setup.sh; export EXIT_STATUS=0; for pkg in $TARGET_PKG; do (roscd $pkg; [ "`find . -iname '*.test'`" == "" ] && echo "[$pkg] No tests ware found!!!" || find . -iname "*.test" -print0 | xargs -0 -n1 rostest || export EXIT_STATUS=$?;) done; [ $EXIT_STATUS == 0 ] ; fi - export EXIT_STATUS=$? - - if [ $BUILDER == catkin ]; then catkin_make test --pkg $TARGET_PKG -j8 -l8 ; export EXIT_STATUS=$?; fi + - if [ $BUILDER == catkin ]; then catkin_make test --pkg $TARGET_PKG ${ROS_PARALLEL_JOBS} ; export EXIT_STATUS=$?; fi - if [ $EXIT_STATUS != 0 -a $BUILDER == catkin ]; then find build -name LastTest.log -exec echo "==== {} ====" \; -exec cat {} \; ; fi - - if [ $BUILDER == catkin ]; then catkin_make -j8 -l8 install ; fi + - if [ $BUILDER == catkin ]; then catkin_make ${ROS_PARALLEL_JOBS} install ; fi - if [ $BUILDER == catkin ]; then rm -fr devel src build ; fi - if [ $BUILDER == catkin ]; then source install/setup.bash ; fi - if [ $BUILDER == catkin ]; then export EXIT_STATUS=0; for pkg in $TARGET_PKG; do [ "`find install/share/$pkg -iname '*.test'`" == "" ] && echo "[$pkg] No tests ware found!!!" || find install/share/$pkg -iname "*.test" -print0 | xargs -0 -n1 rostest || export EXIT_STATUS=$?; done; [ $EXIT_STATUS == 0 ] ; fi