Migrate to check_define
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6302 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
parent
e58ffeb322
commit
fdf7ed9652
40
configure
vendored
40
configure
vendored
@ -88,8 +88,14 @@ elif check_define __sparc__ ; then
|
|||||||
else
|
else
|
||||||
cpu="sparc"
|
cpu="sparc"
|
||||||
fi
|
fi
|
||||||
|
elif check_define _ARCH_PPC ; then
|
||||||
|
if check_define _ARCH_PPC64 ; then
|
||||||
|
cpu="ppc64"
|
||||||
else
|
else
|
||||||
cpu=`test $(uname -s) = AIX && uname -p || uname -m`
|
cpu="ppc"
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
cpu=`uname -m`
|
||||||
fi
|
fi
|
||||||
|
|
||||||
target_list=""
|
target_list=""
|
||||||
@ -127,8 +133,11 @@ case "$cpu" in
|
|||||||
mips64)
|
mips64)
|
||||||
cpu="mips64"
|
cpu="mips64"
|
||||||
;;
|
;;
|
||||||
"Power Macintosh"|ppc|ppc64|powerpc)
|
ppc)
|
||||||
cpu="powerpc"
|
cpu="ppc"
|
||||||
|
;;
|
||||||
|
ppc64)
|
||||||
|
cpu="ppc64"
|
||||||
;;
|
;;
|
||||||
s390*)
|
s390*)
|
||||||
cpu="s390"
|
cpu="s390"
|
||||||
@ -678,7 +687,8 @@ if test "$cpu" = "armv4b" \
|
|||||||
-o "$cpu" = "m68k" \
|
-o "$cpu" = "m68k" \
|
||||||
-o "$cpu" = "mips" \
|
-o "$cpu" = "mips" \
|
||||||
-o "$cpu" = "mips64" \
|
-o "$cpu" = "mips64" \
|
||||||
-o "$cpu" = "powerpc" \
|
-o "$cpu" = "ppc" \
|
||||||
|
-o "$cpu" = "ppc64" \
|
||||||
-o "$cpu" = "s390" \
|
-o "$cpu" = "s390" \
|
||||||
-o "$cpu" = "sparc" \
|
-o "$cpu" = "sparc" \
|
||||||
-o "$cpu" = "sparc64"; then
|
-o "$cpu" = "sparc64"; then
|
||||||
@ -692,20 +702,11 @@ hostlongbits="32"
|
|||||||
if test "$cpu" = "x86_64" \
|
if test "$cpu" = "x86_64" \
|
||||||
-o "$cpu" = "alpha" \
|
-o "$cpu" = "alpha" \
|
||||||
-o "$cpu" = "ia64" \
|
-o "$cpu" = "ia64" \
|
||||||
-o "$cpu" = "sparc64"; then
|
-o "$cpu" = "sparc64" \
|
||||||
|
-o "$cpu" = "ppc64"; then
|
||||||
hostlongbits="64"
|
hostlongbits="64"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# ppc specific hostlongbits selection
|
|
||||||
if test "$cpu" = "powerpc" ; then
|
|
||||||
if $cc $ARCH_CFLAGS -dM -E - -o $TMPI 2>/dev/null </dev/null; then
|
|
||||||
grep -q __powerpc64__ $TMPI && hostlongbits=64
|
|
||||||
else
|
|
||||||
echo hostlongbits test failed
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
# check gcc options support
|
# check gcc options support
|
||||||
cat > $TMPC <<EOF
|
cat > $TMPC <<EOF
|
||||||
int main(void) {
|
int main(void) {
|
||||||
@ -1210,14 +1211,13 @@ case "$cpu" in
|
|||||||
echo "ARCH=mips64" >> $config_mak
|
echo "ARCH=mips64" >> $config_mak
|
||||||
echo "#define HOST_MIPS64 1" >> $config_h
|
echo "#define HOST_MIPS64 1" >> $config_h
|
||||||
;;
|
;;
|
||||||
powerpc)
|
ppc)
|
||||||
if test "$hostlongbits" = "32"; then
|
|
||||||
echo "ARCH=ppc" >> $config_mak
|
echo "ARCH=ppc" >> $config_mak
|
||||||
echo "#define HOST_PPC 1" >> $config_h
|
echo "#define HOST_PPC 1" >> $config_h
|
||||||
else
|
;;
|
||||||
|
ppc64)
|
||||||
echo "ARCH=ppc64" >> $config_mak
|
echo "ARCH=ppc64" >> $config_mak
|
||||||
echo "#define HOST_PPC64 1" >> $config_h
|
echo "#define HOST_PPC64 1" >> $config_h
|
||||||
fi
|
|
||||||
;;
|
;;
|
||||||
s390)
|
s390)
|
||||||
echo "ARCH=s390" >> $config_mak
|
echo "ARCH=s390" >> $config_mak
|
||||||
@ -1534,7 +1534,7 @@ gdb_xml_files=""
|
|||||||
|
|
||||||
# Make sure the target and host cpus are compatible
|
# Make sure the target and host cpus are compatible
|
||||||
if test "$kvm" = "yes" -a ! \( "$target_cpu" = "$cpu" -o \
|
if test "$kvm" = "yes" -a ! \( "$target_cpu" = "$cpu" -o \
|
||||||
\( "$target_cpu" = "ppcemb" -a "$cpu" = "powerpc" \) -o \
|
\( "$target_cpu" = "ppcemb" -a "$cpu" = "ppc" \) -o \
|
||||||
\( "$target_cpu" = "x86_64" -a "$cpu" = "i386" \) -o \
|
\( "$target_cpu" = "x86_64" -a "$cpu" = "i386" \) -o \
|
||||||
\( "$target_cpu" = "i386" -a "$cpu" = "x86_64" \) \) ; then
|
\( "$target_cpu" = "i386" -a "$cpu" = "x86_64" \) \) ; then
|
||||||
kvm="no"
|
kvm="no"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user