[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 26/26] generate TARGET_<arch name> for config.h
From: |
quintela |
Subject: |
[Qemu-devel] [PATCH 26/26] generate TARGET_<arch name> for config.h |
Date: |
Mon, 13 Jul 2009 17:54:05 +0200 |
From: Juan Quintela <address@hidden>
Signed-off-by: Juan Quintela <address@hidden>
---
configure | 24 ++++++++----------------
1 files changed, 8 insertions(+), 16 deletions(-)
diff --git a/configure b/configure
index 5835dbe..819276a 100755
--- a/configure
+++ b/configure
@@ -1886,37 +1886,33 @@ echo "#define CONFIG_QEMU_PREFIX \"$interp_prefix1\""
>> $config_h
gdb_xml_files=""
TARGET_ARCH="$target_arch2"
+target_arch_name=""
+
case "$target_arch2" in
i386)
- echo "#define TARGET_I386 1" >> $config_h
target_phys_bits=32
;;
x86_64)
echo "TARGET_BASE_ARCH=i386" >> $config_mak
echo "#define TARGET_I386 1" >> $config_h
- echo "#define TARGET_X86_64 1" >> $config_h
target_phys_bits=64
;;
alpha)
- echo "#define TARGET_ALPHA 1" >> $config_h
target_phys_bits=64
;;
arm|armeb)
TARGET_ARCH=arm
echo "TARGET_ARCH2=$target_arch2" >> $config_mak
- echo "#define TARGET_ARM 1" >> $config_h
bflt="yes"
target_nptl="yes"
gdb_xml_files="arm-core.xml arm-vfp.xml arm-vfp3.xml arm-neon.xml"
target_phys_bits=32
;;
cris)
- echo "#define TARGET_CRIS 1" >> $config_h
target_nptl="yes"
target_phys_bits=32
;;
m68k)
- echo "#define TARGET_M68K 1" >> $config_h
bflt="yes"
gdb_xml_files="cf-core.xml cf-fp.xml"
target_phys_bits=32
@@ -1930,7 +1926,6 @@ case "$target_arch2" in
mips|mipsel)
TARGET_ARCH=mips
echo "TARGET_ARCH2=$target_arch2" >> $config_mak
- echo "#define TARGET_MIPS 1" >> $config_h
echo "#define TARGET_ABI_MIPSO32 1" >> $config_h
target_nptl="yes"
target_phys_bits=64
@@ -1939,7 +1934,7 @@ case "$target_arch2" in
TARGET_ARCH=mipsn32
echo "TARGET_ARCH2=$target_arch2" >> $config_mak
echo "TARGET_BASE_ARCH=mips" >> $config_mak
- echo "#define TARGET_MIPS 1" >> $config_h
+ target_arch_name=mips
echo "#define TARGET_ABI_MIPSN32 1" >> $config_h
target_phys_bits=64
;;
@@ -1948,7 +1943,6 @@ case "$target_arch2" in
echo "TARGET_ARCH2=$target_arch2" >> $config_mak
echo "TARGET_BASE_ARCH=mips" >> $config_mak
echo "#define TARGET_MIPS 1" >> $config_h
- echo "#define TARGET_MIPS64 1" >> $config_h
echo "#define TARGET_ABI_MIPSN64 1" >> $config_h
target_phys_bits=64
;;
@@ -1961,7 +1955,6 @@ case "$target_arch2" in
echo "TARGET_BASE_ARCH=ppc" >> $config_mak
echo "TARGET_ABI_DIR=ppc" >> $config_mak
echo "#define TARGET_PPC 1" >> $config_h
- echo "#define TARGET_PPCEMB 1" >> $config_h
gdb_xml_files="power-core.xml power-fpu.xml power-altivec.xml
power-spe.xml"
target_phys_bits=64
;;
@@ -1969,7 +1962,6 @@ case "$target_arch2" in
echo "TARGET_BASE_ARCH=ppc" >> $config_mak
echo "TARGET_ABI_DIR=ppc" >> $config_mak
echo "#define TARGET_PPC 1" >> $config_h
- echo "#define TARGET_PPC64 1" >> $config_h
gdb_xml_files="power64-core.xml power-fpu.xml power-altivec.xml
power-spe.xml"
target_phys_bits=64
;;
@@ -1979,7 +1971,6 @@ case "$target_arch2" in
echo "TARGET_ABI_DIR=ppc" >> $config_mak
echo "TARGET_ARCH2=ppc64abi32" >> $config_mak
echo "#define TARGET_PPC 1" >> $config_h
- echo "#define TARGET_PPC64 1" >> $config_h
echo "#define TARGET_ABI32 1" >> $config_h
gdb_xml_files="power64-core.xml power-fpu.xml power-altivec.xml
power-spe.xml"
target_phys_bits=64
@@ -1987,19 +1978,16 @@ case "$target_arch2" in
sh4|sh4eb)
TARGET_ARCH=sh4
echo "TARGET_ARCH2=$target_arch2" >> $config_mak
- echo "#define TARGET_SH4 1" >> $config_h
bflt="yes"
target_nptl="yes"
target_phys_bits=32
;;
sparc)
- echo "#define TARGET_SPARC 1" >> $config_h
target_phys_bits=64
;;
sparc64)
echo "TARGET_BASE_ARCH=sparc" >> $config_mak
echo "#define TARGET_SPARC 1" >> $config_h
- echo "#define TARGET_SPARC64 1" >> $config_h
elfload32="yes"
target_phys_bits=64
;;
@@ -2009,7 +1997,6 @@ case "$target_arch2" in
echo "TARGET_ABI_DIR=sparc" >> $config_mak
echo "TARGET_ARCH2=$target_arch2" >> $config_mak
echo "#define TARGET_SPARC 1" >> $config_h
- echo "#define TARGET_SPARC64 1" >> $config_h
echo "#define TARGET_ABI32 1" >> $config_h
target_phys_bits=64
;;
@@ -2018,8 +2005,13 @@ case "$target_arch2" in
exit 1
;;
esac
+if [ "$target_arch_name" = "" ]; then
+ target_arch_name=`echo $TARGET_ARCH | tr '[:lower:]' '[:upper:]'`
+fi
+
echo "TARGET_ARCH=$TARGET_ARCH" >> $config_mak
echo "#define TARGET_ARCH \"$TARGET_ARCH\"" >> $config_h
+echo "#define TARGET_$target_arch_name 1" >> $config_h
if [ $target_phys_bits -lt $hostlongbits ] ; then
target_phys_bits=$hostlongbits
--
1.6.2.5
- [Qemu-devel] [PATCH 16/26] Refactor a single rule to generate all qemu-* executables, (continued)
- [Qemu-devel] [PATCH 16/26] Refactor a single rule to generate all qemu-* executables, quintela, 2009/07/13
- [Qemu-devel] [PATCH 17/26] qemu binary don't exist anymore. I guess not much people is compiling on alpha, quintela, 2009/07/13
- [Qemu-devel] [PATCH 18/26] We can wrap OS_CFLAGS/OS_LDFLAGS in CFLAGS/LDFLAGS at configure time, quintela, 2009/07/13
- [Qemu-devel] [PATCH 19/26] We can wrap ARCH_CFLAGS/ARCH_LDFLAGS in CFLAGS/LDFLAGS at configure time, quintela, 2009/07/13
- [Qemu-devel] [PATCH 20/26] generate ARCH name instead of coding it, quintela, 2009/07/13
- [Qemu-devel] [PATCH 21/26] Refactor common code using a list, quintela, 2009/07/13
- [Qemu-devel] [PATCH 22/26] Refactor targe_bigendian selection in another list, quintela, 2009/07/13
- [Qemu-devel] [PATCH 23/26] print only once TARGET_ARCH, quintela, 2009/07/13
- [Qemu-devel] [PATCH 25/26] generate TARGET_ARCH for config.h, quintela, 2009/07/13
- [Qemu-devel] [PATCH 24/26] Only setup TARGET_ARCH when it is different of, quintela, 2009/07/13
- [Qemu-devel] [PATCH 26/26] generate TARGET_<arch name> for config.h,
quintela <=