automake-patches
[Top][All Lists]
Advanced

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

[FYI] {branch-1.13.2} make flags analysis: embed in a subshell


From: Stefano Lattarini
Subject: [FYI] {branch-1.13.2} make flags analysis: embed in a subshell
Date: Fri, 3 May 2013 12:49:29 +0200

So that we won't have to worry about leaking temporary variables,
and similar stuff.

* lib/am/header-vars.am (am__make_dryrun, am__make_keepgoing): Here.
(am__make_running_with_option): Minor adjustments.

Signed-off-by: Stefano Lattarini <address@hidden>
---
 lib/am/header-vars.am | 11 ++++-------
 1 file changed, 4 insertions(+), 7 deletions(-)

diff --git a/lib/am/header-vars.am b/lib/am/header-vars.am
index 72a1877..11779f5 100644
--- a/lib/am/header-vars.am
+++ b/lib/am/header-vars.am
@@ -36,7 +36,6 @@ am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n 
'$(MAKELEVEL)'
 ## no argument.  Actually, the only supported option at the moment
 ## is '-n' (support for '-k' will be added soon).
 am__make_running_with_option = \
-  { \
     case $${am__target_option-} in \
         ?) ;; \
         *) echo "am__make_running_with_option: internal error: invalid" \
@@ -89,22 +88,20 @@ am__make_running_with_option = \
       case $$am__flg in \
         *$$am__target_option*) am__has_opt=yes; break;; \
       esac; \
-    done;\
-    unset am__skip_next am__flg am__flags am__target_option; \
-    test $$am__has_opt = yes; \
-  }
+    done; \
+    test $$am__has_opt = yes
 
 ## Shell code that determines whether make is running in "dry mode"
 ## ("make -n") or not.  Useful in rules that invoke make recursively,
 ## and are thus executed also with "make -n" -- either because they
 ## are declared as dependencies to '.MAKE' (NetBSD make), or because
 ## their recipes contain the "$(MAKE)" string (GNU and Solaris make).
-am__make_dryrun = { am__target_option=n; $(am__make_running_with_option); }
+am__make_dryrun = (am__target_option=n; $(am__make_running_with_option))
 
 ## Shell code that determines whether make is running in "keep-going mode"
 ## ("make -k") or not.  Useful in rules that must recursively descend into
 ## subdirectories, and decide whther to stop at the first error or not.
-am__make_keepgoing = { am__target_option=k; $(am__make_running_with_option); }
+am__make_keepgoing = (am__target_option=k; $(am__make_running_with_option))
 
 ## Some derived variables that have been found to be useful.
 pkgdatadir = $(datadir)/@PACKAGE@
-- 
1.8.3.rc0.19.g7e6a0cc




reply via email to

[Prev in Thread] Current Thread [Next in Thread]