image: fdulwich/oskar-ci:cuda-11-3

stages:
  - test
  - publish

unit-tests:
  stage: test
  tags: [k8srunner-gpu]
  before_script:
    - nvidia-smi
    - mkdir build && cd build
    # todo: replace arch value with project variable
    - cmake .. -DCUDA_ARCH=6.1
    - make -j
  script:
    - ctest --output-on-failure

doc-pdf:
  stage: publish
  image: ubuntu:20.04
  before_script:
    - >
      apt-get update && DEBIAN_FRONTEND=noninteractive
      apt-get -qq install build-essential cmake doxygen doxygen-latex texlive
    - mkdir build && cd build
    - cmake ..
  script:
    - make doc_single
  artifacts:
    paths:
      - build/doc/*.pdf
    expire_in: 1 week
#  rules:
#    - if: '$CI_COMMIT_TAG'

image: fdulwich/oskar-ci:cuda-11-3

stages:
  - test
  - publish

unit-tests:
  stage: test
  tags: [k8srunner-gpu]
  before_script:
    - nvidia-smi
    - mkdir build && cd build
    # todo: replace arch value with project variable
    - cmake .. -DCUDA_ARCH=6.1
    - make -j
  script:
    - ctest --output-on-failure

doc-pdf:
  stage: publish
  image: ubuntu:18.04 # Use Doxygen version 1.8.13 for compatibility.
  before_script:
    - >
      apt-get update && DEBIAN_FRONTEND=noninteractive
      apt-get -qq install build-essential cmake doxygen doxygen-latex texlive
    - mkdir build && cd build
    - cmake ..
  script:
    - make doc_single
  artifacts:
    paths:
      - build/doc/*.pdf
    expire_in: 1 week
#  rules:
#    - if: '$CI_COMMIT_TAG'

Use Doxygen version 1.8.13 in CI for compatibility.
HIP-52: Use Doxygen version 1.8.13 in CI for compatibility.
