summaryrefslogtreecommitdiff
path: root/.ci/docker-ccache-setup.sh
blob: caba08ac819c95b185c785079fac9d6f278ec483 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/sh

CI_BUILD_TYPE="$1"

cp .ci/ccache.conf ~/.ccache

if [ "$1" = "release-ready" ] ; then
  sed -iE '/^base_dir/d' ~/.ccache/ccache.conf
  echo "base_dir = $(pwd)/$(grep '^PACKAGE_STRING' config.log|cut -d\' -f2|tr ' ' -)" >> ~/.ccache/ccache.conf
else
  sed -iE '/^base_dir/d' ~/.ccache/ccache.conf
  echo "base_dir = $pwd" >> ~/.ccache/ccache.conf
fi