public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Sam Ravnborg <sam@ravnborg.org>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Finn Thain <fthain@telegraphics.com.au>,
	Rob Landley <rob@landley.net>,
	LKML <linux-kernel@vger.kernel.org>,
	Linux/m68k <linux-m68k@vger.kernel.org>
Subject: Re: [PATCH] Make m68k cross compile like every other architecture.
Date: Fri, 12 Oct 2007 12:21:24 +0200	[thread overview]
Message-ID: <20071012102124.GA18959@uranus.ravnborg.org> (raw)
In-Reply-To: <Pine.LNX.4.64.0710121046020.7335@anakin>

On Fri, Oct 12, 2007 at 10:51:00AM +0200, Geert Uytterhoeven wrote:
> On Fri, 12 Oct 2007, Finn Thain wrote:
> > > If your cross-compiler is called differently than the default on in 
> > > arch/*/Makefile,
> > 
> > Part of the problem is that there is no compelling default. The name of 
> > the cross-compiler can vary depending on the chosen executable prefix or 
> > the chosen target tuple.
> > 
> > Let's say I create new cross toolchains for both m68k and powerpc. I use 
> > the "m68k-linux-gnu" to follow the m68k default, but let's assume powerpc 
> > users prefer their default "powerpc-linux" so I follow that too. The 
> > result is that I now have gcc's -B option working (or not working) in 
> > suprising ways too.
> > 
> > Uniformity is more helpful downstream than a different arbitrary default 
> > for each architecture. Debian should patch their default into their kernel 
> > source packages if they've standardised on cross compiler prefixes.
> > 
> > > what's the problem with calling?
> > > 
> > >     make ARCH=myarch CROSS_COMPILE=my-cross-compile-prefx-
> > > 
> > > This has been working for +10 years on all non-ia32 platforms I ever worked on.
> > 
> > But there is no problem with calling that (?). Rob's patch doesn't change 
> > this.
> 
> But it makes life harder for the people who use it daily.
> 
> If the consensus is to not provide default cross compiler prefixes in
> arch/*/Makefile, fine for me, but IFF it's done for all architectures
> (i.e. check with the blackfin, h8300, mips, parisc, and xtensa people
> first).

Test if the expected gcc is available and set CROSS_COMPILE
if it is present. Otherwise do not touch CROSS_COMPILE.

m68kgcc := $(shell "test if m68k-gcc is present and echo 'y' if so")
ifeq ($(m68kgcc,y)
        CROSS_COMPILE := m68k-foo
endif

Then everyone is happy.
parisc does something similar.

	Sam

  reply	other threads:[~2007-10-12 10:20 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-10 22:22 [PATCH] Make m68k cross compile like every other architecture Rob Landley
2007-10-11  7:25 ` Geert Uytterhoeven
2007-10-11 11:31   ` Rob Landley
2007-10-11 11:39   ` Sam Ravnborg
2007-10-11 12:46     ` Geert Uytterhoeven
2007-10-11 13:27       ` Rob Landley
2007-10-11 13:52         ` Paul Mundt
2007-10-11 15:12         ` Geert Uytterhoeven
2007-10-11 16:26           ` Finn Thain
2007-10-11 21:14             ` Rob Landley
2007-10-12  6:51               ` Geert Uytterhoeven
2007-10-12  7:54                 ` Finn Thain
2007-10-12  8:51                   ` Geert Uytterhoeven
2007-10-12 10:21                     ` Sam Ravnborg [this message]
2007-10-15 20:25                       ` Geert Uytterhoeven
2007-10-16  0:31                         ` Rob Landley
2007-10-16  4:15                           ` Sam Ravnborg
2007-10-18 21:14                         ` Sam Ravnborg
2007-10-19  6:38                           ` Rob Landley
2007-10-19 15:10                             ` Sam Ravnborg
2007-10-11 16:24       ` Sam Ravnborg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20071012102124.GA18959@uranus.ravnborg.org \
    --to=sam@ravnborg.org \
    --cc=fthain@telegraphics.com.au \
    --cc=geert@linux-m68k.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-m68k@vger.kernel.org \
    --cc=rob@landley.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox