Thread (4 messages) 4 messages, 3 authors, 2012-08-26

[Buildroot] [PATCH] package/autotool infra: create missing m4 dir

flat view
STALE5178d

From: Yann E. MORIN <hidden>
Date: 2012-08-18 12:48:33
Subsystem: the rest · Maintainer: Linus Torvalds

When a package needs to be auto-reconfigured, it may be missing the m4/
sub-dir, especially when we use the package from its VCS.

Grep configure.{ac,in} tp find the location of the m4/ sub-dir (defaulting
to the root of the package), and create it.

Signed-off-by: "Yann E. MORIN" <redacted>

---

This is a tentative patch for RFC.
---
 package/pkg-autotools.mk |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/package/pkg-autotools.mk b/package/pkg-autotools.mk
index 785daab..f199ac6 100644
--- a/package/pkg-autotools.mk
+++ b/package/pkg-autotools.mk
@@ -173,6 +173,7 @@ endif
 #
 define AUTORECONF_HOOK
 	@$$(call MESSAGE,"Autoreconfiguring")
+	M4_DIR=$$$$(sed -r -e '/.*AC_CONFIG_MACRO_DIR\(\[(.*)\]\).*/!d; s//\1/g;' $$($$(PKG)_SRCDIR)configure.*) && mkdir -p "$$($$(PKG)_SRCDIR)$$$${M4_DIR:-m4}"
 	$(Q)cd $$($$(PKG)_SRCDIR) && $(AUTORECONF) $$($$(PKG)_AUTORECONF_OPT)
 	$(Q)if test "$$($$(PKG)_LIBTOOL_PATCH)" = "YES"; then \
 		for i in `find $$($$(PKG)_SRCDIR) -name ltmain.sh`; do \
-- 
1.7.2.5
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help