From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wolfgang Denk Date: Fri, 10 Sep 2010 23:10:15 +0200 Subject: [U-Boot] [PATCH] examples/standalone: Remove relocation compile flags for PowerPC In-Reply-To: <1284149249.26713.2926.camel@petert> References: <1276572325-12642-1-git-send-email-ptyser@xes-inc.com> <4C17CE2F.9050208@freescale.com> <4C17CEEC.8000409@freescale.com> <1276630601.32134.1501.camel@petert> <4C17D851.4010307@freescale.com> <1276632905.32134.1535.camel@petert> <20100615202813.A1816153659@gemini.denx.de> <1276634341.32134.1541.camel@petert> <20100615205129.11EF7153659@gemini.denx.de> <1276659428.15340.7.camel@ptyser-laptop> <20100616145133.BBDE7D81C69@gemini.denx.de> <20100910194959.BD615153798@gemini.denx.de> <1284149249.26713.2926.camel@petert> Message-ID: <20100910211015.A35DB153798@gemini.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Peter Tyser, In message <1284149249.26713.2926.camel@petert> you wrote: > > > Sorry, I'm confused. What exactly do you want me to do? Since you > > applied Peter's patch, the problem has gone away for me. > > However, I think there's still the issue that if there are multiple > functions in a standalone application there's no guarantee the entry > point function will be at the base of the image. eg if the app were: That's my understanding as well. > My last question on the issue was: > It looks like the -fno-toplevel-reorder flag is only available in gcc >= > 4.2 (http://gcc.gnu.org/gcc-4.2/changes.html released May 2007). So, do > we add support to U-Boot to conditionally check for the gcc version like > Linux to know when to use -fno-toplevel-reorder? Or do we use a linker > script that would support more versions of gcc at the cost of more > complexity? > > I never heard back about the preferred method. I'd personally lean > towards checking for compiler version and using the gcc version check + > -fno-toplevel-reorder. Given the fact that GCC 4.2 is already pretty old I also tend to add a gcc version check with -fno-toplevel-reorder instead of increasing the complexity of the linker scripts. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de You can observe a lot just by watching. - Yogi Berra