Commit 80884a4d authored by jerem's avatar jerem Committed by jeremad

use ccache to speed up CI builds

parent 4f917521
language: cpp language: cpp
cache: ccache
matrix: matrix:
include: include:
...@@ -9,6 +10,7 @@ matrix: ...@@ -9,6 +10,7 @@ matrix:
update: true update: true
packages: packages:
- bison - bison
- ccache
- ceres-solver - ceres-solver
- CMake - CMake
- doxygen - doxygen
...@@ -26,7 +28,7 @@ matrix: ...@@ -26,7 +28,7 @@ matrix:
- qt - qt
- yasm - yasm
before_install: before_install:
- export PATH="/usr/local/opt/bison/bin:${PATH}" - export PATH="/usr/local/opt/bison/bin:/usr/local/opt/ccache/libexec:${PATH}"
script: script:
- mkdir build - mkdir build
- cd build - cd build
...@@ -36,17 +38,26 @@ matrix: ...@@ -36,17 +38,26 @@ matrix:
dist: xenial dist: xenial
services: services:
- docker - docker
script: before_script:
- docker build --tag stitchem-cuda8:latest --file docker/ci.dockerfile --build-arg version=8 . - docker build --tag stitchem-cuda8:latest --file docker/ci.dockerfile --build-arg version=8 .
- docker create -v ${HOME}/.ccache:/ccache --name ccache stitchem-cuda8:latest
script:
- docker run --env CCACHE_DIR=/ccache --volumes-from ccache stitchem-cuda8:latest
- name: CUDA 9 Linux - name: CUDA 9 Linux
dist: xenial dist: xenial
services: services:
- docker - docker
script: before_script:
- docker build --tag stitchem-cuda9:latest --file docker/ci.dockerfile --build-arg version=9 . - docker build --tag stitchem-cuda9:latest --file docker/ci.dockerfile --build-arg version=9 .
- docker create -v ${HOME}/.ccache:/ccache --name ccache stitchem-cuda9:latest
script:
- docker run --env CCACHE_DIR=/ccache --volumes-from ccache stitchem-cuda9:latest
- name: CUDA 10 Linux - name: CUDA 10 Linux
dist: xenial dist: xenial
services: services:
- docker - docker
script: before_script:
- docker build --tag stitchem-cuda10:latest --file docker/ci.dockerfile --build-arg version=10 . - docker build --tag stitchem-cuda10:latest --file docker/ci.dockerfile --build-arg version=10 .
- docker create -v ${HOME}/.ccache:/ccache --name ccache stitchem-cuda10:latest
script:
- docker run --env CCACHE_DIR=/ccache --volumes-from ccache stitchem-cuda10:latest
...@@ -4,6 +4,7 @@ ENV DEBIAN_FRONTEND=noninteractive ...@@ -4,6 +4,7 @@ ENV DEBIAN_FRONTEND=noninteractive
RUN apt update && apt install -y \ RUN apt update && apt install -y \
bison \ bison \
ccache \
doxygen \ doxygen \
flex \ flex \
git \ git \
......
...@@ -6,4 +6,4 @@ WORKDIR stitchEm ...@@ -6,4 +6,4 @@ WORKDIR stitchEm
RUN echo ${CUDA_SHORT} > cuda.version RUN echo ${CUDA_SHORT} > cuda.version
WORKDIR build WORKDIR build
RUN cmake -DCMAKE_BUILD_TYPE=Release -DLINUX_PKG=ON -DRTMP_NVENC=OFF -DCUDA_TARGET_ARCH="50" -G Ninja .. RUN cmake -DCMAKE_BUILD_TYPE=Release -DLINUX_PKG=ON -DRTMP_NVENC=OFF -DCUDA_TARGET_ARCH="50" -G Ninja ..
RUN ninja CMD ninja
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