summaryrefslogtreecommitdiff
path: root/.ci/ci-configure.sh
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@samsung.com>2018-07-10 18:43:55 -0400
committerStefan Schmidt <s.schmidt@samsung.com>2018-07-26 08:55:58 +0200
commit005ba932344bbf4eb022df96ea24be67093324c0 (patch)
tree1296b517b2ec640ffe43cd54d468f4333076f474 /.ci/ci-configure.sh
parent45988ac6c0c8ca661601dcd9fdf10171a13568c7 (diff)
ci: add ccache support
this enables and implements full support for ccache on travis builds fix T7126 Differential Revision: https://phab.enlightenment.org/D6605 =also includes previously-submitted patches= ci: split out ccache config setup into separate script this provides a more unified place to set ccache options also enable ccache compression to cut down on cache upload/download overhead ref D6613 ci: zero ccache stats before build and add some comments for options used zeroing the stats before each build will provide more insight into the cache performance for each build ref D6621 ci: break out ccache stat printing into separate script continue to make travis.yml more readable ref D6622 ci: add more ccache config options to improve cache direct hits ci: disable second cpp run for ccache this should avoid running cpp twice for files https://ccache.samba.org/manual.html#_the_preprocessor_mode
Diffstat (limited to '.ci/ci-configure.sh')
-rwxr-xr-x.ci/ci-configure.sh11
1 files changed, 8 insertions, 3 deletions
diff --git a/.ci/ci-configure.sh b/.ci/ci-configure.sh
index 28897dafcc..86e280ec5f 100755
--- a/.ci/ci-configure.sh
+++ b/.ci/ci-configure.sh
@@ -49,7 +49,10 @@ if [ "$DISTRO" != "" ] ; then
49 if [ "$1" = "release-ready" ]; then 49 if [ "$1" = "release-ready" ]; then
50 OPTS="$OPTS $RELEASE_READY_LINUX_COPTS" 50 OPTS="$OPTS $RELEASE_READY_LINUX_COPTS"
51 fi 51 fi
52 docker run --env MAKEFLAGS="-j5" --env EIO_MONITOR_POLL=1 -v `pwd`:/src -w /src stefanschmidt1/ci-support-files:$DISTRO ./autogen.sh $OPTS 52 docker exec $(cat $HOME/cid) sh -c 'rm -f ~/.ccache/ccache.conf'
53 docker exec --env MAKEFLAGS="-j5" --env EIO_MONITOR_POLL=1 --env CC="ccache gcc" \
54 --env CXX="ccache g++" --env CFLAGS="-fdirectives-only" --env CXXFLAGS="-fdirectives-only" \
55 $(cat $HOME/cid) ./autogen.sh $OPTS
53else 56else
54 OSX_COPTS="--disable-cxx-bindings" 57 OSX_COPTS="--disable-cxx-bindings"
55 58
@@ -57,11 +60,13 @@ else
57 mkdir -p ~/Library/LaunchAgents 60 mkdir -p ~/Library/LaunchAgents
58 ln -sfv /usr/local/opt/d-bus/*.plist ~/Library/LaunchAgents 61 ln -sfv /usr/local/opt/d-bus/*.plist ~/Library/LaunchAgents
59 launchctl load ~/Library/LaunchAgents/org.freedesktop.dbus-session.plist 62 launchctl load ~/Library/LaunchAgents/org.freedesktop.dbus-session.plist
60 export PATH="$(brew --prefix gettext)/bin:$PATH" 63 export PATH="/usr/local/opt/ccache/libexec:$(brew --prefix gettext)/bin:$PATH"
61 64
62 export CFLAGS="-I/usr/local/opt/openssl/include $CFLAGS" 65 export CFLAGS="-I/usr/local/opt/openssl/include -frewrite-includes $CFLAGS"
66 export LDFLAGS="-L/usr/local/opt/openssl/lib $LDFLAGS"
63 export LDFLAGS="-L/usr/local/opt/openssl/lib $LDFLAGS" 67 export LDFLAGS="-L/usr/local/opt/openssl/lib $LDFLAGS"
64 68
65 # Normal build test of all targets 69 # Normal build test of all targets
70 rm -f ~/.ccache/ccache.conf
66 ./autogen.sh $OSX_COPTS 71 ./autogen.sh $OSX_COPTS
67fi 72fi