aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Pashev <igor.pashev@nexenta.com>2012-12-20 08:36:09 +0400
committerIgor Pashev <igor.pashev@nexenta.com>2012-12-20 08:36:09 +0400
commite2d396ab55e0fe32606a6b588fcd5ee51a43779b (patch)
treece8b73981c230fd818ba0ba940ec60755686eef2
parent3e567218b60d7f885e769e1a2a07d84d38f11c13 (diff)
downloadcibs-e2d396ab55e0fe32606a6b588fcd5ee51a43779b.tar.gz
autotools.mk: define make-vars
-rw-r--r--README.md7
-rw-r--r--rules/autotools.mk6
2 files changed, 11 insertions, 2 deletions
diff --git a/README.md b/README.md
index 7930d76..1ebdc22 100644
--- a/README.md
+++ b/README.md
@@ -133,6 +133,13 @@ programs and terminal database):
build-wide-stamp: target = libs
install-wide-stamp: target = install.libs
+Another target-specific variable is "make-vars". The value of this variable
+is appended to make command. By default it is set to `V=1`
+for `build-%-stamp` (disable silent rules) and to `DESTDIR="$(protodir)"` for
+`install-%-stamp`. You can append or completely replace "make-vars" to
+make hacks or when you are using autotools.mk for packages which are not
+actually use autotools, but some hand-made configure scripts.
+
## ips.mk
This module provides functions to work with IPS manifests and publish packages.
diff --git a/rules/autotools.mk b/rules/autotools.mk
index d2b6349..afdf6e5 100644
--- a/rules/autotools.mk
+++ b/rules/autotools.mk
@@ -56,13 +56,15 @@ configure-%-stamp:
touch $@
build-%-stamp: target =
+build-%-stamp: make-vars = V=1
build-%-stamp:
- cd "$(builddir)" && $(MAKE) $(make-jobs:%=-j%) $(target) V=1
+ cd "$(builddir)" && $(MAKE) $(make-jobs:%=-j%) $(target) $(make-vars)
touch $@
install-%-stamp: target = install
+install-%-stamp: make-vars = DESTDIR="$(protodir)"
install-%-stamp:
- cd "$(builddir)" && $(MAKE) $(target) DESTDIR="$(protodir)"
+ cd "$(builddir)" && $(MAKE) $(target) $(make-vars)
touch $@