-
Notifications
You must be signed in to change notification settings - Fork 85
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
Showing
1 changed file
with
66 additions
and
22 deletions.
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 |
---|---|---|
@@ -1,58 +1,102 @@ | ||
language: cpp | ||
env: | ||
global: | ||
- secure: dNf+ddgmbhuzrGHsO6eWuEQ9rTZbIQjdBX47TDnGulwWpOS8LyEoZNFz3IAvf9HJBY2L/pM3F6BvSfXpumX+qX2BVZLUETX54lk07i8PnGWgq0O0ylW5sB3xM0bNGPALiH3sBJEHeimEoRIAkbg+bXafLWo4cDFtQ7IT4mg6fQxq+MGNyr5GnSBkTRK7TdXef1dOylF0R2OV/xXVTr0xEkCb4ONB32ljZ1YZrYw0RzeDWX+rp674S1DnqhC3cYuOjK0Yl3h0uDHEI/rdvJmTahii9C5AILA8eB8Lc4jBlQmXlXYHy7Rr10KIwK7qYNFal6WyS4SbyBLZ6t3bNFrXe3ayMnhllVs0RsreMgMaJ78nGuHmpdQ8FJWlOIEWOYEFO6j/WnQwN7d6U4cgmB0mWmQJoO59qGuw1FsRTMssTJNeOd5t8WVi3AyNSV+GE4n+ZE1Bh4KIhmmhWno+w5iHKIHpr0SocxhPB5jQ2mEm1GhG8ZvM+wAollabkXCfeF9brGCh5IbTib10UpAkDkoeLYSpHO4Blshu5Tkpu0OXe1zcTwfUewbrZ1NZIS6LWdau6ISiPLQSnL+BwgZcIMJ/ZqUEmCtaBE79gQ/h730/Ekxkmdfr9KuvqnF+UTqXtRJeru/uZ0n2LTj7xrjpct2eFHZzGJlp2sAfQWfLK7EWg5A= | ||
|
||
matrix: | ||
include: | ||
- os: linux | ||
- language: cpp | ||
os: linux | ||
addons: | ||
apt: | ||
packages: | ||
- gfortran | ||
- liblapack-dev | ||
- os: linux | ||
|
||
- language: cpp | ||
os: linux | ||
dist: bionic | ||
addons: | ||
apt: | ||
packages: | ||
- gfortran | ||
- liblapack-dev | ||
- os: osx | ||
|
||
- language: cpp | ||
os: osx | ||
osx_image: xcode11 | ||
env: OSX=10.14 CC=gcc CXX=g++ | ||
compiler: clang | ||
- os: osx | ||
- language: cpp | ||
os: osx | ||
osx_image: xcode11 | ||
env: OSX=10.14 | ||
env: OSX=10.14 | ||
compiler: clang | ||
- os: osx | ||
- language: cpp | ||
os: osx | ||
osx_image: xcode10 | ||
env: OSX=10.13 | ||
env: OSX=10.13 | ||
compiler: clang | ||
|
||
- language: minimal | ||
dist: bionic | ||
env: DISTRO=alpine | ||
- language: minimal | ||
dist: bionic | ||
env: DISTRO=archlinux | ||
- language: minimal | ||
dist: bionic | ||
env: DISTRO=centos | ||
- language: minimal | ||
dist: bionic | ||
env: DISTRO=debian | ||
- language: minimal | ||
dist: bionic | ||
env: DISTRO=fedora | ||
- language: minimal | ||
dist: bionic | ||
env: DISTRO=opensuse | ||
- language: minimal | ||
dist: bionic | ||
env: DISTRO=ubuntu | ||
|
||
allow_failures: | ||
- language: cpp | ||
os: osx | ||
|
||
install: true | ||
|
||
before_script: | ||
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew update; fi | ||
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then if [ x`brew list | fgrep bash` != x'bash' ]; then brew install bash; fi; fi | ||
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then if [ x`brew list | fgrep gcc` != x'gcc' ]; then brew install gcc; fi; fi | ||
- if [[ "$TRAVIS_OS_NAME $CC" == "osx gcc" ]]; then export CC=gcc-9 ; export CXX=g++-9 ; $CC --version; $CXX --version; gfortran --version; fi | ||
- if [[ "$TRAVIS_OS_NAME $CC" == "osx clang" ]]; then export PLATFORM=osx$OSX-x86_64-clang`clang -dumpversion`; fi | ||
- if [[ "$TRAVIS_OS_NAME $CC" == "osx gcc-9" ]]; then export PLATFORM=osx$OSX-x86_64-gcc`gcc-9 -dumpversion`; fi | ||
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then export PLATFORM=linux-x86_64-gcc`gcc -dumpversion`; fi | ||
- cd .. | ||
- wget https://raw.githubusercontent.com/coin-or/coinbrew/master/coinbrew | ||
- export PROJECT_URL=https://github.com/$TRAVIS_REPO_SLUG | ||
- export PROJECT=`echo $TRAVIS_REPO_SLUG | cut -d "/" -f 2` | ||
- bash ./coinbrew fetch $PROJECT_URL:$TRAVIS_BRANCH --no-prompt --skip-update | ||
- if [[ "$TRAVIS_OS_NAME" == "linux" ]] && [[ -z "$DISTRO" ]]; then export PLATFORM=linux-x86_64-gcc`gcc -dumpversion`; fi | ||
- if [[ -z "$DISTRO" ]]; then cd ..; fi | ||
- if [[ -z "$DISTRO" ]]; then wget https://raw.githubusercontent.com/coin-or/coinbrew/master/coinbrew; fi | ||
- if [[ -z "$DISTRO" ]]; then export PROJECT_URL=https://github.com/$TRAVIS_REPO_SLUG; fi | ||
- if [[ -z "$DISTRO" ]]; then export PROJECT=`echo $TRAVIS_REPO_SLUG | cut -d "/" -f 2`; fi | ||
- if [[ -z "$DISTRO" ]]; then bash ./coinbrew fetch $PROJECT_URL:$TRAVIS_BRANCH --no-prompt --skip-update; fi | ||
|
||
script: | ||
- bash ./coinbrew build $PROJECT --no-prompt --verbosity 2 --test --enable-relocatable | ||
- if [[ -z "$DISTRO" ]]; then bash ./coinbrew build $PROJECT --no-prompt --verbosity 2 --test --enable-relocatable; fi | ||
|
||
- > | ||
if [[ ! -z "$DISTRO" ]]; then ( | ||
cd .ci && | ||
make env_${DISTRO} && | ||
make devel_${DISTRO} && | ||
make test_${DISTRO} && | ||
make install_${DISTRO} && | ||
make test_install_${DISTRO} || | ||
travis_terminate 1 ); fi | ||
after_script: | ||
- if [ $TRAVIS_BRANCH = "master" ]; then export VERSION=master; else export VERSION=`echo $TRAVIS_BRANCH | cut -d "/" -f 2`; fi | ||
- export TGZ_FILE=$PROJECT-$VERSION-$PLATFORM.tgz | ||
- echo $TGZ_FILE | ||
- cp README.md LICENSE dist | ||
- cd dist | ||
- tar -czvf $TGZ_FILE lib/* bin/* include/* share/* README.md LICENSE | ||
- curl -T $TGZ_FILE -utkralphs:$BINTRAY_API -H "X-Bintray-Publish:1" -H "X-Bintray-Override:1" https://api.bintray.com/content/coin-or/download/$PROJECT/$VERSION/$TGZ_FILE | ||
- if [ $TRAVIS_BRANCH = "master" ] && [[ -z "$DISTRO" ]]; then export VERSION=master; else export VERSION=`echo $TRAVIS_BRANCH | cut -d "/" -f 2`; fi | ||
- if [[ -z "$DISTRO" ]]; then export TGZ_FILE=$PROJECT-$VERSION-$PLATFORM.tgz; fi | ||
- if [[ -z "$DISTRO" ]]; then echo $TGZ_FILE; fi | ||
- if [[ -z "$DISTRO" ]]; then cp README.md LICENSE dist; fi | ||
- if [[ -z "$DISTRO" ]]; then cd dist; fi | ||
- if [[ -z "$DISTRO" ]]; then tar -czvf $TGZ_FILE lib/* bin/* include/* share/* README.md LICENSE; fi | ||
- if [[ -z "$DISTRO" ]]; then curl -T $TGZ_FILE -utkralphs:$BINTRAY_API -H "X-Bintray-Publish:1" -H "X-Bintray-Override:1" https://api.bintray.com/content/coin-or/download/$PROJECT/$VERSION/$TGZ_FILE; fi |