configure: Define _WIN64 when building on a 64-bit platform.
This commit is contained in:
parent
945292737b
commit
58c64190f4
|
@ -24167,6 +24167,37 @@ if test $ac_cv_cpp_def___x86_64__ = yes; then
|
|||
CFLAGS="$CFLAGS -D__x86_64__"
|
||||
LINTFLAGS="$LINTFLAGS -D__x86_64__"
|
||||
fi
|
||||
|
||||
{ echo "$as_me:$LINENO: checking whether we need to define _WIN64" >&5
|
||||
echo $ECHO_N "checking whether we need to define _WIN64... $ECHO_C" >&6; }
|
||||
if test "${ac_cv_cpp_def__WIN64+set}" = set; then
|
||||
echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||
else
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
#ifndef _WIN64
|
||||
yes
|
||||
#endif
|
||||
_ACEOF
|
||||
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
|
||||
$EGREP "yes" >/dev/null 2>&1; then
|
||||
ac_cv_cpp_def__WIN64=yes
|
||||
else
|
||||
ac_cv_cpp_def__WIN64=no
|
||||
fi
|
||||
rm -f conftest*
|
||||
|
||||
fi
|
||||
{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def__WIN64" >&5
|
||||
echo "${ECHO_T}$ac_cv_cpp_def__WIN64" >&6; }
|
||||
if test $ac_cv_cpp_def__WIN64 = yes; then
|
||||
CFLAGS="$CFLAGS -D_WIN64"
|
||||
LINTFLAGS="$LINTFLAGS -D_WIN64"
|
||||
fi
|
||||
;;
|
||||
*alpha*) { echo "$as_me:$LINENO: checking whether we need to define __ALPHA__" >&5
|
||||
echo $ECHO_N "checking whether we need to define __ALPHA__... $ECHO_C" >&6; }
|
||||
|
|
|
@ -1502,7 +1502,8 @@ dnl *** check for the need to define platform-specific symbols
|
|||
|
||||
case $host_cpu in
|
||||
*i[[3456789]]86*) WINE_CHECK_DEFINE([__i386__]) ;;
|
||||
*x86_64*) WINE_CHECK_DEFINE([__x86_64__]) ;;
|
||||
*x86_64*) WINE_CHECK_DEFINE([__x86_64__])
|
||||
WINE_CHECK_DEFINE([_WIN64]) ;;
|
||||
*alpha*) WINE_CHECK_DEFINE([__ALPHA__]) ;;
|
||||
*sparc*) WINE_CHECK_DEFINE([__sparc__]) ;;
|
||||
*powerpc*) WINE_CHECK_DEFINE([__powerpc__]) ;;
|
||||
|
|
|
@ -38,7 +38,7 @@ extern "C" {
|
|||
* type model where int and long are 32 bit and pointer is 64-bit.
|
||||
*/
|
||||
|
||||
#ifdef __x86_64__
|
||||
#if defined(__x86_64__) && !defined(_WIN64)
|
||||
#define _WIN64
|
||||
#endif
|
||||
|
||||
|
|
|
@ -45,7 +45,7 @@ extern "C" {
|
|||
# define __i386__
|
||||
#endif
|
||||
|
||||
#ifdef __x86_64__
|
||||
#if defined(__x86_64__) && !defined(_WIN64)
|
||||
#define _WIN64
|
||||
#endif
|
||||
|
||||
|
|
|
@ -269,10 +269,17 @@ static void compile(struct options* opts, const char* lang)
|
|||
strarray_addall(comp_args, strarray_fromstring(DLLFLAGS, " "));
|
||||
}
|
||||
|
||||
#ifdef _WIN64
|
||||
strarray_add(comp_args, "-DWIN64");
|
||||
strarray_add(comp_args, "-D_WIN64");
|
||||
strarray_add(comp_args, "-D__WIN64");
|
||||
strarray_add(comp_args, "-D__WIN64__");
|
||||
#else
|
||||
strarray_add(comp_args, "-DWIN32");
|
||||
strarray_add(comp_args, "-D_WIN32");
|
||||
strarray_add(comp_args, "-D__WIN32");
|
||||
strarray_add(comp_args, "-D__WIN32__");
|
||||
#endif
|
||||
strarray_add(comp_args, "-D__WINNT");
|
||||
strarray_add(comp_args, "-D__WINNT__");
|
||||
|
||||
|
|
Loading…
Reference in New Issue