From: Mike Frysinger Date: Fri, 22 Jun 2007 04:19:20 -0400 Subject: [U-Boot-Users] [patch] only use $(TEXT_BASE) if it is set Message-ID: <200706220419.21414.vapier@gentoo.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de we've moved TEXT_BASE out of the build system for Blackfin and into the config header so that when porting to a new board, users dont need to set both the CFG_MONITOR_BASE and TEXT_BASE to the same value in two remotely different files for u-boot general though, i'd like to apply the attached patch that simply says only utilize TEXT_BASE in global common files if it is set ... that way everyone else can continue to use TEXT_BASE in their board specific .mk files while in Blackfin, we can simply unset it Signed-off-by: Mike Frysinger --- diff --git a/config.mk b/config.mk index 582df32..e57339f 100644 --- a/config.mk +++ b/config.mk @@ -147,8 +147,10 @@ OBJCFLAGS += --gap-fill=0xff gccincdir := $(shell $(CC) -print-file-name=include) -CPPFLAGS := $(DBGFLAGS) $(OPTFLAGS) $(RELFLAGS) \ - -D__KERNEL__ -DTEXT_BASE=$(TEXT_BASE) \ +CPPFLAGS := $(DBGFLAGS) $(OPTFLAGS) $(RELFLAGS) -D__KERNEL__ +ifneq ($(TEXT_BASE),) +CPPFLAGS += -DTEXT_BASE=$(TEXT_BASE) +endif ifneq ($(OBJTREE),$(SRCTREE)) CPPFLAGS += -I$(OBJTREE)/include2 -I$(OBJTREE)/include @@ -186,7 +188,10 @@ endif AFLAGS := $(AFLAGS_DEBUG) -D__ASSEMBLY__ $(CPPFLAGS) -LDFLAGS += -Bstatic -T $(LDSCRIPT) -Ttext $(TEXT_BASE) $(PLATFORM_LDFLAGS) +LDFLAGS += -Bstatic -T $(LDSCRIPT) $(PLATFORM_LDFLAGS) +ifneq ($(TEXT_BASE),) +LDFLAGS += -Ttext $(TEXT_BASE) +endif # Location of a usable BFD library, where we define "usable" as # "built for ${HOST}, supports ${TARGET}". Sensible values are -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 827 bytes Desc: This is a digitally signed message part. Url : http://lists.denx.de/pipermail/u-boot/attachments/20070622/1d715b83/attachment.pgp