[Pkg-ocaml-maint-commits] [ocaml] 05/14: Try ccache

Ximin Luo infinity0 at debian.org
Mon Jul 17 13:34:15 UTC 2017


This is an automated email from the git hooks/post-receive script.

infinity0 pushed a commit to branch debian/experimental
in repository ocaml.

commit b775a26770a05a2e2d7f8e4aa9557e8bb55d8dad
Author: Ximin Luo <infinity0 at debian.org>
Date:   Tue Jul 4 20:49:51 2017 +0200

    Try ccache
---
 debian/rules | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/debian/rules b/debian/rules
index 369fb6d..362d475 100755
--- a/debian/rules
+++ b/debian/rules
@@ -9,6 +9,15 @@ ALL_PACKAGES := $(shell dh_listpackages)
 OCAMLMAJOR := 4.04
 OCAMLMINOR := 0
 
+# Use ccache if pkg.ocaml.ccache build-profile is active.
+# Your rebuilds will be *much quicker*.
+ifneq (,$(filter pkg.ocaml.ccache,$(DEB_BUILD_PROFILES)))
+export PATH := /usr/lib/ccache:$(PATH)
+export CCACHE_DIR := $(CURDIR)/debian/ccache
+#export CCACHE_BASEDIR := $(CURDIR)/debian/build
+$(shell mkdir -p "$(CCACHE_DIR)")
+endif
+
 # Build cache (for Debian debugging)
 BUILDCACHE := $(wildcard ../ocaml.cache)
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ocaml-maint/packages/ocaml.git



More information about the Pkg-ocaml-maint-commits mailing list