build:pw:
  tags: [docker]
  image: espressofoundation/ubuntu:latest
  script:
    - ./configure
    - make pw
#    - export OMP_NUM_THREADS=1
#    - cd test-suite
#    - mkdir /tmp/save
#    - make run-tests-pw-serial
#    - rm -r /tmp/save

build:cp:
  tags: [docker]
  image: espressofoundation/ubuntu:latest
  script:
    - ./configure
    - make cp
#    - export OMP_NUM_THREADS=1
#    - cd test-suite
#    - mkdir /tmp/save
#    - make run-tests-cp-serial
#    - rm -r /tmp/save

build:ph:
  tags: [docker]
  image: espressofoundation/ubuntu:latest
  script:
    - ./configure
    - make ph
#    - export OMP_NUM_THREADS=1
#    - cd test-suite
#    - mkdir /tmp/save
#    - make run-tests-ph-serial
#    - rm -r /tmp/save

build:cmake-gnu:
  tags: [docker]
  image: ubuntu:latest
  script:
    - apt-get update
    - DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends tzdata
    - apt-get install --yes gfortran git cmake libopenblas0 libopenblas-dev libfftw3-3 libfftw3-dev libopenmpi3 libopenmpi-dev
    - cmake --version
    - mkdir build
    - cd build
    - cmake -DCMAKE_Fortran_COMPILER=mpif90 -DCMAKE_C_COMPILER=gcc .. && make

build:pgi:
  tags: [docker]
  image: nvcr.io/nvidia/nvhpc:20.9-devel-centos7
  script:
    - ./configure FC=pgf90 F90=pgf90 F77=pgfortran MPIF90=mpif90 --enable-openmp --with-cuda=yes --enable-cuda-env-check=no
    - make pw cp ph

#build:centos:
#  image: centos:latest
#  script:
#    - yum -y groupinstall "Development Tools"
#    - yum -y install wget which python27
#    - ./configure
#    - make all
#    - export OMP_NUM_THREADS=1
#    - cd test-suite
#    - mkdir /tmp/save
#    - make run-tests-serial
#    - rm -r /tmp/save


#### BUILDS ON GALILEO ####

#build:intel:
#  tags: [galileo]
#  script:
#    - module load intel/pe-xe-2017--binary intelmpi/2017--binary mkl/2017--binary
#    - ./configure --enable-openmp
#    - make pw cp
#    - export OMP_NUM_THREADS=2
#    - cd test-suite
#    - mkdir -p /tmp/save
#    - make run-tests-pw-parallel
#    - make run-tests-cp-parallel
#    - rm -r /tmp/save
