Skip to content

Commit

Permalink
travis: remove rebuild twice for MEMDBG test
Browse files Browse the repository at this point in the history
  • Loading branch information
linuxmaniac committed Jun 3, 2016
1 parent 2115943 commit eb0d271
Showing 1 changed file with 17 additions and 16 deletions.
33 changes: 17 additions & 16 deletions test/travis/build_travis.sh
Expand Up @@ -17,13 +17,26 @@ else
rm -rf /code/debian
ln -s /code/pkg/kamailio/deb/"${DIST}" /code/debian
fi
function build {

function _clean {
echo "make clean"
make -f debian/rules clean
}

function _build {
echo "make build"
make -f debian/rules build
}

function _install {
if [[ "$CC" =~ gcc ]] ; then
echo "make install"
make install
else
echo "skip make install step"
fi
}

if [[ "${CC}" =~ clang ]] ; then
CLANG=$(find /usr/bin -type l -name 'clang-[0-9]*' | sort -r | head -1)
echo "setting clang to ${CLANG}"
Expand All @@ -33,18 +46,6 @@ fi
echo "environment DIST=$DIST CC=$CC"
${CC} --version

# build flags
export MEMDBG=0
echo "build with MEMDBG=0"
build

export MEMDBG=1
echo "build with MEMDBG=1"
build

if [[ "$CC" =~ gcc ]] ; then
echo "make install"
make install
else
echo "skip make install step"
fi
_clean
_build
_install

0 comments on commit eb0d271

Please sign in to comment.