public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Murray Jensen <Murray.Jensen@csiro.au>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] [PPCBoot-users] Using gcc-3.4 to compile u-boot on powerpc
Date: Mon, 23 Jun 2003 12:06:53 +1000	[thread overview]
Message-ID: <30366.1056334013@ull> (raw)

Hi All, a small but important thing... I am using the latest gcc from cvs
(3.4 20030608 (experimental)) and if you build the cross compiler for a
powerpc/linux target, it leaves out the "fixup" stuff for the "-mrelocatable"
command line option. If you then want to use that cross compiler to build
"u-boot", it stuffs up with messages from the Assembler that looks something
like this (on certain C files):

... Error: Relocation cannot be done when using -mrelocatable

Since "-mrelocatable" is usually not used for Linux programs, I can't see why
they did this. Rather than have two different cross compilers, one for linux
and one for "other", which you use to compile u-boot, I chose a simple fix -
patch the file "gcc/config/rs6000/linux.h" as follows:

--- linux.h     2003/06/13 16:41:53     1.3
+++ linux.h     2003/06/20 01:28:53
@@ -84,7 +84,8 @@
 #define TARGET_64BIT 0
   
 /* We don't need to generate entries in .fixup.  */
-#undef RELOCATABLE_NEEDS_FIXUP
+/* well I do need them! */
+#define RELOCATABLE_NEEDS_FIXUP
  
 #define TARGET_ASM_FILE_END file_end_indicate_exec_stack

Hope this helps someone. Cheers!
								Murray...
--
Murray Jensen, CSIRO Manufacturing & Infra. Tech.      Phone: +61 3 9662 7763
Locked Bag No. 9, Preston, Vic, 3072, Australia.         Fax: +61 3 9662 7853
Internet: Murray.Jensen at csiro.au

Hymod project: http://www.msa.cmst.csiro.au/projects/Hymod/

To the extent permitted by law, CSIRO does not represent, warrant and/or
guarantee that the integrity of this communication has been maintained or
that the communication is free of errors, virus, interception or interference.

The information contained in this e-mail may be confidential or privileged.
Any unauthorised use or disclosure is prohibited. If you have received this
e-mail in error, please delete it immediately and notify Murray Jensen on
+61 3 9662 7763. Thank you.


-------------------------------------------------------
This SF.Net email is sponsored by: INetU
Attention Web Developers & Consultants: Become An INetU Hosting Partner.
Refer Dedicated Servers. We Manage Them. You Get 10% Monthly Commission!
INetU Dedicated Managed Hosting http://www.inetu.net/partner/index.php
_______________________________________________
PPCBoot-users mailing list
PPCBoot-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ppcboot-users

                 reply	other threads:[~2003-06-23  2:06 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=30366.1056334013@ull \
    --to=murray.jensen@csiro.au \
    --cc=u-boot@lists.denx.de \
    /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