diff options
author | Bernd Schmidt <bernds_cb1@t-online.de> | 2008-01-17 19:11:18 +0000 |
---|---|---|
committer | Bernd Schmidt <bernds_cb1@t-online.de> | 2008-01-17 19:11:18 +0000 |
commit | 23656d08e2055c62b09138f9330c15f088d74127 (patch) | |
tree | 88370a2dae9386dd1a665dffaf5617942e2668bf /Rules.mak | |
parent | bcfe4064658aad62431d9e96644c7a3eafd301b4 (diff) |
A patch from our Blackfin repository, originally from Jie Zhang. This fixes
a problem where the linker was trying to use the wrong symbol name for the
init function.
Define SYMBOL_PREFIX as _ in Rules.mak for h8300, bfin, i960,
microblaze, and v850. Add -D__UCLIBC_UNDERSCORES__ in CFLAGS for targets
which define SYMBOL_PREFIX as _. Remove defines and undefs from
uClibc_arch_features.h of each target.
Add $(SYMBOL_PREFIX) to __uClibc_init when passed by ld option -init.
Diffstat (limited to 'Rules.mak')
-rw-r--r-- | Rules.mak | 18 |
1 files changed, 18 insertions, 0 deletions
@@ -276,6 +276,7 @@ ifeq ($(TARGET_ARCH),sh64) endif ifeq ($(TARGET_ARCH),h8300) + SYMBOL_PREFIX=_ CPU_LDFLAGS-$(CONFIG_H8300H)+= -Wl,-ms8300h CPU_LDFLAGS-$(CONFIG_H8S) += -Wl,-ms8300s CPU_CFLAGS-$(CONFIG_H8300H) += -mh -mint32 @@ -310,6 +311,7 @@ ifeq ($(TARGET_ARCH),powerpc) endif ifeq ($(TARGET_ARCH),bfin) + SYMBOL_PREFIX=_ ifeq ($(UCLIBC_FORMAT_FDPIC_ELF),y) CPU_CFLAGS-y:=-mfdpic CPU_LDFLAGS-y += -Wl,-melf32bfinfd @@ -338,6 +340,18 @@ ifeq ($(strip $(TARGET_ARCH)),avr32) CPU_LDFLAGS-$(CONFIG_LINKRELAX) += --relax endif +ifeq ($(TARGET_ARCH),i960) + SYMBOL_PREFIX=_ +endif + +ifeq ($(TARGET_ARCH),microblaze) + SYMBOL_PREFIX=_ +endif + +ifeq ($(TARGET_ARCH),v850) + SYMBOL_PREFIX=_ +endif + # Keep the check_gcc from being needlessly executed ifndef PIEFLAG ifneq ($(UCLIBC_BUILD_PIE),y) @@ -533,6 +547,10 @@ ifneq ($(DOASSERTS),y) CFLAGS+=-DNDEBUG endif +ifeq ($(SYMBOL_PREFIX),_) +CFLAGS+=-D__UCLIBC_UNDERSCORES__ +endif + # Keep the check_as from being needlessly executed ifndef ASFLAGS_NOEXEC ifeq ($(UCLIBC_BUILD_NOEXECSTACK),y) |