aboutsummarylogtreecommitdiffstats
path: root/.travis.yml
diff options
context:
space:
mode:
authorbartus2019-09-08 11:03:30 +0200
committerbartus2019-09-08 11:03:30 +0200
commiteb76757bd8cfb6eef9f86049c4b59d850ed76eec (patch)
tree618032f78c99d4127d7ad63e54ce332caa786fc8 /.travis.yml
parent2974e61d9baa3d1ce42c0150fba95ec6207ce4c7 (diff)
downloadaur-eb76757bd8cfb6eef9f86049c4b59d850ed76eec.tar.gz
ccache/Travis: use nvcc-ccache provided in ccache-ext.
Diffstat (limited to '.travis.yml')
-rw-r--r--.travis.yml14
1 files changed, 3 insertions, 11 deletions
diff --git a/.travis.yml b/.travis.yml
index 647d2ca55a1d..dd5194e77b6c 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -25,8 +25,10 @@ arch:
- bartus=https://github.com/bartoszek/AUR-repo/raw/master
packages:
- ccache
- - moreutils
+ - ccache-ext
+# cuda need to be installed before `makepkg` invocation in order to allow nvcc-ccache logic to work.
- cuda
+ - moreutils
before_install:
# 1.Override `package-cleanup.hook` to preserve cache for travis.
# 2.Enable ccache
@@ -41,16 +43,6 @@ arch:
sudo sed -i '$a CFLAGS="$CFLAGS -w"' /etc/makepkg.conf
sudo sed -i '$a CXXFLAGS="$CXXFLAGS -w"' /etc/makepkg.conf
script:
-# Incorporate ccache in nvcc
- - |
- _gcc="$(readlink /opt/cuda/bin/gcc)"
- _gpp="$(readlink /opt/cuda/bin/g++)"
- sudo mv /opt/cuda/bin/nvcc /opt/cuda/bin/nvcc.bin
- sudo rm /opt/cuda/bin/g{cc,++}
- echo -e "#!/bin/sh -\n/usr/bin/ccache /opt/cuda/bin/nvcc.bin \"\$@\"" | sudo dd of=/opt/cuda/bin/nvcc status=none
- echo -e "#!/bin/sh -\n/usr/bin/ccache $_gcc \"\$@\"" | sudo dd of=/opt/cuda/bin/gcc status=none
- echo -e "#!/bin/sh -\n/usr/bin/ccache $_gpp \"\$@\"" | sudo dd of=/opt/cuda/bin/g++ status=none
- sudo chmod +x /opt/cuda/bin/{nvcc,g{cc,++}}
# Normalize TRAVIS variable
- |
[ "$TRAVIS" == "true" ] && TRAVIS=1 || TRAVIS=0