From: Tobias Brunner Date: Wed, 8 Aug 2018 09:35:46 +0000 (+0200) Subject: travis: Add Botan build X-Git-Tag: 5.7.0rc1~4^2~12 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9ee23d5efa099e05f4f98d71e7fab677f08dd88c;p=thirdparty%2Fstrongswan.git travis: Add Botan build We build Botan directly from the master branch until 2.8.0 is released. --- diff --git a/.travis.yml b/.travis.yml index 8e36f4ebe9..d220950c71 100644 --- a/.travis.yml +++ b/.travis.yml @@ -38,6 +38,8 @@ env: - TEST=default - TEST=default MONOLITHIC=yes - TEST=default LEAK_DETECTIVE=yes + - TEST=botan + - TEST=botan LEAK_DETECTIVE=yes - TEST=openssl - TEST=openssl LEAK_DETECTIVE=yes - TEST=gcrypt diff --git a/scripts/test.sh b/scripts/test.sh index 58dc7307e4..a2ec74a4b9 100755 --- a/scripts/test.sh +++ b/scripts/test.sh @@ -26,6 +26,32 @@ gcrypt) CONFIG="--disable-defaults --enable-pki --enable-gcrypt --enable-pkcs1" DEPS="libgcrypt11-dev" ;; +botan) + CONFIG="--disable-defaults --enable-pki --enable-botan" + # we can't use the old package that comes with Ubuntu so we build from + # the current master until 2.8.0 is released and then probably switch to + # that unless we need newer features (at least 2.7.0 plus PKCS#1 patch is + # currently required) + DEPS="" + if test "$1" = "deps"; then + # if the leak detective is enabled we have to disable threading support + # (used for std::async) as that causes invalid frees somehow, the + # locking allocator causes a static leak via the first function that + # references it (e.g. crypter or hasher), so we disable that too + if test "$LEAK_DETECTIVE" = "yes"; then + BOTAN_CONFIG="--without-os-features=threads + --disable-modules=locking_allocator" + fi + # disable some larger modules we don't need for the tests + BOTAN_CONFIG="$BOTAN_CONFIG --disable-modules=pkcs11,tls,x509,xmss" + git clone --depth 1 https://github.com/randombit/botan.git botan && + cd botan && + python ./configure.py $BOTAN_CONFIG && + make -j4 libs >/dev/null && + sudo make install >/dev/null && + sudo ldconfig || exit $? + fi + ;; printf-builtin) CONFIG="--with-printf-hooks=builtin" ;; @@ -43,6 +69,8 @@ all|coverage|sonarcloud) CONFIG="$CONFIG --disable-nm" # not enabled on the build server CONFIG="$CONFIG --disable-af-alg" + # separate test case with external dependency + CONFIG="$CONFIG --disable-botan" if test "$TEST" != "coverage"; then CONFIG="$CONFIG --disable-coverage" else