lorikeet-heimdal: add scipts to rebase and import the latest version into samba4
[metze/heimdal/wip.git] / .travis.yml
index f9940b99d639ed2a27122b506159e4a67c058ccc..78bb4caea19dd43421ec1a62d969b8714926defa 100644 (file)
@@ -10,38 +10,65 @@ env:
 
 before_install:
     - if [ $TRAVIS_OS_NAME = linux ]; then sudo apt-get update -qq; fi
-    - if [ $TRAVIS_OS_NAME = linux ]; then sudo apt-get install -qq bison comerr-dev flex libcap-ng-dev libdb-dev libedit-dev libjson-perl libldap2-dev libncurses5-dev libperl4-corelibs-perl libsqlite3-dev pkg-config python ss-dev texinfo unzip netbase; fi
+    - if [ $TRAVIS_OS_NAME = linux ]; then sudo apt-get install -qq bison comerr-dev flex libcap-ng-dev libdb-dev libedit-dev libjson-perl libldap2-dev libncurses5-dev libperl4-corelibs-perl libsqlite3-dev libkeyutils-dev pkg-config python ss-dev texinfo unzip netbase keyutils; fi
+    - if [ $TRAVIS_OS_NAME = linux ]; then sudo apt-get install -qq ldap-utils gdb; fi
+    - if [ $TRAVIS_OS_NAME = linux ]; then sudo apt-get install -qq libmicrohttpd-dev; fi
+    - if [ $TRAVIS_OS_NAME = linux -a -n "$COVERAGE" ]; then sudo apt-get install -qq jq; fi
     - if [ $TRAVIS_OS_NAME = osx ]; then brew update; fi
-    - if [ $TRAVIS_OS_NAME = osx ]; then brew install cpanm bison flex berkeley-db openssl; fi
+    - if [ $TRAVIS_OS_NAME = osx ]; then brew install cpanm bison flex berkeley-db lmdb openldap openssl; fi
     - if [ $TRAVIS_OS_NAME = osx ]; then sudo cpanm install JSON; fi
+    - if [ $TRAVIS_OS_NAME = osx -a -n "$COVERAGE" ]; then brew install jq; fi
     - mkdir ci-build
     - mkdir coverity-build
     - ./autogen.sh
 
 install:
     - cd ci-build
-    - if [ -n "$COVERAGE" ]; then pip install --user cpp-coveralls; fi
-    - ../configure --enable-maintainer-mode $COVERAGE
-    - make -j3
+    - |
+      if [ $TRAVIS_OS_NAME = osx ]; then
+          LDFLAGS="-L/usr/local/opt/berkeley-db/lib -L/usr/local/opt/lmdb/lib" \
+          CFLAGS="-I/usr/local/opt/lmdb/include" \
+          ../configure \
+                  --srcdir=`dirname "$PWD"` \
+                  --prefix=/tmp/heimdal \
+                  --enable-maintainer-mode $COVERAGE \
+                  --enable-static=no \
+                  --enable-pthread-support \
+                  --disable-afs-support \
+                  --disable-ndbm-db \
+                  --with-openldap=/usr/local/opt/openldap \
+                  --with-openssl=/usr/local/opt/openssl/ \
+                  --with-hcrypto-default-backend=ossl \
+                  --with-berkeley-db \
+                  --with-berkeley-db-include=/usr/local/opt/berkeley-db/include
+      else
+          ../configure --srcdir=`dirname "$PWD"` --enable-maintainer-mode $COVERAGE
+      fi
+    - ulimit -c unlimited; make -j3
 
 script:
-    - if [ x${COVERITY_SCAN_BRANCH} != x1 ]; then make check; fi
+    - if [ x${COVERITY_SCAN_BRANCH} != x1 ]; then ulimit -c unlimited; make check${MAKE_CHECK_SUFFIX}; fi
 
-compiler: clang
 after_script:
-    - if [ -n "$COVERAGE" ]; then coveralls --gcov-options; fi
+    - if [ -n "$COVERAGE" ]; then ../tools/coveralls-tool -O $PWD -S ..; fi
+    - find . -name \*.log -print0|xargs -0 grep '^==[1-9]'
+
+after_failure:
+    - find . -name test-suite.log -print0 | xargs -0 cat
+    - if [ $TRAVIS_OS_NAME = linux ]; then echo "thread apply all bt" > x; find . -name core.\* -print | while read gdb; do gdb -batch -x x `file "$core"|sed -e "s/^[^']*'//" -e "s/[ '].*$//"` "$core"; done; fi
+
+compiler:
+    - clang
+    - gcc
 
 matrix:
-    # Add a gcov build
     include:
-        - compiler: gcc
-          env: COVERAGE="--enable-gcov"
-          os: linux
-    # The gcov build is not working quite yet
-    allow_failures:
+      - os: linux
+        compiler: gcc
+        env: COVERAGE=--enable-gcov
+    exclude:
+      - os: osx
         compiler: gcc
-        env: COVERAGE="--enable-gcov"
-        os: linux
 
 notifications:
     email: