Commit d6af4934 authored by Chris Cantwell's avatar Chris Cantwell

Merge branch 'feature/gitlab_ci' into feature/fenton-set4

parents 8db001ec 26ab5e9b
......@@ -4,6 +4,7 @@
!.gitattributes
!.clang-format
!.dockerignore
!.gitlab-ci
# Ignore builds and ThirdParty directories
build
builds
......
This diff is collapsed.
FROM %%BASE_IMAGE%%
ADD --chown=nektar:nektar . /home/nektar/nektar
#!/bin/bash -x
[[ $OS_VERSION != "osx" ]] && ccache -s && ccache -M 5G
rm -rf build && mkdir -p build && (cd build && if [[ $BUILD_TYPE == "default" ]]; then cmake -G 'Unix Makefiles' .. -DCMAKE_BUILD_TYPE=Release -DNEKTAR_TEST_ALL=ON -DNEKTAR_BUILD_TIMINGS=ON -DNEKTAR_ERROR_ON_WARNINGS=OFF ..; elif [[ $BUILD_TYPE == "full" ]]; then cmake -DCMAKE_BUILD_TYPE:STRING=Debug -DNEKTAR_FULL_DEBUG:BOOL=ON -DNEKTAR_TEST_ALL:BOOL=ON -DNEKTAR_BUILD_TIMINGS:BOOL=ON -DNEKTAR_USE_ARPACK:BOOL=ON -DNEKTAR_USE_FFTW:BOOL=ON -DNEKTAR_USE_MPI:BOOL=ON -DNEKTAR_USE_SCOTCH:BOOL=ON -DNEKTAR_USE_PETSC:BOOL=ON -DNEKTAR_USE_HDF5:BOOL=ON -DNEKTAR_USE_MESHGEN:BOOL=ON -DNEKTAR_USE_CCM:BOOL=ON -DNEKTAR_BUILD_PYTHON:BOOL=ON -DNEKTAR_TEST_USE_HOSTFILE=ON -DNEKTAR_ERROR_ON_WARNINGS=OFF ..; fi) && \
make -C build -j $NUM_CPUS all 2>&1 && \
make -C build -j $NUM_CPUS install && \
(cd build && ctest -j $NUM_CPUS --output-on-failure)
exit_code=$?
if [[ $exit_code -ne 0 ]]
then
[[ $OS_VERSION != "osx" ]] && rm -rf build/dist
exit $exit_code
fi
#!/bin/bash
rm -rf nektar/build/dist
tar czf nektar.tar.gz nektar
rm -rf nektar
......@@ -5,6 +5,7 @@ v5.1.0
------
**Library**
- Refactored time integration code using factory pattern (!1034)
- Fix to preprocessor logic for boost with Visual Studio >= 2015 (!1115)
**CardiacEPSolver**
- Added additional parameter sets to Fenton-Karma model (!1119)
......
......@@ -10,7 +10,7 @@ split up into a number of sections:
- [How to contribute](#how-to-contribute)
- [Submission checklist](#submission-checklist)
- [Git cheatsheet](#git-cheatsheet)
- [Testing and Buildbot](#testing-and-buildbot)
- [Testing and GitLab CI](#testing-and-gitlab)
- [Documentation](#documentation)
- [Formatting guidelines](#formatting-guidelines)
......@@ -51,9 +51,9 @@ project. It's a pretty simple process:
## Submission checklist
- Did you add regression tests (for fixes) or unit tests and/or normal tests for
new features?
- Have you run your branch through buildbot and do all the tests pass?
- Have you run your branch through GitLab CI and do all the tests pass?
- Have you fixed any new compiler warnings your code has introduced into the
compilation step for all of the Linux buildbots?
compilation step for all of the Linux CI environments?
- **unused parameters**: if these are genuinely needed (e.g. virtual functions
in a derived class, please use `boost::ignore_unused()` to mark as such.
- **switch case may fall-through**: for switch statements which
......@@ -105,7 +105,7 @@ commit, you can additionally use the `git gui` command to bring up a simple
interface. `git difftool` can also be used in combination with a GUI diff
viewer, to graphically view the output of `git diff`.
## Testing and Buildbot
## Testing and GitLab CI
Your new features or fixes should include tests that cover the code you've
added. There are numerous examples within the various `Tests` directory lying
within the source trees, and there is an example of writing `.tst` files for our
......@@ -114,29 +114,15 @@ tests, add them to the `CMakeLists.txt` file for the relevant solver, or to the
appropriate demos directory for library features in whatever directory you are
working in.
You should also test your branch on the
[Nektar++ buildbot](http://buildbot.nektar.info/), which will compile and test
the code against a number of Linux, Mac and Windows operating systems, both 32-
and 64-bit. If your tests don't pass, we can't merge the code into master.
You should also test your branch on the Nektar++ GitLab CI, which will compile
and test the code against a number of Linux, Mac and Windows operating
systems. If your tests don't pass, we can't merge the code into master.
When you submit a merge request testing on buildbot will happen automatically,
When you submit a merge request testing on GitLab CI will happen automatically,
unless you have marked the merge request as a work-in-progress (WIP: prefix).
Each time you push commits to a non-WIP merge request branch, it will also
trigger a build.
For WIP merge request branches, you can force a build on individual builders
using the buildbot web interface:
1. Go to the buildbot site and log in using the drop-down menu (top right).
2. Go to the console display and select the builder from the column headings on
which you would like to force test.
3. Select 'Force' from the top-right of the page.
4. Enter the details as required. If you're working on a fork, then the *Fork*
box should be changed to `username/nektar`.
5. Hit the *Start build* button.
6. Return to the *console* display to see progress. You can click on the
flashing indicator for your active build to see progress and output.
## Documentation
Nektar++ has a fairly comprehensive user guide and a developer guide that is
presently very incomplete. The following are rough guidelines for what you
......
FROM centos:%%OS_VERSION%%
LABEL maintainer="Nektar++ Development Team <nektar-users@imperial.ac.uk>"
ENV CENTOS_VERSION %%OS_VERSION%%
COPY docker/nektar-env/${CENTOS_VERSION}_default_packages.txt packages.txt
RUN yum install -y epel-release && \
yum install -y $(cat packages.txt) \
&& yum clean all
# openmpi installs to a non-standard location on centos7
# below env vars added to help out cmake
ENV LD_LIBRARY_PATH /usr/lib64/openmpi/lib/
ENV PATH /usr/lib64/openmpi/bin/:$PATH
RUN ln -s /usr/bin/ccache /usr/local/bin/cc && ln -s /usr/bin/ccache /usr/local/bin/c++
RUN groupadd nektar && useradd -m -g nektar nektar
USER nektar:nektar
RUN mkdir /home/nektar/nektar
WORKDIR /home/nektar/nektar
FROM %%REGISTRY%%:env-%%OS_VERSION%%-default
LABEL maintainer="Nektar++ Development Team <nektar-users@imperial.ac.uk>"
USER root
COPY docker/nektar-env/${CENTOS_VERSION}_full_packages.txt packages.txt
RUN yum install -y epel-release && \
yum install -y $(cat packages.txt) \
&& yum clean all
USER nektar:nektar
FROM debian:%%OS_VERSION%%-slim
LABEL maintainer="Nektar++ Development Team <nektar-users@imperial.ac.uk>"
ENV DEBIAN_VERSION %%OS_VERSION%%
COPY docker/nektar-env/${DEBIAN_VERSION}_default_packages.txt packages.txt
RUN echo "deb http://deb.debian.org/debian ${DEBIAN_VERSION} non-free" > \
/etc/apt/sources.list.d/debian-non-free.list && \
apt-get update && \
apt-get install -y $(cat packages.txt) \
&& rm -rf /var/lib/apt/lists/*
RUN ln -s /usr/bin/ccache /usr/local/bin/cc && ln -s /usr/bin/ccache /usr/local/bin/c++
RUN groupadd nektar && useradd -m -g nektar nektar
USER nektar:nektar
RUN mkdir /home/nektar/nektar
WORKDIR /home/nektar/nektar
FROM gitlab.nektar.info:4567/ccaveayl/nektar:env-buster-default
USER root
COPY docker/nektar-env/buster_documentation_packages.txt packages.txt
RUN echo "deb http://deb.debian.org/debian buster non-free" > \
/etc/apt/sources.list.d/debian-non-free.list && \
apt-get update && \
apt-get install -y $(cat packages.txt) \
&& rm -rf /var/lib/apt/lists/*
USER nektar:nektar
FROM %%REGISTRY%%:env-%%OS_VERSION%%-default
LABEL maintainer="Nektar++ Development Team <nektar-users@imperial.ac.uk>"
USER root
COPY docker/nektar-env/${DEBIAN_VERSION}_full_packages.txt packages.txt
RUN echo "deb http://deb.debian.org/debian ${DEBIAN_VERSION} non-free" > \
/etc/apt/sources.list.d/debian-non-free.list && \
apt-get update && \
apt-get install -y $(cat packages.txt) \
&& rm -rf /var/lib/apt/lists/*
USER nektar:nektar
FROM ubuntu:%%OS_VERSION%%
LABEL maintainer="Nektar++ Development Team <nektar-users@imperial.ac.uk>"
ENV UBUNTU_VERSION %%OS_VERSION%%
COPY docker/nektar-env/${UBUNTU_VERSION}_default_packages.txt packages.txt
RUN export DEBIAN_FRONTEND=noninteractive && \
apt-get update && \
apt-get install -y $(cat packages.txt) \
&& rm -rf /var/lib/apt/lists/*
RUN ln -s /usr/bin/ccache /usr/local/bin/cc && ln -s /usr/bin/ccache /usr/local/bin/c++
RUN groupadd nektar && useradd -m -g nektar nektar
USER nektar:nektar
RUN mkdir /home/nektar/nektar
WORKDIR /home/nektar/nektar
FROM %%REGISTRY%%:env-%%OS_VERSION%%-default
LABEL maintainer="Nektar++ Development Team <nektar-users@imperial.ac.uk>"
USER root
COPY docker/nektar-env/${UBUNTU_VERSION}_full_packages.txt packages.txt
RUN export DEBIAN_FRONTEND=noninteractive && \
apt-get update && \
apt-get install -y $(cat packages.txt) \
&& rm -rf /var/lib/apt/lists/*
USER nektar:nektar
......@@ -24,3 +24,8 @@ or similar.
```sh
docker build -t nektarpp/nektar-env -f Dockerfile .
```
# Other environment images
The other dockerfiles for different operating systems and package lists are used
to provide environment images for the CI system. See .gitlab-ci.yml for details.
ccache
cmake
g++
libboost-filesystem-dev
libboost-iostreams-dev
libboost-program-options-dev
libboost-regex-dev
libboost-system-dev
libboost-thread-dev
liblapack-dev
libscotch-dev
libtinyxml-dev
zlib1g-dev
libarpack2-dev
libboost-numpy-dev
libboost-python-dev
libfftw3-dev
libhdf5-mpi-dev
liboce-foundation-dev
liboce-modeling-dev
liboce-ocaf-dev
libptscotch-dev
libtet1.5-dev
libtriangle-dev
mpi-default-dev
petsc-dev
python-dev
python-numpy
rsh-client
build-essential
ccache
cmake
libboost-filesystem-dev
libboost-iostreams-dev
libboost-program-options-dev
libboost-regex-dev
libboost-system-dev
libboost-thread-dev
liblapack-dev
libscotch-dev
libtinyxml-dev
zlib1g-dev
cmake
doxygen
dvipng
graphviz
imagemagick
texlive-base
texlive-fonts-recommended
texlive-latex-extra
texlive-pstricks
texlive-science
libarpack2-dev
libboost-numpy-dev
libboost-python-dev
libfftw3-dev
libhdf5-dev
libhdf5-mpi-dev
liboce-foundation-dev
liboce-modeling-dev
liboce-ocaf-dev
libptscotch-dev
libtet1.5-dev
libtriangle-dev
mpi-default-dev
petsc-dev
python-numpy
blas-devel
ccache
cmake
fftw-devel
gcc-c++
gcc-gfortran
lapack-devel
make
patch
scotch-devel
tinyxml-devel
zlib-devel
OCE-devel
arpack-devel
boost-devel
boost-python-devel
hdf5-openmpi-devel
numpy
openmpi-devel
petsc-devel
ptscotch-openmpi-devel
python-devel
scotch-devel
tetgen-devel
build-essential
ccache
cmake
libboost-filesystem-dev
libboost-iostreams-dev
libboost-program-options-dev
libboost-regex-dev
libboost-system-dev
libboost-thread-dev
liblapack-dev
libscotch-dev
libtinyxml-dev
zlib1g-dev
libarpack2-dev
libboost-python-dev
libfftw3-dev
libhdf5-dev
libhdf5-mpi-dev
liboce-foundation-dev
liboce-modeling-dev
liboce-ocaf-dev
libptscotch-dev
libtet1.5-dev
libtriangle-dev
mpi-default-dev
petsc-dev
python-numpy
rsh-client
ccache
cmake
g++
libboost-filesystem-dev
libboost-iostreams-dev
libboost-program-options-dev
libboost-regex-dev
libboost-system-dev
libboost-thread-dev
liblapack-dev
libscotch-dev
libtinyxml-dev
zlib1g-dev
libarpack2-dev
libboost-python-dev
libfftw3-dev
libhdf5-mpi-dev
liboce-foundation-dev
liboce-modeling-dev
liboce-ocaf-dev
libptscotch-dev
libtet1.5-dev
libtriangle-dev
mpi-default-dev
patch
petsc-dev
python-dev
python-numpy
rsh-client
ccache
cmake
g++
libboost-filesystem-dev
libboost-iostreams-dev
libboost-program-options-dev
libboost-regex-dev
libboost-system-dev
libboost-thread-dev
liblapack-dev
libscotch-dev
libtinyxml-dev
zlib1g-dev
libarpack2-dev
libboost-python-dev
libfftw3-dev
libhdf5-mpi-dev
liboce-foundation-dev
liboce-modeling-dev
liboce-ocaf-dev
libptscotch-dev
libtet1.5-dev
libtriangle-dev
mpi-default-dev
patch
petsc-dev
python-dev
python-numpy
rsh-client
......@@ -1088,7 +1088,7 @@ void CouplingCwipi::DumpRawFields(const NekDouble time,
LibUtilities::Timer timer1;
timer1.Start();
#ifdef _WIN32
#if (defined _WIN32 && _MSC_VER < 1900)
// We need this to make sure boost::format has always
// two digits in the exponents of Scientific notation.
unsigned int old_exponent_format;
......
......@@ -101,7 +101,7 @@ void CouplingFile::v_Send(
vector<int> sendVarsToVars =
GenerateVariableMapping(varNames, m_sendFieldNames);
#ifdef _WIN32
#if (defined _WIN32 && _MSC_VER < 1900)
// We need this to make sure boost::format has always
// two digits in the exponents of Scientific notation.
unsigned int old_exponent_format;
......@@ -162,7 +162,7 @@ void CouplingFile::v_Receive(const int step,
string filename = m_evalField->GetSession()->GetFunctionFilename(
m_config["RECEIVEFUNCTION"], m_recvFieldNames[0]);
#ifdef _WIN32
#if (defined _WIN32 && _MSC_VER < 1900)
// We need this to make sure boost::format has always
// two digits in the exponents of Scientific notation.
unsigned int old_exponent_format;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment