[U-Boot] [PATCH 02/32] x86: Align config.mk and linker scripts with other arches

Scott Wood scottwood at freescale.com
Fri Feb 4 21:42:10 CET 2011


On Fri, 4 Feb 2011 23:35:29 +1100
Graeme Russ <graeme.russ at gmail.com> wrote:

>  LDFLAGS += --cref
> -LDFLAGS_u-boot += --gc-sections
> -PLATFORM_RELFLAGS += -ffunction-sections
> +LDFLAGS_u-boot += --gc-sections -pie
> +LDSCRIPT := $(SRCTREE)/$(CPUDIR)/u-boot.lds

The use of --cref came up recently (see
http://lists.denx.de/pipermail/u-boot/2011-February/086698.html).

During what link phase is --cref supposed to be used?  Currently it is being
used during partial links only, and not the final link, as a result of
commit 8aba9dceebb14144e07d19593111ee3a999c37fc.  As the toplevel
config.mk currently stands, it would have to go in PLATFORM_LDFLAGS to
be used in all link phases, or LDFLAGS_u-boot to be used when linking
the final image only.

BTW, is it really enabled because of something to do with i386?  Or just
maintainer preference (in which case it should probably be a non-arch config,
or in this case just enabled unconditionally, since I don't think there's
any harm to it).

-Scott



More information about the U-Boot mailing list