X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=cross-compile%2Flinux%2Fsigrok-cross-linux;h=a01173ab7c37aa97f8073ecae9f88c33cbaa2a03;hb=ab2ccf3daeb8ede4f22f25a95a0cb6475e278066;hp=8dd770d9ef921a12eed0418f6dace9aa4e108b71;hpb=7facd6cf6456b9f684415502a62db036fdfcdcd8;p=sigrok-util.git diff --git a/cross-compile/linux/sigrok-cross-linux b/cross-compile/linux/sigrok-cross-linux index 8dd770d..a01173a 100755 --- a/cross-compile/linux/sigrok-cross-linux +++ b/cross-compile/linux/sigrok-cross-linux @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/sh ## ## This file is part of the sigrok-util project. ## @@ -39,6 +39,11 @@ PYPATH=$PREFIX/lib/python2.7/site-packages # Edit this to enable/disable/modify parallel compiles. PARALLEL="-j 2" +# Uncomment the following lines to build with clang and run scan-build. +# export CC=clang +# export CXX=clang++ +# SB="scan-build -k -v" + # You usually don't need to change anything below this line. # ----------------------------------------------------------------------------- @@ -62,7 +67,7 @@ cd libserialport mkdir build cd build ../configure $C -make $PARALLEL +$SB make $PARALLEL make install cd ../.. @@ -74,9 +79,9 @@ cd libsigrok mkdir build cd build PKG_CONFIG_PATH=$P ../configure $C -make $PARALLEL -PYTHONPATH=$PYPATH make install -make check +$SB make $PARALLEL +PYTHONPATH=$PYPATH $SB make install +$SB make check cd ../.. # libsigrokdecode @@ -86,9 +91,9 @@ cd libsigrokdecode mkdir build cd build PKG_CONFIG_PATH=$P ../configure $C -make $PARALLEL +$SB make $PARALLEL make install -make check +$SB make check cd ../.. # sigrok-firmware @@ -121,7 +126,7 @@ cd sigrok-cli mkdir build cd build PKG_CONFIG_PATH=$P ../configure $C -make $PARALLEL +$SB make $PARALLEL make install cd ../.. @@ -130,8 +135,9 @@ $GIT_CLONE git://sigrok.org/pulseview cd pulseview mkdir build cd build -PKG_CONFIG_PATH=$P cmake -DCMAKE_INSTALL_PREFIX:PATH=$PREFIX -DDISABLE_WERROR=y -DENABLE_TESTS=y .. -make $PARALLEL +PKG_CONFIG_PATH=$P $SB cmake -DCMAKE_INSTALL_PREFIX:PATH=$PREFIX -DDISABLE_WERROR=y -DENABLE_TESTS=y .. +$SB make $PARALLEL make install +$SB make test cd ../..