-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
145611a
commit 018044f
Showing
5 changed files
with
134 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Travis CI script | ||
language: c | ||
|
||
os: | ||
- linux | ||
|
||
sudo: false | ||
|
||
services: | ||
- docker | ||
|
||
env: | ||
- BUILD_TYPE=default | ||
#- BUILD_TYPE=android | ||
#- BUILD_TYPE=check-py | ||
#- BUILD_TYPE=cmake | ||
|
||
addons: | ||
apt: | ||
packages: | ||
- valgrind | ||
- git | ||
|
||
before_install: | ||
- if [ $TRAVIS_OS_NAME == "osx" ] ; then brew update; brew install binutils valgrind ; fi | ||
|
||
# Hand off to generated script for each BUILD_TYPE | ||
script: ./ci_build.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#!/usr/bin/env bash | ||
set -ex | ||
|
||
docker run -v "$REPO_DIR":/gsl zeromqorg/zproject project.xml | ||
|
||
# keep an eye on git version used by CI | ||
git --version | ||
if [[ $(git --no-pager diff -w) ]]; then | ||
git --no-pager diff -w | ||
echo "There are diffs between current code and code generated by zproject!" | ||
exit 1 | ||
fi | ||
if [[ $(git status -s) ]]; then | ||
git status -s | ||
echo "zproject generated new files!" | ||
exit 1 | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/usr/bin/env bash | ||
set -ex | ||
|
||
|
||
# keep an eye on git version used by CI | ||
git --version | ||
if [[ $(git --no-pager diff -w api/*) ]]; then | ||
git --no-pager diff -w api/* | ||
echo "There are diffs between current code and code generated by zproto!" | ||
exit 1 | ||
fi | ||
if [[ $(git status -s api) ]]; then | ||
git status -s api | ||
echo "zproto generated new files!" | ||
exit 1 | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
#!/usr/bin/env bash | ||
|
||
################################################################################ | ||
# THIS FILE IS 100% GENERATED BY ZPROJECT; DO NOT EDIT EXCEPT EXPERIMENTALLY # | ||
# PLEASE REFER TO THE README FOR INFORMATION ABOUT MAKING PERMANENT CHANGES. # | ||
################################################################################ | ||
|
||
set -x | ||
set -e | ||
|
||
if [ "$BUILD_TYPE" == "default" ]; then | ||
mkdir tmp | ||
BUILD_PREFIX=$PWD/tmp | ||
|
||
CONFIG_OPTS=() | ||
CONFIG_OPTS+=("CFLAGS=-I${BUILD_PREFIX}/include") | ||
CONFIG_OPTS+=("CPPFLAGS=-I${BUILD_PREFIX}/include") | ||
CONFIG_OPTS+=("CXXFLAGS=-I${BUILD_PREFIX}/include") | ||
CONFIG_OPTS+=("LDFLAGS=-L${BUILD_PREFIX}/lib") | ||
CONFIG_OPTS+=("PKG_CONFIG_PATH=${BUILD_PREFIX}/lib/pkgconfig") | ||
CONFIG_OPTS+=("--prefix=${BUILD_PREFIX}") | ||
CONFIG_OPTS+=("--with-docs=no") | ||
CONFIG_OPTS+=("--quiet") | ||
|
||
# Clone and build dependencies | ||
git clone --quiet --depth 1 https://github.com/zeromq/libzmq libzmq | ||
cd libzmq | ||
git --no-pager log --oneline -n1 | ||
if [ -e autogen.sh ]; then | ||
./autogen.sh 2> /dev/null | ||
fi | ||
if [ -e buildconf ]; then | ||
./buildconf 2> /dev/null | ||
fi | ||
./configure "${CONFIG_OPTS[@]}" | ||
make -j4 | ||
make install | ||
cd .. | ||
git clone --quiet --depth 1 https://github.com/zeromq/czmq czmq | ||
cd czmq | ||
git --no-pager log --oneline -n1 | ||
if [ -e autogen.sh ]; then | ||
./autogen.sh 2> /dev/null | ||
fi | ||
if [ -e buildconf ]; then | ||
./buildconf 2> /dev/null | ||
fi | ||
./configure "${CONFIG_OPTS[@]}" | ||
make -j4 | ||
make install | ||
cd .. | ||
|
||
# Build and check this project | ||
./autogen.sh 2> /dev/null | ||
./configure "${CONFIG_OPTS[@]}" | ||
make -j4 | ||
make check | ||
make memcheck | ||
make install | ||
|
||
# Build and check this project without DRAFT APIs | ||
make clean | ||
git reset --hard HEAD | ||
./autogen.sh 2> /dev/null | ||
./configure --enable-drafts=no "${CONFIG_OPTS[@]}" | ||
make -j4 | ||
make check | ||
make install | ||
else | ||
pushd "./builds/${BUILD_TYPE}" && REPO_DIR="$(dirs -l +1)" ./ci_build.sh | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters