.travis.yml 1.97 KB
Newer Older
1
# Travis CI script
2

3
language: c
4

5 6 7 8
os:
- linux
- osx

9 10
dist: trusty

11
env:
12
- BUILD_TYPE=default CURVE=tweetnacl DRAFT=enabled
13 14
- BUILD_TYPE=android CURVE=tweetnacl
- BUILD_TYPE=cmake CURVE=tweetnacl
15
- BUILD_TYPE=default CURVE=libsodium
16
- BUILD_TYPE=default
17 18
- BUILD_TYPE=coverage CURVE=tweetnacl DRAFT=enabled
- BUILD_TYPE=valgrind CURVE=tweetnacl DRAFT=enabled
19 20 21

matrix:
  exclude:
22 23 24 25
  - env: BUILD_TYPE=coverage CURVE=tweetnacl DRAFT=enabled
    os: osx
  - env: BUILD_TYPE=valgrind CURVE=tweetnacl DRAFT=enabled
    os: osx
26
  include:
27 28 29 30
  - env: BUILD_TYPE=default CURVE=tweetnacl IPv6=ON
    os: linux
    dist: precise
    sudo: false
31

32
sudo: required
33

34 35 36 37
addons:
  apt:
    packages:
    - cmake
38
    - lcov
39
    - valgrind
40

41 42
before_install:
- if [ $TRAVIS_OS_NAME == "osx" ] ; then brew update; brew install binutils ; fi
43 44
# workaround for Travis OSX CI bug, hasn't been fixed in a month so time for a hack
- if [ $TRAVIS_OS_NAME == "osx" ] ; then brew uninstall libtool && brew install libtool ; fi
45

46 47 48 49
before_script:
# ZMQ stress tests need more open socket (files) than the usual default
# On OSX, it seems the way to set the max files limit is constantly changing, so
# try to use all known knobs to ensure compatibility across various versions
50
- if [ $TRAVIS_OS_NAME == "osx" ] ; then sudo sysctl -w kern.maxfiles=64000 ; sudo sysctl -w kern.maxfilesperproc=64000 ; sudo launchctl limit maxfiles 64000 64000 ; ulimit -n 64000; fi
51

52
# Build and check this project according to the BUILD_TYPE
53
script: ./ci_build.sh
54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69

# Deploy tags
before_deploy:
- . ./ci_deploy.sh
deploy:
  provider: releases
  api_key:
    secure: vGB5E+A8wxm2J1GJZzmIgT9PrjEzvd9gE8iui8FyxSbxAsW9vFZFGZC/21sTtpVcmRarwQCHH1UEbtg+nJwN2iD9YzMRnSVks8xqP+b709YW+VXaMuhZgTzWa74IorQku7NuvLibvQk72/OSgdwPGaNJ6f5AX9pnWVWbEoW1svE=
  file_glob: true
  file: ${LIBZMQ_DEPLOYMENT}
  skip_cleanup: true
  on:
    repo: zeromq/libzmq
    branch: master
    tags: true
    condition: "$TRAVIS_OS_NAME =~ (linux) && $BUILD_TYPE =~ (default) && $CURVE =~ (libsodium) && -z $DRAFT"