RE: [U-Boot-Users] PPC as host

-----Original Message----- From: u-boot-users-admin@lists.sourceforge.net [mailto:u-boot-users-admin@lists.sourceforge.net] On Behalf Of Richard Klingler Sent: Monday, October 25, 2004 11:02 AM To: u-boot-users Subject: [U-Boot-Users] PPC as host
Evening (o;
Apparently no one uses Linux PPC as host? So no one ever had problems cross-compiling u-boot for another target then (o;
In the top Makefile we have:
ifndef CROSS_COMPILE ifeq ($(HOSTARCH),ppc) CROSS_COMPILE = else ....
which always picks up the host ppc compiler regardless what ARCH you have defined for your board...
Since I don't use PPC as target someone might come up with a better idea then:
ifeq ($(HOSTARCH,$(ARCH)) CROSS_COMPILE = else ...
In my case it is YDL-3.0.1 PPC Linux running on G4. This doesn't happen on OSX since it is solved in the top config.mk file.
best regards rick
The Makefile makes its best guess about cross compilers given very limited information. It may guess wrong, as you are seeing.
For more information, see: http://www.denx.de/twiki/bin/view/DULG/ELDKUsage
<blockquote> * After the installation utility completes, export the CROSS_COMPILE variable:
bash$ export CROSS_COMPILE=ppc_8xx-
TIP The trailing '-' character in the CROSS_COMPILE variable value is optional and has no effect on the cross tools behavior. </blockquote>
A related hint (if you don't like the export hint) is in http://www.denx.de/twiki/bin/view/DULG/LinuxConfiguration
<blockquote> If your host computer is not the same architecture as the target system, and if you got your kernel tree from kernel.org or other "official" sources, then you may have to supply an architecture override and a cross compiler definition. The most reliable way to do this is to specify them on the make command line as part of the make command. If this is the case, use for example:
bash$ make ARCH=ppc CROSS_COMPILE=ppc_8xx- </blockquote>
gvb
****************************************** The following messages are brought to you by the Lawyers' League of IdioSpeak:
****************************************** The information contained in, or attached to, this e-mail, may contain confidential information and is intended solely for the use of the individual or entity to whom they are addressed and may be subject to legal privilege. If you have received this e-mail in error you should notify the sender immediately by reply e-mail, delete the message from your system and notify your system manager. Please do not copy it for any purpose, or disclose its contents to any other person. The views or opinions presented in this e-mail are solely those of the author and do not necessarily represent those of the company. The recipient should check this e-mail and any attachments for the presence of viruses. The company accepts no liability for any damage caused, directly or indirectly, by any virus transmitted in this email. ******************************************

The Makefile makes its best guess about cross compilers given very limited information. It may guess wrong, as you are seeing.
In this case it doesn't even 'guess' when cross-compiling for example with target bfin-elf- (o;
For more information, see: http://www.denx.de/twiki/bin/view/DULG/ELDKUsage
<blockquote> * After the installation utility completes, export the CROSS_COMPILE variable:
bash$ export CROSS_COMPILE=ppc_8xx-
I'm aware of CROSS_COMPILE though admit never read ELDK manuals since I just don't do PPC development (o;
Just mentioned that there would be an easy fix for cross-compiling for NON-PPC platforms...but if it's written by Wolfgang..so it should be (o;
rick

In message 1098724833.1186.15.camel@imac you wrote:
The Makefile makes its best guess about cross compilers given very limited information. It may guess wrong, as you are seeing.
In this case it doesn't even 'guess' when cross-compiling for example with target bfin-elf- (o;
It doesn't guess because you can provide correct information through the documented ways. I think the make just does what you tell it to do...
I'm aware of CROSS_COMPILE though admit never read ELDK manuals since I just don't do PPC development (o;
First, the quoted document (DULG) is more than just the ELDK documentation. It's the manual, and FAQ and some more about U-Boot and Linux und the rest of the world. You are expected to read it ;-)
Second, the ELDK is more than just PPC, it also covers ARM and MIPS.
Just mentioned that there would be an easy fix for cross-compiling for NON-PPC platforms...but if it's written by Wolfgang..so it should be (o;
Not only by me - many people contributed one way or another (and if only by asking FAQ's ;-)
Best regards,
Wolfgang Denk
participants (3)
-
Richard Klingler
-
VanBaren, Gerald (AGRE)
-
Wolfgang Denk