diff options
author | Eric Andersen <andersen@codepoet.org> | 2002-11-03 14:59:00 +0000 |
---|---|---|
committer | Eric Andersen <andersen@codepoet.org> | 2002-11-03 14:59:00 +0000 |
commit | 0c6405c1d65d8a570b731abf1163fe6003a62c2c (patch) | |
tree | 2bfd64ca323ed1f96b4c342f793666261d5f7bf1 | |
parent | 4bb535f88baea1473630b83d06fe86cc42d69e86 (diff) |
Yet more config system updating.
-rw-r--r-- | Rules.mak | 43 | ||||
-rw-r--r-- | extra/Configs/Config.alpha | 7 | ||||
-rw-r--r-- | extra/Configs/Config.arm | 14 | ||||
-rw-r--r-- | extra/Configs/Config.cris | 4 | ||||
-rw-r--r-- | extra/Configs/Config.h8300 | 10 | ||||
-rw-r--r-- | extra/Configs/Config.i386 | 23 | ||||
-rw-r--r-- | extra/Configs/Config.i386.default | 1 | ||||
-rw-r--r-- | extra/Configs/Config.i960 | 10 | ||||
-rw-r--r-- | extra/Configs/Config.in.arch | 5 | ||||
-rw-r--r-- | extra/Configs/Config.m68k | 6 | ||||
-rw-r--r-- | extra/Configs/Config.mips | 7 | ||||
-rw-r--r-- | extra/Configs/Config.mipsel | 7 | ||||
-rw-r--r-- | extra/Configs/Config.powerpc | 7 | ||||
-rw-r--r-- | extra/Configs/Config.sh | 18 | ||||
-rw-r--r-- | extra/Configs/Config.sparc | 4 | ||||
-rw-r--r-- | extra/Configs/Config.v850e | 11 |
16 files changed, 51 insertions, 126 deletions
@@ -94,20 +94,45 @@ export LC_COLLATE ARFLAGS:=r -# Some nice architecture specific optimizations -ifndef OPTIMIZATION - # use '-Os' optimization if available, else use -O2, allow Config to override OPTIMIZATION:= OPTIMIZATION+=$(call check_gcc,-Os,-O2) -ifeq ($(strip $(TARGET_ARCH)),arm) - OPTIMIZATION+=-fstrict-aliasing -endif + +# Some nice CPU specific optimizations ifeq ($(strip $(TARGET_ARCH)),i386) OPTIMIZATION+=$(call check_gcc,-mpreferred-stack-boundary=2,) - OPTIMIZATION+=$(call check_gcc,-falign-functions=0 -falign-jumps=0 -falign-loops=0,\ - -malign-functions=0 -malign-jumps=0 -malign-loops=0) + OPTIMIZATION+=$(call check_gcc,-falign-jumps=0 -falign-loops=0,-malign-jumps=0 -malign-loops=0) + CPU_CFLAGS-$(CONFIG_386):="-march=i386" + CPU_CFLAGS-$(CONFIG_486):="-march=i486" + CPU_CFLAGS-$(CONFIG_586):="-march=i586" + CPU_CFLAGS-$(CONFIG_586MMX):="$(call check_gcc,-march=pentium-mmx,-march=i586)" + CPU_CFLAGS-$(CONFIG_686):="-march=i686" + CPU_CFLAGS-$(CONFIG_PENTIUMIII):="$(call check_gcc,-march=pentium3,-march=i686)" + CPU_CFLAGS-$(CONFIG_PENTIUM4):="$(call check_gcc,-march=pentium4,-march=i686)" + CPU_CFLAGS-$(CONFIG_K6):="$(call check_gcc,-march=k6,-march=i586)" + CPU_CFLAGS-$(CONFIG_K7):="$(call check_gcc,-march=athlon,-malign-functions=4 -march=i686)" + CPU_CFLAGS-$(CONFIG_CRUSOE):="-march=i686 -malign-functions=0 -malign-jumps=0 -malign-loops=0" + CPU_CFLAGS-$(CONFIG_WINCHIPC6):="$(call check_gcc,-march=winchip-c6,-march=i586)" + CPU_CFLAGS-$(CONFIG_WINCHIP2):="$(call check_gcc,-march=winchip2,-march=i586)" + CPU_CFLAGS-$(CONFIG_CYRIXIII):="$(call check_gcc,-march=c3,-march=i586)" endif + +ifeq ($(strip $(TARGET_ARCH)),arm) + OPTIMIZATION+=-fstrict-aliasing + CPU_CFLAGS-$(CONFIG_GENERIC_ARM):= + CPU_CFLAGS-$(CONFIG_ARM7TDMI):="-march=arm7tdmi" + CPU_CFLAGS-$(CONFIG_STRONGARM):="-march=strongarm" + CPU_CFLAGS-$(CONFIG_XSCALE):="$(call check_gcc,-march=xscale,-march=strongarm)" +endif + +ifeq ($(strip $(TARGET_ARCH)),sh) + OPTIMIZATION+=-fstrict-aliasing + CPU_CFLAGS-$(ARCH_LITTLE_ENDIAN):="-ml" + CPU_CFLAGS-$(ARCH_BIG_ENDIAN):="-mb" + CPU_CFLAGS-$(CONFIG_SH2)+="-m2" + CPU_CFLAGS-$(CONFIG_SH3)+="-m3" + CPU_CFLAGS-$(CONFIG_SH4)+="-m4" + CPU_CFLAGS-$(CONFIG_SH5)+="-m5" endif # Add a bunch of extra pedantic annoyingly strict checks @@ -115,7 +140,7 @@ WARNINGS+=-Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing CFLAGS:=$(WARNINGS) $(OPTIMIZATION) -fno-builtin -nostdinc $(CPUFLAGS) \ - -I$(TOPDIR)include -iwithprefix include -I. -D_LIBC $(CPU_CFLAGS) $(ARCH_CFLAGS) + -I$(TOPDIR)include -iwithprefix include -I. -D_LIBC $(CPU_CFLAGS-y) $(ARCH_CFLAGS) NATIVE_CFLAGS:=-O2 -Wall ifeq ($(strip $(DODEBUG)),y) diff --git a/extra/Configs/Config.alpha b/extra/Configs/Config.alpha index 3a13d9826..0f55c3252 100644 --- a/extra/Configs/Config.alpha +++ b/extra/Configs/Config.alpha @@ -11,21 +11,14 @@ config HAVE_ELF bool default y -config C_SYMBOL_PREFIX - string - default "" - config ARCH_CFLAGS string - default "" config ARCH_LDFLAGS string - default "" config LIBGCC_CFLAGS string - default "" source "extra/Configs/Config.in.arch" diff --git a/extra/Configs/Config.arm b/extra/Configs/Config.arm index e11ec1008..f458f23a1 100644 --- a/extra/Configs/Config.arm +++ b/extra/Configs/Config.arm @@ -11,21 +11,14 @@ config HAVE_ELF bool default y -config C_SYMBOL_PREFIX - string - default "" - config ARCH_CFLAGS string - default "" config ARCH_LDFLAGS string - default "" config LIBGCC_CFLAGS string - default "" choice prompt "Target Processor Type" @@ -66,13 +59,6 @@ config ARCH_HAS_NO_MMU bool default y if CONFIG_ARM7TDMI -config CPU_CFLAGS - string - default "" if CONFIG_GENERIC_ARM - default "-march=arm7tdmi" if CONFIG_ARM7TDMI - default "-march=strongarm" if CONFIG_STRONGARM - default "$(call check_gcc,-march=xscale,-march=strongarm)" if CONFIG_XSCALE - source "extra/Configs/Config.in.arch" endmenu diff --git a/extra/Configs/Config.cris b/extra/Configs/Config.cris index 983570f78..4d3514689 100644 --- a/extra/Configs/Config.cris +++ b/extra/Configs/Config.cris @@ -11,10 +11,6 @@ config HAVE_ELF bool default y -config C_SYMBOL_PREFIX - string - default "" - config ARCH_CFLAGS string default "-fpic -mlinux -D__USE_WEAK_ALIASES" diff --git a/extra/Configs/Config.h8300 b/extra/Configs/Config.h8300 index e3a63a5af..8c17d89a9 100644 --- a/extra/Configs/Config.h8300 +++ b/extra/Configs/Config.h8300 @@ -11,26 +11,24 @@ config HAVE_ELF bool default n -config C_SYMBOL_PREFIX - string - default "_" - config ARCH_CFLAGS string default "-mh -mint32 -fsigned-char" config ARCH_LDFLAGS string - default "" config LIBGCC_CFLAGS string - default "" config ARCH_HAS_NO_MMU bool default y +config ARCH_HAS_C_SYMBOL_PREFIX + bool + default y + source "extra/Configs/Config.in.arch" endmenu diff --git a/extra/Configs/Config.i386 b/extra/Configs/Config.i386 index 463da8e2b..55f609bb6 100644 --- a/extra/Configs/Config.i386 +++ b/extra/Configs/Config.i386 @@ -11,21 +11,14 @@ config HAVE_ELF bool default y -config C_SYMBOL_PREFIX - string - default "" - config ARCH_CFLAGS string - default "" config ARCH_LDFLAGS string - default "" config LIBGCC_CFLAGS string - default "" choice prompt "Target Processor Type" @@ -100,22 +93,6 @@ config CONFIG_CYRIXIII endchoice -config CPU_CFLAGS - string - default "-march=i386" if CONFIG_386 - default "-march=i486" if CONFIG_486 - default "-march=i586" if CONFIG_586 - default "$(call check_gcc,-march=pentium-mmx,-march=i586)" if CONFIG_586MMX - default "-march=i686" if CONFIG_686 - default "$(call check_gcc,-march=pentium3,-march=i686)" if CONFIG_PENTIUMIII - default "$(call check_gcc,-march=pentium4,-march=i686)" if CONFIG_PENTIUM4 - default "$(call check_gcc,-march=k6,-march=i586)" if CONFIG_K6 - default "$(call check_gcc,-march=athlon,-march=i686 -malign-functions=4)" if CONFIG_K7 - default "-march=i686 -malign-functions=0 -malign-jumps=0 -malign-loops=0" if CONFIG_CRUSOE - default "$(call check_gcc,-march=winchip-c6,-march=i586)" if CONFIG_WINCHIPC6 - default "$(call check_gcc,-march=winchip2,-march=i586)" if CONFIG_WINCHIP2 - default "$(call check_gcc,-march=c3,-march=i586)" if CONFIG_CYRIXIII - source "extra/Configs/Config.in.arch" endmenu diff --git a/extra/Configs/Config.i386.default b/extra/Configs/Config.i386.default index b563f47c3..bc215596f 100644 --- a/extra/Configs/Config.i386.default +++ b/extra/Configs/Config.i386.default @@ -27,7 +27,6 @@ HAS_FPU=y # DO_C99_MATH is not set WARNINGS="-Wall" KERNEL_SOURCE="/usr/src/linux" -C_SYMBOL_PREFIX="" UCLIBC_UCLINUX_BROKEN_MUNMAP=y HAVE_ELF=y # HAVE_DOT_HIDDEN is not set diff --git a/extra/Configs/Config.i960 b/extra/Configs/Config.i960 index 4ffafdf01..ac35628c2 100644 --- a/extra/Configs/Config.i960 +++ b/extra/Configs/Config.i960 @@ -11,26 +11,24 @@ config HAVE_ELF bool default n -config C_SYMBOL_PREFIX - string - default "_" - config ARCH_CFLAGS string default "-mh -mint32 -fsigned-char" config ARCH_LDFLAGS string - default "" config LIBGCC_CFLAGS string - default "" config ARCH_HAS_NO_MMU bool default y +config ARCH_HAS_C_SYMBOL_PREFIX + bool + default y + source "extra/Configs/Config.in.arch" endmenu diff --git a/extra/Configs/Config.in.arch b/extra/Configs/Config.in.arch index 6e9f5fb82..1e7b1129a 100644 --- a/extra/Configs/Config.in.arch +++ b/extra/Configs/Config.in.arch @@ -82,3 +82,8 @@ config EXCLUDE_BRK depends on !UCLIBC_HAS_MMU default y +config C_SYMBOL_PREFIX + string + default "_" if ARCH_HAS_C_SYMBOL_PREFIX + default "" if !ARCH_HAS_C_SYMBOL_PREFIX + diff --git a/extra/Configs/Config.m68k b/extra/Configs/Config.m68k index ca36c0cd0..48c70fe54 100644 --- a/extra/Configs/Config.m68k +++ b/extra/Configs/Config.m68k @@ -11,21 +11,15 @@ config HAVE_ELF bool default y -config C_SYMBOL_PREFIX - string - default "" - config ARCH_CFLAGS string default "-Wa,--bitwise-or -I$(KERNEL_SOURCE)/include" config ARCH_LDFLAGS string - default "" config LIBGCC_CFLAGS string - default "" config HAVE_ELF bool diff --git a/extra/Configs/Config.mips b/extra/Configs/Config.mips index 72f7f6d50..8ede6f26f 100644 --- a/extra/Configs/Config.mips +++ b/extra/Configs/Config.mips @@ -11,21 +11,14 @@ config HAVE_ELF bool default y -config C_SYMBOL_PREFIX - string - default "" - config ARCH_CFLAGS string - default "" config ARCH_LDFLAGS string - default "" config LIBGCC_CFLAGS string - default "" choice prompt "Target Processor Endianness" diff --git a/extra/Configs/Config.mipsel b/extra/Configs/Config.mipsel index 3a13d9826..0f55c3252 100644 --- a/extra/Configs/Config.mipsel +++ b/extra/Configs/Config.mipsel @@ -11,21 +11,14 @@ config HAVE_ELF bool default y -config C_SYMBOL_PREFIX - string - default "" - config ARCH_CFLAGS string - default "" config ARCH_LDFLAGS string - default "" config LIBGCC_CFLAGS string - default "" source "extra/Configs/Config.in.arch" diff --git a/extra/Configs/Config.powerpc b/extra/Configs/Config.powerpc index 3a13d9826..0f55c3252 100644 --- a/extra/Configs/Config.powerpc +++ b/extra/Configs/Config.powerpc @@ -11,21 +11,14 @@ config HAVE_ELF bool default y -config C_SYMBOL_PREFIX - string - default "" - config ARCH_CFLAGS string - default "" config ARCH_LDFLAGS string - default "" config LIBGCC_CFLAGS string - default "" source "extra/Configs/Config.in.arch" diff --git a/extra/Configs/Config.sh b/extra/Configs/Config.sh index 5b7f1c907..bcd273487 100644 --- a/extra/Configs/Config.sh +++ b/extra/Configs/Config.sh @@ -11,21 +11,14 @@ config HAVE_ELF bool default y -config C_SYMBOL_PREFIX - string - default "" - config ARCH_CFLAGS string - default "" config ARCH_LDFLAGS string - default "" config LIBGCC_CFLAGS string - default "" config HAVE_DOT_HIDDEN bool @@ -80,17 +73,6 @@ config ARCH_HAS_NO_MMU bool default y if CONFIG_SH2 || CONFIG_SH3 -config CPU_CFLAGS - string - default "-ml -m2" if CONFIG_SH2 && ARCH_LITTLE_ENDIAN - default "-mb -m2" if CONFIG_SH2 && ARCH_BIG_ENDIAN - default "-ml -m3" if CONFIG_SH3 && ARCH_LITTLE_ENDIAN - default "-mb -m3" if CONFIG_SH3 && ARCH_BIG_ENDIAN - default "-ml -m4" if CONFIG_SH4 && ARCH_LITTLE_ENDIAN - default "-mb -m4" if CONFIG_SH4 && ARCH_BIG_ENDIAN - default "-ml -m5" if CONFIG_SH5 && ARCH_LITTLE_ENDIAN - default "-mb -m5" if CONFIG_SH5 && ARCH_BIG_ENDIAN - source "extra/Configs/Config.in.arch" endmenu diff --git a/extra/Configs/Config.sparc b/extra/Configs/Config.sparc index 983570f78..4d3514689 100644 --- a/extra/Configs/Config.sparc +++ b/extra/Configs/Config.sparc @@ -11,10 +11,6 @@ config HAVE_ELF bool default y -config C_SYMBOL_PREFIX - string - default "" - config ARCH_CFLAGS string default "-fpic -mlinux -D__USE_WEAK_ALIASES" diff --git a/extra/Configs/Config.v850e b/extra/Configs/Config.v850e index 176e43e14..c0a7226ed 100644 --- a/extra/Configs/Config.v850e +++ b/extra/Configs/Config.v850e @@ -11,21 +11,14 @@ config HAVE_ELF bool default y -config C_SYMBOL_PREFIX - string - default "_" - config ARCH_CFLAGS string - default "" config ARCH_LDFLAGS string - default "" config LIBGCC_CFLAGS string - default "" config HAVE_ELF bool @@ -35,6 +28,10 @@ config ARCH_HAS_NO_MMU bool default y +config ARCH_HAS_C_SYMBOL_PREFIX + bool + default y + source "extra/Configs/Config.in.arch" endmenu |