automake-ng
[Top][All Lists]
Advanced

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

[Automake-NG] [PATCH 1/2] [ng] subdirs: prefer "make -C dir" over "cd di


From: Stefano Lattarini
Subject: [Automake-NG] [PATCH 1/2] [ng] subdirs: prefer "make -C dir" over "cd dir && make"
Date: Fri, 15 Jun 2012 16:04:10 +0200

* lib/am/subdirs.am ($(RECURSIVE_TARGETS), $(RECURSIVE_CLEAN_TARGETS)):
Prefer "$(MAKE) -C $$dir ..." over "($(am__cd) $$dir && $(MAKE) ...".
This allows us to remove a subshell invocation.

Signed-off-by: Stefano Lattarini <address@hidden>
---
 lib/am/subdirs.am |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/lib/am/subdirs.am b/lib/am/subdirs.am
index 9ee49ce..5dfe8ca 100644
--- a/lib/am/subdirs.am
+++ b/lib/am/subdirs.am
@@ -58,8 +58,7 @@ $(RECURSIVE_TARGETS) $(RECURSIVE_CLEAN_TARGETS):
          else \
            local_target="$$target"; \
          fi; \
-         ($(am__cd) $$subdir && $(MAKE) $$local_target) \
-         || eval $$failcom; \
+         $(MAKE) -C "$$subdir" $$local_target || eval $$failcom; \
        done; \
        if test "$$dot_seen" = "no"; then \
          $(MAKE) "$$target-am" || exit 1; \
-- 
1.7.9.5




reply via email to

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