]> git.ipfire.org Git - thirdparty/gnutls.git/commitdiff
.gitlab-ci.yml: updated x86 CI builds with better datefudge detection
authorNikos Mavrogiannopoulos <nmav@gnutls.org>
Sun, 24 Jun 2018 04:51:14 +0000 (06:51 +0200)
committerNikos Mavrogiannopoulos <nmav@gnutls.org>
Sun, 24 Jun 2018 05:57:31 +0000 (07:57 +0200)
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
.gitlab-ci.yml
tests/cert-tests/pkcs1-pad
tests/scripts/common.sh
tests/suite/testcompat-openssl.sh
tests/suite/testcompat-polarssl.sh
tests/suite/testcompat-tls13-openssl.sh

index d1c875e4209a08460701e30b3837e55731d14489..a24104e1cc9cc730e40cd54bd0f8271c5f98bab8 100644 (file)
@@ -403,17 +403,14 @@ FreeBSD.x86_64:
       - tests/*.log
       - tests/*/*.log
 
-# We need a clean 32-bit fedora for testing. Note that this is also
-# a test for interoperability with openssl 1.0.x.
 Fedora.x86:
   stage: stage1-testing
   image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$FEDORA_X86_BUILD
   script:
-  - git submodule update --init --no-fetch
   - ./bootstrap && mkdir -p build && cd build &&
     CC="ccache gcc -m32" PKG_CONFIG_LIBDIR=/usr/lib/pkgconfig/ ../configure --disable-gcc-warnings --host=i686-redhat-linux --target=i686-redhat-linux
      --libdir=/usr/lib --disable-cxx --disable-non-suiteb-curves --enable-seccomp-tests --disable-full-test-suite --disable-doc --disable-guile &&
-    make -j$(nproc) && make check -j$(nproc) &&
+    make -j$(nproc) && make check -j$(nproc) SKIP_DATEFUDGE_CHECK=1 &&
     make pic-check
   tags:
   - shared
index 7c0723ee64605a7dbf76c67da4bc8f9a18fd91f5..a314fb308de8073ce8ef1b97b1b4aacb83e6bde1 100755 (executable)
@@ -32,12 +32,9 @@ fi
 
 export TZ="UTC"
 
-# Check for datefudge
-TSTAMP=`datefudge "2006-09-23" date -u +%s || true`
-if test "${TSTAMP}" != "1158969600"; then
-       echo "You need datefudge to run this test"
-       exit 77
-fi
+. ${srcdir}/../scripts/common.sh
+
+check_for_datefudge
 
 TMPFILE1=pkcs1-pad.$$.tmp
 TMPFILE2=pkcs1-pad-2.$$.tmp
index 8662d93cf1709b3bae1086b013348f98aaa51de8..35ac52e5a6e110139e9cf895abcaf6d1b891d45d 100644 (file)
@@ -67,6 +67,12 @@ GETPORT='rc=0; myrandom=$(date +%N | sed s/^0*//)
 '
 
 check_for_datefudge() {
+       # On certain platforms running datefudge date fails (e.g., x86 datefudge
+       # with x86-64 date app).
+       if test ${SKIP_DATEFUDGE_CHECK} = 1;then
+               return
+       fi
+
        TSTAMP=`datefudge -s "2006-09-23" date -u +%s || true`
        if test "$TSTAMP" != "1158969600" || test "$WINDOWS" = 1; then
        echo $TSTAMP
index 216047087d9d0f8faba8aa20b92033a230e59686..bfc59c09ac306a1485104849b0788a03b2cf8918 100755 (executable)
@@ -52,11 +52,9 @@ fi
 export TZ="UTC"
 
 # Check for datefudge
-TSTAMP=`datefudge "2006-09-23 00:00 UTC" date -u +%s 2>/dev/null`
-if test "${TSTAMP}" != "1158969600"; then
-       echo "You need datefudge to run this test"
-       exit 77
-fi
+. "${srcdir}/../scripts/common.sh"
+
+check_for_datefudge
 
 timeout 1800 datefudge "2012-09-2" "${srcdir}/testcompat-main-openssl"
 
index 4c7a493d17039506dc10b3e1f743cdd7ea113b54..1af0099dca64bcc2f82824b17a4fba6df9a5d094 100755 (executable)
@@ -40,11 +40,9 @@ if test "${GNUTLS_FORCE_FIPS_MODE}" = 1;then
 fi
 
 # Check for datefudge
-TSTAMP=`datefudge "2006-09-23 00:00 UTC" date -u +%s 2>/dev/null`
-if test "${TSTAMP}" != "1158969600"; then
-       echo "You need datefudge to run this test"
-       exit 77
-fi
+. "${srcdir}/../scripts/common.sh"
+
+check_for_datefudge
 
 cat /proc/cpuinfo|grep "model name"|grep "VIA Esther" >/dev/null 2>&1
 if test $? = 0; then
index 4058da8f6afcf2bea0c0c023514b9692a74ad06e..e7a58f560a67859dd20651c94d7e63723ee38eba 100755 (executable)
@@ -39,13 +39,6 @@ if ! test -x "${CLI}"; then
        exit 77
 fi
 
-# Check for datefudge
-TSTAMP=`datefudge "2006-09-23 00:00 UTC" date -u +%s 2>/dev/null`
-if test "${TSTAMP}" != "1158969600"; then
-       echo "You need datefudge to run this test"
-       exit 77
-fi
-
 if ! test -z "${VALGRIND}"; then
        VALGRIND="${LIBTOOL:-libtool} --mode=execute ${VALGRIND}"
 fi
@@ -56,6 +49,8 @@ fi
 
 . "${srcdir}/../scripts/common.sh"
 
+check_for_datefudge
+
 . "${srcdir}/testcompat-common"
 
 PORT="${PORT:-${RPORT}}"