Skip to content

Commit

Permalink
Merge pull request trinityrnaseq#623 from junaruga/feature/devel-merg…
Browse files Browse the repository at this point in the history
…e-travis.yml

Merge files from master branch.
  • Loading branch information
brianjohnhaas authored Dec 18, 2018
2 parents 9a7b92b + 368ef13 commit c51b38e
Show file tree
Hide file tree
Showing 5 changed files with 73 additions and 25 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
*.o
*.pyc
*.swp
*~
/Chrysalis/bin
Expand Down
89 changes: 68 additions & 21 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ sudo: false
git:
depth: 1
language: generic
# Custom definitions
.conditions:
if: &secondary type = cron OR env(SECONDARY) = true
matrix:
include:
# http://www.cpan.org/src/
Expand All @@ -11,32 +14,57 @@ matrix:
- language: perl
perl: "5.26-shrplib"
env: CC=gcc-8 CXX=g++-8
# https://docs.travis-ci.com/user/languages/cpp/
- language: cpp
compiler: clang
# https://docs.travis-ci.com/user/languages/java/
- language: java
jdk: oraclejdk9
env: CC=gcc-6 CXX=g++-6
# https://docs.travis-ci.com/user/languages/python/
- language: python
python: "3.6"
- language: generic
env: CC=clang-3.9 CXX=clang++-3.9 LDFLAGS="-fopenmp=libiomp5"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- llvm-toolchain-precise-3.9
packages:
- clang-3.9
if: *secondary
- language: generic
# Open MP support is available from clang-3.7.
env: CC=clang-3.7 CXX=clang++-3.7 LDFLAGS="-fopenmp=libiomp5"
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- llvm-toolchain-precise-3.7
packages:
- clang-3.7
if: *secondary
# Test old version of the dependency packages.
- language: perl
perl: "5.18-shrplib"
env: BOWTIE2_VERSION=2.2.6
if: *secondary
# https://docs.travis-ci.com/user/reference/osx
- os: osx
language: cpp
# Do not have to set "compiler: gcc" as it is actually clang on osx.
compiler: clang
- os: osx
osx_image: xcode9.4
env: CC=gcc-8 CXX=g++-8
- os: osx
osx_image: xcode9.4
# "clang++" installed by [email protected] instead of "clang++-3.9".
env: CC=clang-3.9 CXX=clang++
if: *secondary
- os: osx
osx_image: xcode9.4
env: CC=clang-3.7 CXX=clang++-3.7
if: *secondary
allow_failures:
- language: cpp
compiler: clang
- env: BOWTIE2_VERSION=2.2.6
- env: CC=clang-3.7 CXX=clang++-3.7 LDFLAGS="-fopenmp=libiomp5"
- os: osx
env: CC=clang-3.7 CXX=clang++-3.7
fast_finish: true
install:
- |
Expand All @@ -56,21 +84,33 @@ install:
echo "Installing ${CXX}."
sudo apt-get install -qq "${CXX}"
fi
if [[ "${CC}" =~ clang- ]]; then
echo "Installing ${CC}."
sudo apt-get install -qq "${CC}" libiomp-dev
fi
else
# osx
export HOMEBREW_NO_AUTO_UPDATE=1
if [[ "${CC}" =~ gcc- ]]; then
# Update command line tool to avoid an error:
# "_stdio.h: No such file or directory", when building samtools.
softwareupdate --list
softwareupdate --install "Command Line Tools (macOS High Sierra version 10.13) for Xcode-9.4"
softwareupdate --install "Command Line Tools (macOS High Sierra version 10.13) for Xcode-10.1"
# Uninstall oclint to install gcc on OSX.
# https://github.com/travis-ci/travis-ci/issues/8826
brew cask uninstall oclint
CC_PKG="$(echo "${CC}" | sed -e 's/-/@/')"
echo "Installing ${CC_PKG}."
brew install "${CC_PKG}"
fi
if [[ "${CC}" =~ clang- ]]; then
echo "Installing ${CC}."
CC_VERSION=$(echo "${CC}" | sed -e 's/^clang-//')
brew install "llvm@${CC_VERSION}"
brew install libomp
CC_PREFIX=$(brew --prefix "llvm@${CC_VERSION}")
export PATH="${CC_PREFIX}/bin:$PATH"
export LDFLAGS="-L${CC_PREFIX}/lib -Wl,-rpath,${CC_PREFIX}/lib"
export CPPFLAGS="-I${CC_PREFIX}/include"
fi
fi
- pushd "${HOME}"
Expand All @@ -93,7 +133,7 @@ install:
- pushd samtools-1.9
- autoheader
- autoconf -Wno-syntax
- ./configure
- ./configure || (cat config.log; false)
- make
- sudo make install
- popd
Expand All @@ -118,7 +158,7 @@ install:
- wget https://github.com/gmarcais/Jellyfish/releases/download/v${JELLYFISH_VERSION}/jellyfish-${JELLYFISH_VERSION}.tar.gz
- tar xzf jellyfish-${JELLYFISH_VERSION}.tar.gz
- pushd jellyfish-${JELLYFISH_VERSION}
- ./configure
- ./configure || (cat config.log; false)
- make
- sudo make install
- popd
Expand Down Expand Up @@ -149,10 +189,17 @@ install:
- sudo pip install numpy

- popd
script:
before_script:
- |
export TRINITY_HOME=`pwd` && \
make && \
make plugins && \
sudo make install > /dev/null && \
make test -C sample_data/test_Trinity_Assembly
function show_log {
for file in $(find . -name config.log); do
echo "config.log File: ${file}"
cat "${file}"
done
}
- export TRINITY_HOME=`pwd`
- make || (show_log; false)
- make plugins || (show_log; false)
- sudo make install > /dev/null
script:
- make test -C sample_data/test_Trinity_Assembly
2 changes: 1 addition & 1 deletion Trinity
Original file line number Diff line number Diff line change
Expand Up @@ -1086,7 +1086,7 @@ unless ($NO_RUN_INCHWORM_FLAG || $NO_RUN_CHRYSALIS_FLAG || $bypass_java_version_
if ($java_version =~ /(java|openjdk) version \"1\.(\d)\./) {
$version_id = $2;
}
elsif ($java_version =~ /java version \"(\d+)\" /) {
elsif ($java_version =~ /java version \"(\d+)(\.)?([._\d])+?\" ?/) {
$version_id = $1;
}
elsif ($java_version =~ /java (\d+) /) {
Expand Down
4 changes: 2 additions & 2 deletions trinity-plugins/Makefile
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@

OS := $(shell uname)

CXX=g++
CC=gcc
CXX ?= g++
CC ?= gcc
COLLECTL_CODE="collectl-4.1.0"
PARAFLY_CODE="ParaFly-0.1.0"
TRIMMOMATIC_CODE=Trimmomatic-0.36
Expand Down
2 changes: 1 addition & 1 deletion trinity-plugins/scaffold_iworm_contigs/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
CXX = g++
CXX ?= g++
prefix = ../htslib

ScaffoldIwormContigs:
Expand Down

0 comments on commit c51b38e

Please sign in to comment.