summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRay Donnelly <mingw.android@gmail.com>2013-07-10 11:40:21 (GMT)
committerRay Donnelly <mingw.android@gmail.com>2013-07-10 11:40:21 (GMT)
commit4e45eb1093c734b81410ffec58edfe7cbba6a6ba (patch)
treedc1f23b4d30b188a28fc40aa63b36e21e02e4f64
parent3835e6b6ee85307fa6874af2e3e510cd367bbf9e (diff)
Allow reordered MAKEFLAGS
-R and -r (-Rr) can be reordered to -r and -R (-rR). This happens with MSYS1/2 gnu-make and mingw32-make, and triggers "Recursion detected, bailing out..." Signed-off-by: Ray Donnelly <mingw.android@gmail.com> Message-Id: <CAOYw7dsdsg-XaDOwwEWJeUUSo2Vu_UD5GtkSgNTu59ai7yx0cQ@mail.gmail.com> Patchwork-Id: 258027
-rw-r--r--Makefile.in5
1 files changed, 5 insertions, 0 deletions
diff --git a/Makefile.in b/Makefile.in
index 29aff1c..09bbf7c 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -24,9 +24,14 @@ endif
# Note: dual test, because if -R and -r are given on the command line
# (who knows?), MAKEFLAGS contains 'Rr' instead of '-Rr', while adding
# '-Rr' to MAKEFLAGS adds it literaly ( and does not add 'Rr' )
+# Further: quad test because the flags 'rR' and '-rR' can be reordered.
ifeq ($(filter Rr,$(MAKEFLAGS)),)
ifeq ($(filter -Rr,$(MAKEFLAGS)),)
+ifeq ($(filter rR,$(MAKEFLAGS)),)
+ifeq ($(filter -rR,$(MAKEFLAGS)),)
CT_MAKEFLAGS += -Rr
+endif # No -rR
+endif # No rR
endif # No -Rr
endif # No Rr