From: Stefano Lattarini Date: Fri, 3 May 2013 10:52:14 +0000 (+0200) Subject: make flags analysis: whitespace changes X-Git-Tag: v1.13.1d~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=6d643e93182d50d236ccfeacffad55576cf51d99;p=platform%2Fupstream%2Fautomake.git make flags analysis: whitespace changes * lib/am/header-vars.am (am__make_running_with_option): Here. No semantic change is intended. Signed-off-by: Stefano Lattarini --- diff --git a/lib/am/header-vars.am b/lib/am/header-vars.am index 11779f5..ed640b2 100644 --- a/lib/am/header-vars.am +++ b/lib/am/header-vars.am @@ -36,60 +36,60 @@ 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" \ - "target option '$${am__target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - am__has_opt=no; \ - am__flags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ + case $${am__target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${am__target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + am__has_opt=no; \ + am__flags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ ## The format of $(MAKEFLAGS) is quite tricky with GNU make; the ## variable $(MFLAGS) behaves much better in that regard. So use it. - am__flags=$$MFLAGS; \ - else \ + am__flags=$$MFLAGS; \ + else \ ## Non-GNU make: we must rely on $(MAKEFLAGS). This is tricker and more ## brittle, but is the best we can do. - case $$MAKEFLAGS in \ + case $$MAKEFLAGS in \ ## If we run "make TESTS='snooze nap'", FreeBSD make will export MAKEFLAGS ## to " TESTS=foo\ nap", so that the simpler loop below (on word-splitted ## $$MAKEFLAGS) would see a "make flag" equal to "nap", and would wrongly ## misinterpret that as and indication that make is running in dry mode. ## This has already happened in practice. So we need this hack. - *\\[\ \ ]*) \ + *\\[\ \ ]*) \ ## Extra indirection with ${am__bs} required by FreeBSD 8.x make. ## Not sure why (so sorry for the cargo-cult programming here). - am__bs=\\; \ - am__flags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$am__bs$$am__bs[$$am__bs $$am__bs ]*//g"`;; \ - esac; \ + am__bs=\\; \ + am__flags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$am__bs$$am__bs[$$am__bs $$am__bs ]*//g"`;; \ + esac; \ + fi; \ + am__skip_next=no; \ + am__strip_trailopt () \ + { \ + am__flg=`printf '%s\n' "$$am__flg" | sed "s/$$1.*$$//"`; \ + }; \ + for am__flg in $$am__flags; do \ + if test $$am__skip_next = yes; then \ + am__skip_next=no; \ + continue; \ fi; \ - am__skip_next=no; \ - am__strip_trailopt () \ - { \ - am__flg=`printf '%s\n' "$$am__flg" | sed "s/$$1.*$$//"`; \ - }; \ - for am__flg in $$am__flags; do \ - if test $$am__skip_next = yes; then \ - am__skip_next=no; \ - continue; \ - fi; \ - case $$am__flg in \ - *=*|--*) continue;; \ + case $$am__flg in \ + *=*|--*) continue;; \ ## GNU make 3.83 has changed the format of $MFLAGS, and removed the space ## between an option and its argument (e.g., from "-I dir" to "-Idir"). ## So we need to handle both formats. ## TODO: we might need to handle similar other cases as well; but let's ## wait until the need arises. - -*I) am__strip_trailopt 'I'; am__skip_next=yes;; \ - -*I?*) am__strip_trailopt 'I';; \ - esac; \ - case $$am__flg in \ - *$$am__target_option*) am__has_opt=yes; break;; \ - esac; \ - done; \ - test $$am__has_opt = yes + -*I) am__strip_trailopt 'I'; am__skip_next=yes;; \ + -*I?*) am__strip_trailopt 'I';; \ + esac; \ + case $$am__flg in \ + *$$am__target_option*) am__has_opt=yes; break;; \ + esac; \ + 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,