linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* Makefile check for older binutils broken?
@ 2005-10-26 13:36 Marcelo Tosatti
  2005-10-26 19:59 ` Andreas Schwab
  2005-10-26 22:02 ` Tom Rini
  0 siblings, 2 replies; 8+ messages in thread
From: Marcelo Tosatti @ 2005-10-26 13:36 UTC (permalink / raw)
  To: linuxppc-dev


Hi,

While trying to compile 2.6.14-rc4 on my Pegasos (running Debian unstable):

make[2]: Entering directory `/home/marcelo/8xx/linux-2.6.14-rc4'
*** 2.6 kernels no longer build correctly with old versions of binutils.
*** Please upgrade your binutils to 2.12.1 or newer
make[2]: *** [checkbin] Error 1

Even though Debian uses a recent version of binutils:

GNU assembler 2.16.1 Debian GNU/Linux
Copyright 2005 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License.  This program has absolutely no warranty.
This assembler was configured for a target of `powerpc-linux-gnu'.

The return value of the verification command is 0:

marcelo@pegasos:~$ /bin/echo dssall | as -many -o /tmp/output.as >/dev/null 2>&1
marcelo@pegasos:~$ echo $?
0

So somehow the verification inside the Makefile fails (maybe a make or shell 
bug? not sure).

Anyway, surrounding the verification command around an eval expression
does the trick correcting the situation. Is it any good? 

I'm not sure what to expect from older binutils versions as I don't have
any around at the moment for testing.

diff --git a/arch/ppc/Makefile b/arch/ppc/Makefile
index 0432a25..cdd9250 100644
--- a/arch/ppc/Makefile
+++ b/arch/ppc/Makefile
@@ -126,7 +126,7 @@ checkbin:
 			false; \
 		fi ; \
 	fi
-	@if ! /bin/echo dssall | $(AS) -many -o $(TOUT) >/dev/null 2>&1 ; then \
+	@if ! [[ "/bin/echo dssall | $(AS) -many -o $(TOUT) >/dev/null 2>&1" ]] ; then \
 		echo -n '*** ${VERSION}.${PATCHLEVEL} kernels no longer build ' ; \
 		echo 'correctly with old versions of binutils.' ; \
 		echo '*** Please upgrade your binutils to 2.12.1 or newer' ; \

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: Makefile check for older binutils broken?
  2005-10-26 19:59 ` Andreas Schwab
@ 2005-10-26 16:08   ` Marcelo Tosatti
  0 siblings, 0 replies; 8+ messages in thread
From: Marcelo Tosatti @ 2005-10-26 16:08 UTC (permalink / raw)
  To: Andreas Schwab; +Cc: linuxppc-dev

On Wed, Oct 26, 2005 at 09:59:20PM +0200, Andreas Schwab wrote:
> Marcelo Tosatti <marcelo.tosatti@cyclades.com> writes:
> 
> > Anyway, surrounding the verification command around an eval expression
> > does the trick correcting the situation. Is it any good? 
> 
> Not at all.  You have effectively disabled the check completely.
> 
> > diff --git a/arch/ppc/Makefile b/arch/ppc/Makefile
> > index 0432a25..cdd9250 100644
> > --- a/arch/ppc/Makefile
> > +++ b/arch/ppc/Makefile
> > @@ -126,7 +126,7 @@ checkbin:
> >  			false; \
> >  		fi ; \
> >  	fi
> > -	@if ! /bin/echo dssall | $(AS) -many -o $(TOUT) >/dev/null 2>&1 ; then \
> > +	@if ! [[ "/bin/echo dssall | $(AS) -many -o $(TOUT) >/dev/null 2>&1" ]] ; then \
> 
> A non-empty string is always true.

Doh - it seemed too easy. I'll go search for some clue (and buy a shell book).

I bet either Make or bash is screwing up.

Thanks

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Makefile check for older binutils broken?
  2005-10-26 13:36 Makefile check for older binutils broken? Marcelo Tosatti
@ 2005-10-26 19:59 ` Andreas Schwab
  2005-10-26 16:08   ` Marcelo Tosatti
  2005-10-26 22:02 ` Tom Rini
  1 sibling, 1 reply; 8+ messages in thread
From: Andreas Schwab @ 2005-10-26 19:59 UTC (permalink / raw)
  To: Marcelo Tosatti; +Cc: linuxppc-dev

Marcelo Tosatti <marcelo.tosatti@cyclades.com> writes:

> Anyway, surrounding the verification command around an eval expression
> does the trick correcting the situation. Is it any good? 

Not at all.  You have effectively disabled the check completely.

> diff --git a/arch/ppc/Makefile b/arch/ppc/Makefile
> index 0432a25..cdd9250 100644
> --- a/arch/ppc/Makefile
> +++ b/arch/ppc/Makefile
> @@ -126,7 +126,7 @@ checkbin:
>  			false; \
>  		fi ; \
>  	fi
> -	@if ! /bin/echo dssall | $(AS) -many -o $(TOUT) >/dev/null 2>&1 ; then \
> +	@if ! [[ "/bin/echo dssall | $(AS) -many -o $(TOUT) >/dev/null 2>&1" ]] ; then \

A non-empty string is always true.

Andreas.

-- 
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Makefile check for older binutils broken?
  2005-10-26 13:36 Makefile check for older binutils broken? Marcelo Tosatti
  2005-10-26 19:59 ` Andreas Schwab
@ 2005-10-26 22:02 ` Tom Rini
  2005-10-28  8:52   ` Marcelo Tosatti
  1 sibling, 1 reply; 8+ messages in thread
From: Tom Rini @ 2005-10-26 22:02 UTC (permalink / raw)
  To: Marcelo Tosatti; +Cc: linuxppc-dev

On Wed, Oct 26, 2005 at 11:36:48AM -0200, Marcelo Tosatti wrote:
> 
> Hi,
> 
> While trying to compile 2.6.14-rc4 on my Pegasos (running Debian unstable):
> 
> make[2]: Entering directory `/home/marcelo/8xx/linux-2.6.14-rc4'
> *** 2.6 kernels no longer build correctly with old versions of binutils.
> *** Please upgrade your binutils to 2.12.1 or newer
> make[2]: *** [checkbin] Error 1

What's your CONFIG_SHELL set to?

[snip]
> marcelo@pegasos:~$ /bin/echo dssall | as -many -o /tmp/output.as >/dev/null 2>&1
> marcelo@pegasos:~$ echo $?

What about if you run the whole test on shell (if ...), does it work there? 
What shell are you running?

-- 
Tom Rini
http://gate.crashing.org/~trini/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Makefile check for older binutils broken?
  2005-10-26 22:02 ` Tom Rini
@ 2005-10-28  8:52   ` Marcelo Tosatti
  2005-10-28 16:10     ` Tom Rini
  0 siblings, 1 reply; 8+ messages in thread
From: Marcelo Tosatti @ 2005-10-28  8:52 UTC (permalink / raw)
  To: Tom Rini; +Cc: linuxppc-dev

On Wed, Oct 26, 2005 at 03:02:05PM -0700, Tom Rini wrote:
> On Wed, Oct 26, 2005 at 11:36:48AM -0200, Marcelo Tosatti wrote:
> > 
> > Hi,
> > 
> > While trying to compile 2.6.14-rc4 on my Pegasos (running Debian unstable):
> > 
> > make[2]: Entering directory `/home/marcelo/8xx/linux-2.6.14-rc4'
> > *** 2.6 kernels no longer build correctly with old versions of binutils.
> > *** Please upgrade your binutils to 2.12.1 or newer
> > make[2]: *** [checkbin] Error 1
> 
> What's your CONFIG_SHELL set to?

bash

> 
> [snip]
> > marcelo@pegasos:~$ /bin/echo dssall | as -many -o /tmp/output.as >/dev/null 2>&1
> > marcelo@pegasos:~$ echo $?
> 
> What about if you run the whole test on shell (if ...), does it work there? 
> What shell are you running?

Yep, that does the trick. Is it good now?


--- arch/ppc/Makefile.orig	2005-10-26 13:04:43.000000000 -0500
+++ arch/ppc/Makefile	2005-10-28 08:43:22.153202928 -0500
@@ -132,12 +132,12 @@
 			false; \
 		fi ; \
 	fi
-	@if ! [[ "/bin/echo dssall | $(AS) -many -o $(TOUT) >/dev/null 2>&1" ]]; then \
+	@(if ! /bin/echo dssall | $(AS) -many -o $(TOUT) >/dev/null 2>&1 ; then\
 		echo -n '*** ${VERSION}.${PATCHLEVEL} kernels no longer build ' ; \
 		echo 'correctly with old versions of binutils.' ; \
 		echo '*** Please upgrade your binutils to 2.12.1 or newer' ; \
 		false ; \
-	fi
+	fi)
 
 CLEAN_FILES += $(TOUT)
 

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Makefile check for older binutils broken?
  2005-10-28 16:10     ` Tom Rini
@ 2005-10-28 13:14       ` Marcelo Tosatti
  2005-11-01 16:33       ` Marcelo Tosatti
  1 sibling, 0 replies; 8+ messages in thread
From: Marcelo Tosatti @ 2005-10-28 13:14 UTC (permalink / raw)
  To: Tom Rini; +Cc: linuxppc-dev

On Fri, Oct 28, 2005 at 09:10:54AM -0700, Tom Rini wrote:
> On Fri, Oct 28, 2005 at 06:52:24AM -0200, Marcelo Tosatti wrote:
> > On Wed, Oct 26, 2005 at 03:02:05PM -0700, Tom Rini wrote:
> > > On Wed, Oct 26, 2005 at 11:36:48AM -0200, Marcelo Tosatti wrote:
> > > > 
> > > > Hi,
> > > > 
> > > > While trying to compile 2.6.14-rc4 on my Pegasos (running Debian unstable):
> > > > 
> > > > make[2]: Entering directory `/home/marcelo/8xx/linux-2.6.14-rc4'
> > > > *** 2.6 kernels no longer build correctly with old versions of binutils.
> > > > *** Please upgrade your binutils to 2.12.1 or newer
> > > > make[2]: *** [checkbin] Error 1
> > > 
> > > What's your CONFIG_SHELL set to?
> > 
> > bash
> > 
> > > 
> > > [snip]
> > > > marcelo@pegasos:~$ /bin/echo dssall | as -many -o /tmp/output.as >/dev/null 2>&1
> > > > marcelo@pegasos:~$ echo $?
> > > 
> > > What about if you run the whole test on shell (if ...), does it work there? 
> > > What shell are you running?
> > 
> > Yep, that does the trick. Is it good now?
> 
> Er, that's odd.  I was using writing parens, not shell parens :)   Can
> you test the failure case here by changing dssall to garbage?  Also,
> that's not a clean patch, but vs your last one that wasn't valid.

Yes thats bullshit (it does not work actually).

Give me some time figure out whats going to avoid wasting your time.

Sorry.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Makefile check for older binutils broken?
  2005-10-28  8:52   ` Marcelo Tosatti
@ 2005-10-28 16:10     ` Tom Rini
  2005-10-28 13:14       ` Marcelo Tosatti
  2005-11-01 16:33       ` Marcelo Tosatti
  0 siblings, 2 replies; 8+ messages in thread
From: Tom Rini @ 2005-10-28 16:10 UTC (permalink / raw)
  To: Marcelo Tosatti; +Cc: linuxppc-dev

On Fri, Oct 28, 2005 at 06:52:24AM -0200, Marcelo Tosatti wrote:
> On Wed, Oct 26, 2005 at 03:02:05PM -0700, Tom Rini wrote:
> > On Wed, Oct 26, 2005 at 11:36:48AM -0200, Marcelo Tosatti wrote:
> > > 
> > > Hi,
> > > 
> > > While trying to compile 2.6.14-rc4 on my Pegasos (running Debian unstable):
> > > 
> > > make[2]: Entering directory `/home/marcelo/8xx/linux-2.6.14-rc4'
> > > *** 2.6 kernels no longer build correctly with old versions of binutils.
> > > *** Please upgrade your binutils to 2.12.1 or newer
> > > make[2]: *** [checkbin] Error 1
> > 
> > What's your CONFIG_SHELL set to?
> 
> bash
> 
> > 
> > [snip]
> > > marcelo@pegasos:~$ /bin/echo dssall | as -many -o /tmp/output.as >/dev/null 2>&1
> > > marcelo@pegasos:~$ echo $?
> > 
> > What about if you run the whole test on shell (if ...), does it work there? 
> > What shell are you running?
> 
> Yep, that does the trick. Is it good now?

Er, that's odd.  I was using writing parens, not shell parens :)   Can
you test the failure case here by changing dssall to garbage?  Also,
that's not a clean patch, but vs your last one that wasn't valid.

-- 
Tom Rini
http://gate.crashing.org/~trini/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Makefile check for older binutils broken?
  2005-10-28 16:10     ` Tom Rini
  2005-10-28 13:14       ` Marcelo Tosatti
@ 2005-11-01 16:33       ` Marcelo Tosatti
  1 sibling, 0 replies; 8+ messages in thread
From: Marcelo Tosatti @ 2005-11-01 16:33 UTC (permalink / raw)
  To: Tom Rini; +Cc: linuxppc-dev


> > Yep, that does the trick. Is it good now?
> 
> Er, that's odd.  I was using writing parens, not shell parens :)   Can
> you test the failure case here by changing dssall to garbage?  Also,
> that's not a clean patch, but vs your last one that wasn't valid.

Problem is specific to invocation of "make" inside a (particular) Makefile.

Again, sorry for you wasting your time.

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2005-11-01 21:49 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-10-26 13:36 Makefile check for older binutils broken? Marcelo Tosatti
2005-10-26 19:59 ` Andreas Schwab
2005-10-26 16:08   ` Marcelo Tosatti
2005-10-26 22:02 ` Tom Rini
2005-10-28  8:52   ` Marcelo Tosatti
2005-10-28 16:10     ` Tom Rini
2005-10-28 13:14       ` Marcelo Tosatti
2005-11-01 16:33       ` Marcelo Tosatti

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).