Skip to content

Commit

Permalink
Merge pull request #1305 from boutproject/v4.2-rc
Browse files Browse the repository at this point in the history
Version 4.2.0
  • Loading branch information
ZedThree authored Oct 17, 2018
2 parents 8389878 + 91096a3 commit 8567b2d
Show file tree
Hide file tree
Showing 757 changed files with 64,823 additions and 37,558 deletions.
33 changes: 33 additions & 0 deletions .codacy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
---
languages:
cpp:
extensions:
- '*.hxx'
- '*.cxx'
engines:
coverage:
enabled: true
exclude_paths:
- tests/**
- examples/**
bandit:
enabled: true
include_paths:
- tools/pylib/**
cppcheck:
enabled: true
exclude_paths:
- externalpackages/**
- tools/**
pylint:
enable: true
include_paths:
- tools/pylib/**
prospector:
enable: true
include_paths:
- tools/pylib/**
shellcheck:
enable: true
exclude_paths:
- build-aux/**
11 changes: 11 additions & 0 deletions .codacy_coverage.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#First install the reporter tool
wget -q -O ~/codacy-coverage-reporter-assembly-latest.jar https://oss.sonatype.org/service/local/repositories/releases/content/com/codacy/codacy-coverage-reporter/4.0.1/codacy-coverage-reporter-4.0.1-assembly.jar > /dev/null

#Analyse the existing gcov files and output in compatible xml format
#The -g option says to use the existing gcov files, the -k options says to not delete the gcov files
#The -j option is like make's -j
#See https://gcovr.com/guide.html for more details
gcovr --root . -k -j 2 --xml -o gcovr_report.xml --exclude-directories "tests/.*"

#Do the upload
java -jar ~/codacy-coverage-reporter-assembly-latest.jar report -f --language CPP -r gcovr_report.xml --partial
7 changes: 7 additions & 0 deletions .codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
comment: false

ignore:
- "tests"

codecov:
branch: next
7 changes: 5 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,17 @@
.tmtags
autom4te.cache/
aclocal.m4
data_*
test*.py
/bin/bout-config
/externalpackages/
/include/pvode
/lib/
/manual/*.pdf
/tools/vagrant/.vagrant
\#*#
.#*
*.132t.vect
*.gcda
*.gcno
bout-coverage/
src/.libfast
.*.mk
19 changes: 0 additions & 19 deletions .install_miniconda_for_travis.sh

This file was deleted.

17 changes: 17 additions & 0 deletions .pip_install_for_travis.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/bash
export PATH=${HOME}/.local/bin:${PATH}
pip3 install --user --upgrade pip setuptools

for package in $@
do
if test $package == "cython"
then
# fast install Cython
pip3 install --user Cython --install-option="--no-cython-compile"
elif test $package == "something_else"
then
pip3 install what_we_need
else
pip3 install --user $package
fi
done
139 changes: 94 additions & 45 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,57 +3,112 @@ dist: trusty
language: cpp
compiler: gcc

git:
depth: 3

addons:
apt:
packages:
- openmpi-bin
- libopenmpi-dev
# Note &<name> creates a reference that we can refer to later using
# *<name>, see https://en.wikipedia.org/wiki/YAML#Syntax
packages: &standard_packages
- libfftw3-dev
- libnetcdf-dev
- libhdf5-serial-dev
- netcdf-bin
- hdf5-tools
- python3
- python3-pip
- python3-numpy
- python3-scipy
- lcov
- libhdf5-mpi-dev
- openmpi-bin
- libopenmpi-dev

matrix:
fast_finish: true
include:
- env: CONFIGURE_OPTIONS=''
- env: CONFIGURE_OPTIONS='--enable-openmp' OMP_NUM_THREADS=2
- env: CONFIGURE_OPTIONS='--enable-debug'
- env: CONFIGURE_OPTIONS='--enable-checks=no --enable-optimize=3 --disable-signal --disable-track --disable-backtrace'
- env: CONFIGURE_OPTIONS='' MPICH_CC=clang MPICH_CXX=clang++ OMPI_CC=clang OMPI_CXX=clang++
compiler: clang
- env: CONFIGURE_OPTIONS='--enable-debug' MPICH_CC=clang MPICH_CXX=clang++ OMPI_CC=clang OMPI_CXX=clang++
compiler: clang
- env: &default_env
- CONFIGURE_OPTIONS='--enable-checks=no --enable-optimize=3 --disable-signal --disable-track --disable-backtrace'
- SCRIPT_FLAGS='-uim'
- PIP_PACKAGES='netcdf4'
- addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- openmpi-bin
- libopenmpi-dev
- libfftw3-dev
- libnetcdf-dev
- libhdf5-serial-dev
- netcdf-bin
- hdf5-tools
- g++-7
- *standard_packages
env:
- *default_env
- CONFIGURE_OPTIONS='--enable-debug'
- CC=gcc-7 CXX=g++-7
- MATRIX_EVAL="CC=gcc-7 && CXX=g++-7"
#The -Wno-literal-suffix flag in CXXFLAGS above is a temporary workaround to
#disable a noisy message arising from the relatively old version of openmpi
#in use in combination with the relatively new version of gcc. We should be able
#to remove this if a newer openmpi version is introduced.
- CXXFLAGS="-Wno-literal-suffix -Wall -Wextra"
- env:
- *default_env
- CONFIGURE_OPTIONS='--enable-shared'
- SCRIPT_FLAGS="-uim -t python -t shared"
- PIP_PACKAGES='netcdf4 cython'
- env:
- *default_env
- CONFIGURE_OPTIONS='--enable-openmp'
- OMP_NUM_THREADS=2
#CLANG
- env:
- *default_env
- CONFIGURE_OPTIONS='--enable-debug'
- MPICH_CC=clang MPICH_CXX=clang++
- OMPI_CC=clang OMPI_CXX=clang++
compiler: clang
#COVERAGE
- if: branch IN (master, next) OR commit_message =~ /build coverage/
addons:
apt:
packages:
- *standard_packages
- libpetsc3.4.2-dev
env: CONFIGURE_OPTIONS='--with-petsc' PETSC_DIR=/usr/lib/petscdir/3.4.2 PETSC_ARCH=linux-gnu-c-opt
- addons:
- libslepc3.4.2-dev
- liblapack-dev
- libparpack2-dev
- jq
env:
- CONFIGURE_OPTIONS='--enable-code-coverage --enable-debug --enable-track --enable-checks=3 --with-petsc --with-lapack --with-slepc --enable-openmp'
- OMP_NUM_THREADS=2
- PETSC_DIR=/usr/lib/petscdir/3.4.2
- PETSC_ARCH=linux-gnu-c-opt
- SLEPC_DIR=/usr/lib/slepcdir/3.4.2
- SLEPC_ARCH=linux-gnu-c-opt
- SCRIPT_FLAGS='-cu'
- PIP_PACKAGES='gcovr'
- secure: "M5U3I81hzK41Kw7KB+DpEMxP/sgkWkFI4uiRZQDMDFRlhcitsJQQ/YGeBt3a0vo153m2P2PmmeKUl/lTo5WS5SfAVFI8BkcyBjpxZQXV3OD8ru7JsMgVc5pGwl2dvR8Qz02gUIbrIpAlf3YDnNVb6F1C9ofDaCnZU3GUTLH5Fy5z5Z8OpuTaLmTVMMnT2ZEcRawHbmlVhIB/9PUQUa+fM7iC+dtszFxZ2ma5LOHxPS2sGpRCKE5Sae1/xAFWjo4oO0ZqYu5JFvKdb+/2yWKTg/1aTyxCdqAzLg4ldzDlX759zXgtWn+k3TLiVyQ+gsvF8QZkh4BKvl/w2KZ20vRP3blzmxvdsSH+ZP92MZIIK9EkNPGd+UJJd5Hu+zwecEFyfO8bXB9l00kzUsVx+lo7VHbANuNO3b5a6FRiihTCgk+dfOxxrow/fci+lQ9BkmJg0680SIj2e6UM/P9lFgfQLH3IoacN1PtkyqnpJqdHUdbWmpqMtmitmQhXHjnJ+wDb5+i9b1fy5yEsB64rjgF9PBr1/Nos1XD4oGWAknXmQTgWhNyy6f+e0wBNcSUd5nrReLTOAscyXYpcTqONp1W999JSFQEH+YTwBfXytdkWaAGAFEhaaAXQ2jCwHO7jl/TODPfSeZgXkQiT5jgg63i5tlPB4Xn0MTSCX74bYIi16Tk="
- if: branch IN (master, next) OR commit_message =~ /build coverage/
addons:
apt:
packages:
- *standard_packages
- jq
env:
- CONFIGURE_OPTIONS='--enable-code-coverage --disable-debug --disable-checks'
- SCRIPT_FLAGS='-cu'
- PIP_PACKAGES='gcovr'
- secure: "M5U3I81hzK41Kw7KB+DpEMxP/sgkWkFI4uiRZQDMDFRlhcitsJQQ/YGeBt3a0vo153m2P2PmmeKUl/lTo5WS5SfAVFI8BkcyBjpxZQXV3OD8ru7JsMgVc5pGwl2dvR8Qz02gUIbrIpAlf3YDnNVb6F1C9ofDaCnZU3GUTLH5Fy5z5Z8OpuTaLmTVMMnT2ZEcRawHbmlVhIB/9PUQUa+fM7iC+dtszFxZ2ma5LOHxPS2sGpRCKE5Sae1/xAFWjo4oO0ZqYu5JFvKdb+/2yWKTg/1aTyxCdqAzLg4ldzDlX759zXgtWn+k3TLiVyQ+gsvF8QZkh4BKvl/w2KZ20vRP3blzmxvdsSH+ZP92MZIIK9EkNPGd+UJJd5Hu+zwecEFyfO8bXB9l00kzUsVx+lo7VHbANuNO3b5a6FRiihTCgk+dfOxxrow/fci+lQ9BkmJg0680SIj2e6UM/P9lFgfQLH3IoacN1PtkyqnpJqdHUdbWmpqMtmitmQhXHjnJ+wDb5+i9b1fy5yEsB64rjgF9PBr1/Nos1XD4oGWAknXmQTgWhNyy6f+e0wBNcSUd5nrReLTOAscyXYpcTqONp1W999JSFQEH+YTwBfXytdkWaAGAFEhaaAXQ2jCwHO7jl/TODPfSeZgXkQiT5jgg63i5tlPB4Xn0MTSCX74bYIi16Tk="

- stage: Finalise Coverage
if: branch IN (master, next) OR commit_message =~ /build coverage/
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-6
- openmpi-bin
- libopenmpi-dev
- libfftw3-dev
- libnetcdf-dev
- libhdf5-serial-dev
- netcdf-bin
- hdf5-tools
env: CONFIGURE_OPTIONS='' CC=gcc-6 CXX=g++-6 MPICH_CC=gcc-6 MPICH_CXX=g++-6 OMPI_CC=gcc-6 OMPI_CXX=g++-6 MATRIX_EVAL="CC=gcc-6 && CXX=g++-6" CXXFLAGS=-Wno-literal-suffix
#The -Wno-literal-suffix flag in CXXFLAGS above is a temporary workaround to
#disable a noisy message arising from the relatively old version of openmpi
#in use in combination with the relatively new version of gcc. We should be able
#to remove this if a newer openmpi version is introduced.
- *standard_packages
- jq
env:
- SCRIPT_FLAGS='-cu'
- PIP_PACKAGES='gcovr'
- secure: "M5U3I81hzK41Kw7KB+DpEMxP/sgkWkFI4uiRZQDMDFRlhcitsJQQ/YGeBt3a0vo153m2P2PmmeKUl/lTo5WS5SfAVFI8BkcyBjpxZQXV3OD8ru7JsMgVc5pGwl2dvR8Qz02gUIbrIpAlf3YDnNVb6F1C9ofDaCnZU3GUTLH5Fy5z5Z8OpuTaLmTVMMnT2ZEcRawHbmlVhIB/9PUQUa+fM7iC+dtszFxZ2ma5LOHxPS2sGpRCKE5Sae1/xAFWjo4oO0ZqYu5JFvKdb+/2yWKTg/1aTyxCdqAzLg4ldzDlX759zXgtWn+k3TLiVyQ+gsvF8QZkh4BKvl/w2KZ20vRP3blzmxvdsSH+ZP92MZIIK9EkNPGd+UJJd5Hu+zwecEFyfO8bXB9l00kzUsVx+lo7VHbANuNO3b5a6FRiihTCgk+dfOxxrow/fci+lQ9BkmJg0680SIj2e6UM/P9lFgfQLH3IoacN1PtkyqnpJqdHUdbWmpqMtmitmQhXHjnJ+wDb5+i9b1fy5yEsB64rjgF9PBr1/Nos1XD4oGWAknXmQTgWhNyy6f+e0wBNcSUd5nrReLTOAscyXYpcTqONp1W999JSFQEH+YTwBfXytdkWaAGAFEhaaAXQ2jCwHO7jl/TODPfSeZgXkQiT5jgg63i5tlPB4Xn0MTSCX74bYIi16Tk="
script: wget -q -O ~/codacy-coverage-reporter-assembly-latest.jar https://oss.sonatype.org/service/local/repositories/releases/content/com/codacy/codacy-coverage-reporter/4.0.1/codacy-coverage-reporter-4.0.1-assembly.jar ; java -jar ~/codacy-coverage-reporter-assembly-latest.jar final

before_install:
##################################################
Expand All @@ -64,19 +119,13 @@ before_install:
- eval "${MATRIX_EVAL}"
- echo "${CC} $(${CC} --version)"
##################################################
# Install Conda for python 3
# Install remaining python3 packages using pip
##################################################
- source .install_miniconda_for_travis.sh

##################################################

# Make sure to use the system NetCDF/HDF5 libraries, or we end up
# using the Conda libraries, which causes no end of headaches
- export CONFIGURE_OPTIONS="--with-netcdf=/usr/bin/nc-config --with-hdf5=/usr/bin/h5cc $CONFIGURE_OPTIONS"
- source .pip_install_for_travis.sh ${PIP_PACKAGES}

script:
# Configure, compile and run test_suite
- "./.travis_script.sh"
- "./.travis_script.sh ${SCRIPT_FLAGS}"

notifications:
# Send a notification to the BOUT++ Slack team
Expand Down
Loading

0 comments on commit 8567b2d

Please sign in to comment.