# [PATCH] unexpected Make output (e.g. from --debug) causes build failure

2 messages from 2007-09-25 to 2007-09-25. Participants: Jim Meyering, David Kastrup.
Thread: https://gitlist.dev/t/10007

## Jim Meyering, 2007-09-25 06:42

Subject: [PATCH] unexpected Make output (e.g. from --debug) causes build failure
Message-ID: <877imftfef.fsf@rho.meyering.net>
URL: https://gitlist.dev/e/877imftfef.fsf%40rho.meyering.net

```
Without this, the extra output produced e.g., by "make --debug"
would go into $INSTLIBDIR and then cause the sed command to fail.

Signed-off-by: Jim Meyering <jim@meyering.net>
---
 Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/Makefile b/Makefile
index 0055eef..97ce687 100644
--- a/Makefile
+++ b/Makefile
@@ -805,7 +805,7 @@ perl/perl.mak: GIT-CFLAGS

 $(patsubst %.perl,%,$(SCRIPT_PERL)): % : %.perl
 	$(QUIET_GEN)$(RM) $@ $@+ && \
-	INSTLIBDIR=`$(MAKE) -C perl -s --no-print-directory instlibdir` && \
+	INSTLIBDIR=`MAKEFLAGS= $(MAKE) -C perl -s --no-print-directory instlibdir` && \
 	sed -e '1{' \
 	    -e '	s|#!.*perl|#!$(PERL_PATH_SQ)|' \
 	    -e '	h' \
--
1.5.3.2.99.ge4b2-dirty

```

## David Kastrup, 2007-09-25 07:59

Subject: Re: [PATCH] unexpected Make output (e.g. from --debug) causes build failure
Message-ID: <86zlzbrx9a.fsf@lola.quinscape.zz>
URL: https://gitlist.dev/e/86zlzbrx9a.fsf%40lola.quinscape.zz
In-Reply-To: <877imftfef.fsf@rho.meyering.net>

```
Jim Meyering <jim@meyering.net> writes:

> Without this, the extra output produced e.g., by "make --debug"
> would go into $INSTLIBDIR and then cause the sed command to fail.
>
> Signed-off-by: Jim Meyering <jim@meyering.net>
> ---
>  Makefile |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index 0055eef..97ce687 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -805,7 +805,7 @@ perl/perl.mak: GIT-CFLAGS
>
>  $(patsubst %.perl,%,$(SCRIPT_PERL)): % : %.perl
>  	$(QUIET_GEN)$(RM) $@ $@+ && \
> -	INSTLIBDIR=`$(MAKE) -C perl -s --no-print-directory instlibdir` && \
> +	INSTLIBDIR=`MAKEFLAGS= $(MAKE) -C perl -s --no-print-directory instlibdir` && \
>  	sed -e '1{' \
>  	    -e '	s|#!.*perl|#!$(PERL_PATH_SQ)|' \
>  	    -e '	h' \
> --
> 1.5.3.2.99.ge4b2-dirty

Does this work with "make -n" ?

-- 
David Kastrup

```
