mirror of https://gitee.com/openkylin/qemu.git
Move definition of HOST_LONG_BITS to qemu-common.h
Like the related macro TCG_TARGET_LONG, HOST_LONG_BITS can be determined by the C preprocessor. It is also not used in Makefiles. So there is no need to calculate it in configure, and it can be defined in qemu-common.h. Signed-off-by: Stefan Weil <sw@weilnetz.de>
This commit is contained in:
parent
2ad5201c1e
commit
c0fd260e9d
|
@ -1291,17 +1291,6 @@ esac
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# host long bits test, actually a pointer size test
|
|
||||||
cat > $TMPC << EOF
|
|
||||||
int sizeof_pointer_is_8[sizeof(void *) == 8 ? 1 : -1];
|
|
||||||
EOF
|
|
||||||
if compile_object; then
|
|
||||||
hostlongbits=64
|
|
||||||
else
|
|
||||||
hostlongbits=32
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
##########################################
|
##########################################
|
||||||
# NPTL probe
|
# NPTL probe
|
||||||
|
|
||||||
|
@ -2988,7 +2977,6 @@ fi
|
||||||
if test "$bigendian" = "yes" ; then
|
if test "$bigendian" = "yes" ; then
|
||||||
echo "HOST_WORDS_BIGENDIAN=y" >> $config_host_mak
|
echo "HOST_WORDS_BIGENDIAN=y" >> $config_host_mak
|
||||||
fi
|
fi
|
||||||
echo "HOST_LONG_BITS=$hostlongbits" >> $config_host_mak
|
|
||||||
if test "$mingw32" = "yes" ; then
|
if test "$mingw32" = "yes" ; then
|
||||||
echo "CONFIG_WIN32=y" >> $config_host_mak
|
echo "CONFIG_WIN32=y" >> $config_host_mak
|
||||||
rc_version=`cat $source_path/VERSION`
|
rc_version=`cat $source_path/VERSION`
|
||||||
|
|
|
@ -65,6 +65,15 @@ typedef struct Monitor Monitor;
|
||||||
#define TIME_MAX LONG_MAX
|
#define TIME_MAX LONG_MAX
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/* HOST_LONG_BITS is the size of a native pointer in bits. */
|
||||||
|
#if UINTPTR_MAX == UINT32_MAX
|
||||||
|
# define HOST_LONG_BITS 32
|
||||||
|
#elif UINTPTR_MAX == UINT64_MAX
|
||||||
|
# define HOST_LONG_BITS 64
|
||||||
|
#else
|
||||||
|
# error Unknown pointer size
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifndef CONFIG_IOVEC
|
#ifndef CONFIG_IOVEC
|
||||||
#define CONFIG_IOVEC
|
#define CONFIG_IOVEC
|
||||||
struct iovec {
|
struct iovec {
|
||||||
|
|
Loading…
Reference in New Issue