[U-Boot] Building U-Boot under Ubuntu 8.10

I'm trying to build U-boot (2009.03) under Ubuntu 8.10.
I get the following error when building:
"as: unrecognized option '-mppc'" "make[1]: *** [hello_world.o] Error 2" "make[1]: Leaving directory '/opt/u-boot/examples'" "make: *** [examples] Error 2"
I've built the same U-Boot source code on a windows XP machine with colinux.
Can anyone provide insight into how I can fix this?
Thanks.
Christopher M. Fairfax Sr. Software Engineer Rockwell Collins +1 540-428-3344 +1 540-428-3301 cmfairfa@rockwellcollins.com This message contains PRIVILEGED AND PROPRIETARY INFORMATION intended solely for the use of the addressee(s) named above. Any disclosure, distribution, copying or use of the information by others is strictly prohibited. If you have received this message in error, please advise the sender by immediate reply and delete the original message. Thank you.

what is the host architecture x86 or ppc?
If its x86 you need a cross compiler.
- k
On Jun 10, 2009, at 5:37 PM, cmfairfa@rockwellcollins.com wrote:
I'm trying to build U-boot (2009.03) under Ubuntu 8.10.
I get the following error when building:
"as: unrecognized option '-mppc'" "make[1]: *** [hello_world.o] Error 2" "make[1]: Leaving directory '/opt/u-boot/examples'" "make: *** [examples] Error 2"
I've built the same U-Boot source code on a windows XP machine with colinux.
Can anyone provide insight into how I can fix this?
Thanks.
Christopher M. Fairfax Sr. Software Engineer Rockwell Collins +1 540-428-3344 +1 540-428-3301 cmfairfa@rockwellcollins.com This message contains PRIVILEGED AND PROPRIETARY INFORMATION intended solely for the use of the addressee(s) named above. Any disclosure, distribution, copying or use of the information by others is strictly prohibited. If you have received this message in error, please advise the sender by immediate reply and delete the original message. Thank you. _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot

Kumar, The host is x86.
Sorry. I should've mentioned that I installed the ELDK 4.2 for ppc-linux-x86. I"m using powerpc-linux-gcc for cross-compiling.
Thanks.
Christopher M. Fairfax Sr. Software Engineer Rockwell Collins +1 540-428-3344 +1 540-428-3301 cmfairfa@rockwellcollins.com This message contains PRIVILEGED AND PROPRIETARY INFORMATION intended solely for the use of the addressee(s) named above. Any disclosure, distribution, copying or use of the information by others is strictly prohibited. If you have received this message in error, please advise the sender by immediate reply and delete the original message. Thank you.
Kumar Gala galak@kernel.crashing.org 06/10/2009 07:15 PM
To cmfairfa@rockwellcollins.com cc u-boot@lists.denx.de Subject Re: [U-Boot] Building U-Boot under Ubuntu 8.10
what is the host architecture x86 or ppc?
If its x86 you need a cross compiler.
- k
On Jun 10, 2009, at 5:37 PM, cmfairfa@rockwellcollins.com wrote:
I'm trying to build U-boot (2009.03) under Ubuntu 8.10.
I get the following error when building:
"as: unrecognized option '-mppc'" "make[1]: *** [hello_world.o] Error 2" "make[1]: Leaving directory '/opt/u-boot/examples'" "make: *** [examples] Error 2"
I've built the same U-Boot source code on a windows XP machine with colinux.
Can anyone provide insight into how I can fix this?
Thanks.
Christopher M. Fairfax Sr. Software Engineer Rockwell Collins +1 540-428-3344 +1 540-428-3301 cmfairfa@rockwellcollins.com This message contains PRIVILEGED AND PROPRIETARY INFORMATION intended solely for the use of the addressee(s) named above. Any disclosure, distribution, copying or use of the information by others is strictly prohibited. If you have received this message in error, please advise the sender by immediate reply and delete the original message. Thank you. _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot

at what point in the build do you get this error?
- k
On Jun 10, 2009, at 7:03 PM, cmfairfa@rockwellcollins.com wrote:
Kumar, The host is x86.
Sorry. I should've mentioned that I installed the ELDK 4.2 for ppc- linux-x86. I"m using powerpc-linux-gcc for cross-compiling.
Thanks.
Christopher M. Fairfax Sr. Software Engineer Rockwell Collins +1 540-428-3344 +1 540-428-3301 cmfairfa@rockwellcollins.com This message contains PRIVILEGED AND PROPRIETARY INFORMATION intended solely for the use of the addressee(s) named above. Any disclosure, distribution, copying or use of the information by others is strictly prohibited. If you have received this message in error, please advise the sender by immediate reply and delete the original message. Thank you.
Kumar Gala galak@kernel.crashing.org 06/10/2009 07:15 PM
To cmfairfa@rockwellcollins.com cc u-boot@lists.denx.de Subject Re: [U-Boot] Building U-Boot under Ubuntu 8.10
what is the host architecture x86 or ppc?
If its x86 you need a cross compiler.
- k
On Jun 10, 2009, at 5:37 PM, cmfairfa@rockwellcollins.com wrote:
I'm trying to build U-boot (2009.03) under Ubuntu 8.10.
I get the following error when building:
"as: unrecognized option '-mppc'" "make[1]: *** [hello_world.o] Error 2" "make[1]: Leaving directory '/opt/u-boot/examples'" "make: *** [examples] Error 2"
I've built the same U-Boot source code on a windows XP machine with colinux.
Can anyone provide insight into how I can fix this?
Thanks.
Christopher M. Fairfax Sr. Software Engineer Rockwell Collins +1 540-428-3344 +1 540-428-3301 cmfairfa@rockwellcollins.com This message contains PRIVILEGED AND PROPRIETARY INFORMATION
intended
solely for the use of the addressee(s) named above. Any disclosure, distribution, copying or use of the information by others is
strictly
prohibited. If you have received this message in error, please advise the sender by immediate reply and delete the original message. Thank you. _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot

Dear cmfairfa@rockwellcollins.com,
In message OF8E7A40DC.A763CF10-ON852575D2.00002464-852575D2.00005580@rockwellcollins.com you wrote:
Sorry. I should've mentioned that I installed the ELDK 4.2 for ppc-linux-x86. I"m using powerpc-linux-gcc for cross-compiling.
Did you also enable it by adding it to your PATH and by setting and exporting the ARCH and CROSS_COMPILE variables?
My guess is that you forgot to set and export CROSS_COMPILE ...
Best regards,
Wolfgang Denk

ARCH and CROSS_COMPILE are set and exported (ARCH=ppc, CROSS_COMPILE=powerpc-linux-)
The problem appears to be with the assembler (as). The as: unrecognized option "-mppc" is what's killing me.
I get through the compilation of "make -C tools all"
The error happens during compilation of hello_world in "make -C examples all"
I'm going to try to use ELDK 4.1 instead of 4.2. The ELDK 4.1_AMCC iso worked on my Windows host with colinux.
Thanks.
Christopher M. Fairfax Sr. Software Engineer Rockwell Collins +1 540-428-3344 +1 540-428-3301 cmfairfa@rockwellcollins.com This message contains PRIVILEGED AND PROPRIETARY INFORMATION intended solely for the use of the addressee(s) named above. Any disclosure, distribution, copying or use of the information by others is strictly prohibited. If you have received this message in error, please advise the sender by immediate reply and delete the original message. Thank you.
Wolfgang Denk wd@denx.de 06/11/2009 03:58 AM
To cmfairfa@rockwellcollins.com cc Kumar Gala galak@kernel.crashing.org, u-boot@lists.denx.de Subject Re: [U-Boot] Building U-Boot under Ubuntu 8.10
Dear cmfairfa@rockwellcollins.com,
In message OF8E7A40DC.A763CF10-ON852575D2.00002464-852575D2.00005580@rockwellcollins.com you wrote:
Sorry. I should've mentioned that I installed the ELDK 4.2 for ppc-linux-x86. I"m using powerpc-linux-gcc for cross-compiling.
Did you also enable it by adding it to your PATH and by setting and exporting the ARCH and CROSS_COMPILE variables?
My guess is that you forgot to set and export CROSS_COMPILE ...
Best regards,
Wolfgang Denk

Dear cmfairfa@rockwellcollins.com,
In message OF8FD4848E.6EC6CC4F-ON852575D2.004C617A-852575D2.004D5A7B@rockwellcollins.com you wrote:
ARCH and CROSS_COMPILE are set and exported (ARCH=ppc, CROSS_COMPILE=powerpc-linux-)
...which is plain wrong. "powerpc-linux-" is NOIT a legal setting for CROSS_COMPILE.
Please RTFM.
Best regards,
Wolfgang Denk

On Thu, 2009-06-11 at 17:04 +0200, Wolfgang Denk wrote:
Dear cmfairfa@rockwellcollins.com,
In message OF8FD4848E.6EC6CC4F-ON852575D2.004C617A-852575D2.004D5A7B@rockwellcollins.com you wrote:
ARCH and CROSS_COMPILE are set and exported (ARCH=ppc, CROSS_COMPILE=powerpc-linux-)
...which is plain wrong. "powerpc-linux-" is NOIT a legal setting for CROSS_COMPILE.
why is that ? it's just a prefix to whatever you compiled the toolkit to use no?

Dear Kenneth Johansson,
In message 1244733541.4182.81.camel@localhost.localdomain you wrote:
ARCH and CROSS_COMPILE are set and exported (ARCH=ppc, CROSS_COMPILE=powerpc-linux-)
...which is plain wrong. "powerpc-linux-" is NOIT a legal setting for CROSS_COMPILE.
why is that ?
Because that's the way how the ELDK is designed.
it's just a prefix to whatever you compiled the toolkit to use no?
At least with ELDK, which supports a wide range pf processor fami- lies, it also has to carry information about which CPU architecture you are targeting for.
ELDK uses two methonds to find out what you might want to do: it checks the content of CROSS_COMPILE, and it checks the name you use to run the tools.
If you set CROSS_COMPILE=powerpc-linux- and run "ppc_8xx-gcc" there is still some indication that, for example, you are on a system which has no FPU and only short cache lines. But with above usage, no such information is available.
All this (including the legal values to be used for CROSS_COMPILE) is described in the manual; please RTFM for details.
Ignoring the documentation and doing non-standard things is asking for trouble.
Best regards,
Wolfgang Denk

On Thu, 2009-06-11 at 17:59 +0200, Wolfgang Denk wrote:
Dear Kenneth Johansson,
In message 1244733541.4182.81.camel@localhost.localdomain you wrote:
ARCH and CROSS_COMPILE are set and exported (ARCH=ppc, CROSS_COMPILE=powerpc-linux-)
...which is plain wrong. "powerpc-linux-" is NOIT a legal setting for CROSS_COMPILE.
why is that ?
Because that's the way how the ELDK is designed.
aaha I missed that he used ELDK never used that myself. I thought this was u-boot specific and got a bit confused.
But if ELDK uses wrapper scripts around the real binaries that checks certain variables it makes more sense.

Dear Kenneth Johansson,
In message 1244736946.4182.94.camel@localhost.localdomain you wrote:
But if ELDK uses wrapper scripts around the real binaries that checks certain variables it makes more sense.
It's not wrapper scripts but the binaries itself, but the effect is the same.
Best regards,
Wolfgang Denk

Hi Wolfgang,
Wolfgang Denk wrote:
Dear cmfairfa@rockwellcollins.com,
In message OF8FD4848E.6EC6CC4F-ON852575D2.004C617A-852575D2.004D5A7B@rockwellcollins.com you wrote:
ARCH and CROSS_COMPILE are set and exported (ARCH=ppc, CROSS_COMPILE=powerpc-linux-)
...which is plain wrong. "powerpc-linux-" is NOIT a legal setting for CROSS_COMPILE.
Please RTFM.
Best regards,
Wolfgang Denk
Based on my limited understanding, it seems this should be a valid prefix. If you have a moment, can you explain why it's not? In my installation everything seems to point to 'powerpc-linux-*':
bwarren@bwarren-bldsrv:/opt/tools/eldk_4.1/usr/bin$ ls -l p*-gcc -rwxr-xr-x 1 root root 99312 2007-01-19 17:00 powerpc-linux-gcc lrwxrwxrwx 1 root root 13 2008-12-04 15:22 ppc_4xxFP-gcc -> ppc-linux-gcc lrwxrwxrwx 1 root root 13 2008-12-04 15:21 ppc_4xx-gcc -> ppc-linux-gcc lrwxrwxrwx 1 root root 13 2008-12-04 15:23 ppc_6xx-gcc -> ppc-linux-gcc lrwxrwxrwx 1 root root 13 2008-12-04 15:24 ppc_74xx-gcc -> ppc-linux-gcc lrwxrwxrwx 1 root root 13 2008-12-04 15:23 ppc_7xx-gcc -> ppc-linux-gcc lrwxrwxrwx 1 root root 13 2008-12-04 15:23 ppc_82xx-gcc -> ppc-linux-gcc lrwxrwxrwx 1 root root 13 2008-12-04 15:26 ppc_85xx-gcc -> ppc-linux-gcc lrwxrwxrwx 1 root root 13 2008-12-04 15:27 ppc_8xx-gcc -> ppc-linux-gcc lrwxrwxrwx 1 root root 17 2008-12-04 15:21 ppc-linux-gcc -> powerpc-linux-gcc bwarren@bwarren-bldsrv:/opt/tools/eldk_4.1/usr/bin$ ls -l p*-as -rwxr-xr-x 1 root root 621872 2007-01-19 17:00 powerpc-linux-as lrwxrwxrwx 1 root root 12 2008-12-04 15:21 ppc_4xx-as -> ppc-linux-as lrwxrwxrwx 1 root root 12 2008-12-04 15:22 ppc_4xxFP-as -> ppc-linux-as lrwxrwxrwx 1 root root 12 2008-12-04 15:23 ppc_6xx-as -> ppc-linux-as lrwxrwxrwx 1 root root 12 2008-12-04 15:24 ppc_74xx-as -> ppc-linux-as lrwxrwxrwx 1 root root 12 2008-12-04 15:23 ppc_7xx-as -> ppc-linux-as lrwxrwxrwx 1 root root 12 2008-12-04 15:23 ppc_82xx-as -> ppc-linux-as lrwxrwxrwx 1 root root 12 2008-12-04 15:26 ppc_85xx-as -> ppc-linux-as lrwxrwxrwx 1 root root 12 2008-12-04 15:27 ppc_8xx-as -> ppc-linux-as lrwxrwxrwx 1 root root 16 2008-12-04 15:21 ppc-linux-as -> powerpc-linux-as bwarren@bwarren-bldsrv:/opt/tools/eldk_4.1/usr/bin$ ls -l p*-ld -rwxr-xr-x 1 root root 800652 2007-01-19 17:00 powerpc-linux-ld lrwxrwxrwx 1 root root 12 2008-12-04 15:22 ppc_4xxFP-ld -> ppc-linux-ld lrwxrwxrwx 1 root root 12 2008-12-04 15:21 ppc_4xx-ld -> ppc-linux-ld lrwxrwxrwx 1 root root 12 2008-12-04 15:23 ppc_6xx-ld -> ppc-linux-ld lrwxrwxrwx 1 root root 12 2008-12-04 15:24 ppc_74xx-ld -> ppc-linux-ld lrwxrwxrwx 1 root root 12 2008-12-04 15:23 ppc_7xx-ld -> ppc-linux-ld lrwxrwxrwx 1 root root 12 2008-12-04 15:23 ppc_82xx-ld -> ppc-linux-ld lrwxrwxrwx 1 root root 12 2008-12-04 15:26 ppc_85xx-ld -> ppc-linux-ld lrwxrwxrwx 1 root root 12 2008-12-04 15:27 ppc_8xx-ld -> ppc-linux-ld lrwxrwxrwx 1 root root 16 2008-12-04 15:21 ppc-linux-ld -> powerpc-linux-ld
etc.
regards, Ben

Dear Ben Warren,
In message 4A3136E6.9000006@gmail.com you wrote:
Based on my limited understanding, it seems this should be a valid prefix. If you have a moment, can you explain why it's not? In my installation everything seems to point to 'powerpc-linux-*':
I already explained this.
For details, please see the documentation; see especially section "3.6.A Table of possible values for $CROSS_COMPILE" at http://www.denx.de/wiki/DULG/ELDKUsage#CrossCompileValues
(note that this table does not mention all implications / effects of chosing CROSS_COMPILE - there are other compiler optiones affected as well, i. e. things like -mfloat-gprs, -mspe, -mabi, etc.).
Best regards,
Wolfgang Denk

Wolfgang Denk wrote:
Dear Ben Warren,
In message 4A3136E6.9000006@gmail.com you wrote:
Based on my limited understanding, it seems this should be a valid prefix. If you have a moment, can you explain why it's not? In my installation everything seems to point to 'powerpc-linux-*':
I already explained this.
For details, please see the documentation; see especially section "3.6.A Table of possible values for $CROSS_COMPILE" at http://www.denx.de/wiki/DULG/ELDKUsage#CrossCompileValues
(note that this table does not mention all implications / effects of chosing CROSS_COMPILE - there are other compiler optiones affected as well, i. e. things like -mfloat-gprs, -mspe, -mabi, etc.).
Best regards,
Wolfgang Denk
Got it. Sorry for the noise.
Ben
participants (5)
-
Ben Warren
-
cmfairfa@rockwellcollins.com
-
Kenneth Johansson
-
Kumar Gala
-
Wolfgang Denk