[PATCH] ax_enable_builddir: improve quality of generated top-level Makefile

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The top-level Makefile is generated by mangling rules, "a: b".  We
already avoid mangling "a := b".  But we should also exclude "a = :".

Apparently this was causing unbalanced parenthesis errors on some
systems.

Reported-by: Mike Frysinger <vapier@xxxxxxxxxx>
Signed-off-by: Alan Jenkins <alan-jenkins@xxxxxxxxxxxxxx>
---
This version uses two separate rules, rather than resorting to "\?"
which is ugly and not part of the POSIX regex spec.

The patch applies to the module-init-tools tree.  I assume Peter can
use it as well though.

diff --git a/m4/ax_enable_builddir.m4 b/m4/ax_enable_builddir.m4
index 49b3eb9..4273a53 100644
--- a/m4/ax_enable_builddir.m4
+++ b/m4/ax_enable_builddir.m4
@@ -187,8 +187,9 @@ s/^srcdir *=.*/srcdir = ./
s/^top_srcdir *=.*/top_srcdir = ./
/[[:=]]/!d
/^\\./d
-dnl Now handle rules (i.e. lines containing /:/ but not /:=/).
-/:=/b
+dnl Now handle rules (i.e. lines containing ":" but not " = ").
+/ = /b
+/ .= /b
/:/!b
s/:.*/:/
s/ /  /g


--
To unsubscribe from this list: send the line "unsubscribe linux-modules" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux