From: Willem Toorop Date: Fri, 6 Sep 2013 12:40:51 +0000 (+0200) Subject: Anticipate binapi updates with CI tests X-Git-Tag: release-1.6.17rc1~42 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3a6a9cb4df8be849b0f23001a793c57512d3a1dc;p=thirdparty%2Fldns.git Anticipate binapi updates with CI tests And also make test_ci.sh pass on linux machines (if all is well). --- diff --git a/packaging/ldns-config.1 b/packaging/ldns-config.1 index c5a00a1e..72afc189 100644 --- a/packaging/ldns-config.1 +++ b/packaging/ldns-config.1 @@ -24,7 +24,11 @@ Show the flags to be used to link with ldns .TP \fB--version\fR -Shows the version of the installed ldns library +Shows the ldns version of the installed ldns library + +.TP +\fB--libversion\fR +Shows version of the binary api of the installed ldns library .TP \fB--help\fR diff --git a/packaging/ldns-config.in b/packaging/ldns-config.in index b728ba54..d2cf4d43 100755 --- a/packaging/ldns-config.in +++ b/packaging/ldns-config.in @@ -9,6 +9,7 @@ LDFLAGS="@LDFLAGS@ @LIBSSL_LDFLAGS@ @PYTHON_LDFLAGS@" LIBS="@LIBS@ @LIBSSL_LIBS@" LIBDIR="@libdir@" INCLUDEDIR="@includedir@" +LIBVERSION="@LIBLDNS_CURRENT@.@LIBLDNS_REVISION@.@LIBLDNS_AGE@" for arg in $@ do @@ -28,4 +29,8 @@ do then echo "${VERSION}" fi + if [ $arg = "--libversion" ] + then + echo "${LIBVERSION}" + fi done diff --git a/test/33-test-unbound-latest.tpkg b/test/33-test-unbound-latest.tpkg index 393f6a24..ec7edd9f 100644 Binary files a/test/33-test-unbound-latest.tpkg and b/test/33-test-unbound-latest.tpkg differ diff --git a/test/test_ci.sh b/test/test_ci.sh index b1402b5e..48211f7d 100755 --- a/test/test_ci.sh +++ b/test/test_ci.sh @@ -28,23 +28,45 @@ then exit -1 fi fi - +if [ "x`uname -o`" = "xGNU/Linux" ] +then + ON_LINUX=1 +else + ON_LINUX=0 +fi +chmod +x $BUILD_DIR/packaging/ldns-config +BINAPI=`$BUILD_DIR/packaging/ldns-config --libversion` +BINAPI=${BINAPI#*.} +if [ "x$BINAPI" = "x0.0" ] +then + BINAPI_CHANGED=1 +else + BINAPI_CHANGED=0 +fi # RUN THE TESTS for tests in $BUILD_DIR/test/*.tpkg do TESTFN=`basename $tests` TESTNR=`echo $TESTFN | sed 's/-.*$//g'` - if [ ! -z "$ONLY_TEST" ] + if [ ! -z "$ONLY_TEST" -a x$ONLY_TEST != x$TESTNR ] then - if [ x$ONLY_TEST != x$TESTNR ] + continue + + elif [ x$TESTNR != x$TESTFN ] # cause codingstyle.tpkg has no number + then + if [ $NO_REGRESSION = 1 -a $TESTNR -ge 30 ] then continue + + elif [ $ON_LINUX = 1 -a $TESTNR -eq 2 ] + then + continue # splint doesn't work on linux + + elif [ $BINAPI_CHANGED = 1 -a $TESTNR -eq 32 ] + then + continue # Unbound regression testing not possible fi fi - if [ $NO_REGRESSION = 1 -a $TESTNR -ge 30 ] - then - continue - fi $TPKG -b $BUILD_DIR/test -a $BUILD_DIR exe $TESTFN done