Skip to content

Commit

Permalink
Problem: no CI for cppzmq
Browse files Browse the repository at this point in the history
Solution: add travis-ci
  • Loading branch information
sigiesec committed Mar 28, 2018
1 parent 52c606e commit 702d2fc
Show file tree
Hide file tree
Showing 2 changed files with 72 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Travis CI script

language: c

os:
- linux
#- osx

dist: trusty

cache: ccache

env:
matrix:
# - BUILD_TYPE=cmake DRAFT=enabled
- BUILD_TYPE=cmake

matrix:
include:
# - env: BUILD_TYPE=cmake DO_CLANG_FORMAT_CHECK=1 CLANG_FORMAT=/usr/local/clang-5.0.0/bin/clang-format
# os: linux
# addons:
# apt:
# sources:
# - llvm-toolchain-trusty-5.0
# packages:
# - clang-5.0

sudo: required

# Build and check this project according to the BUILD_TYPE
script:
- chmod +x ci_build.sh
- ./ci_build.sh
38 changes: 38 additions & 0 deletions ci_build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
#!/usr/bin/env bash

set -x

install_zeromq() {
pushd .

mkdir libzmq
cd libzmq
curl -L https://github.com/zeromq/libzmq/releases/download/v${ZMQ_VERSION}/zeromq-${ZMQ_VERSION}.tar.gz >zeromq.tar.gz
tar -xvzf zeromq.tar.gz
cd zeromq-${ZMQ_VERSION}

mkdir build
cd build
cmake ..
sudo make -j4 install

popd
}

# build zeromq first

if [ "${ZMQ_VERSION}" != "" ] ; then install_zeromq ; fi

# build cppzmq

mkdir build
cd build
cmake ..
sudo make -j4 install

# build cppzmq tests
# cd tests
# mkdir build
# cd build
# cmake ..
# make -j5 test ARGS="-V"

0 comments on commit 702d2fc

Please sign in to comment.