makefiles: Don't use -fno-builtin flag with MinGW.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
1f0a9c4c29
commit
629f2e10b1
|
@ -632,8 +632,8 @@ POLL_LIBS
|
|||
DL_LIBS
|
||||
TOOLSEXT
|
||||
UNWINDFLAGS
|
||||
EXCESS_PRECISION_CFLAGS
|
||||
BUILTINFLAG
|
||||
EXCESS_PRECISION_CFLAGS
|
||||
EXTRACFLAGS
|
||||
VKD3D_LIBS
|
||||
VKD3D_CFLAGS
|
||||
|
@ -16568,33 +16568,7 @@ $as_echo "$ac_cv_c_gcc_strength_bug" >&6; }
|
|||
EXTRACFLAGS="$EXTRACFLAGS -fno-strength-reduce"
|
||||
fi
|
||||
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -fno-builtin" >&5
|
||||
$as_echo_n "checking whether the compiler supports -fno-builtin... " >&6; }
|
||||
if ${ac_cv_cflags__fno_builtin+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
ac_wine_try_cflags_saved=$CFLAGS
|
||||
CFLAGS="$CFLAGS -fno-builtin"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
int main(int argc, char **argv) { return 0; }
|
||||
_ACEOF
|
||||
if ac_fn_c_try_link "$LINENO"; then :
|
||||
ac_cv_cflags__fno_builtin=yes
|
||||
else
|
||||
ac_cv_cflags__fno_builtin=no
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext \
|
||||
conftest$ac_exeext conftest.$ac_ext
|
||||
CFLAGS=$ac_wine_try_cflags_saved
|
||||
fi
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cflags__fno_builtin" >&5
|
||||
$as_echo "$ac_cv_cflags__fno_builtin" >&6; }
|
||||
if test "x$ac_cv_cflags__fno_builtin" = xyes; then :
|
||||
BUILTINFLAG="-fno-builtin"
|
||||
|
||||
fi
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -fno-strict-aliasing" >&5
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -fno-strict-aliasing" >&5
|
||||
$as_echo_n "checking whether the compiler supports -fno-strict-aliasing... " >&6; }
|
||||
if ${ac_cv_cflags__fno_strict_aliasing+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
|
@ -17113,6 +17087,36 @@ fi ;;
|
|||
esac
|
||||
done
|
||||
|
||||
case $host_os in
|
||||
cygwin*|mingw32*) ;;
|
||||
*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -fno-builtin" >&5
|
||||
$as_echo_n "checking whether the compiler supports -fno-builtin... " >&6; }
|
||||
if ${ac_cv_cflags__fno_builtin+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
ac_wine_try_cflags_saved=$CFLAGS
|
||||
CFLAGS="$CFLAGS -fno-builtin"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
int main(int argc, char **argv) { return 0; }
|
||||
_ACEOF
|
||||
if ac_fn_c_try_link "$LINENO"; then :
|
||||
ac_cv_cflags__fno_builtin=yes
|
||||
else
|
||||
ac_cv_cflags__fno_builtin=no
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext \
|
||||
conftest$ac_exeext conftest.$ac_ext
|
||||
CFLAGS=$ac_wine_try_cflags_saved
|
||||
fi
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cflags__fno_builtin" >&5
|
||||
$as_echo "$ac_cv_cflags__fno_builtin" >&6; }
|
||||
if test "x$ac_cv_cflags__fno_builtin" = xyes; then :
|
||||
BUILTINFLAG="-fno-builtin"
|
||||
|
||||
fi ;;
|
||||
esac
|
||||
|
||||
case $host_cpu in
|
||||
*i[3456789]86*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -fno-omit-frame-pointer" >&5
|
||||
$as_echo_n "checking whether the compiler supports -fno-omit-frame-pointer... " >&6; }
|
||||
|
|
|
@ -1937,7 +1937,6 @@ then
|
|||
fi
|
||||
|
||||
dnl Check for some compiler flags
|
||||
WINE_TRY_CFLAGS([-fno-builtin],[AC_SUBST(BUILTINFLAG,"-fno-builtin")])
|
||||
WINE_TRY_CFLAGS([-fno-strict-aliasing])
|
||||
WINE_TRY_CFLAGS([-fexcess-precision=standard],[AC_SUBST(EXCESS_PRECISION_CFLAGS,"-fexcess-precision=standard")])
|
||||
dnl clang needs to be told to fail on unknown options
|
||||
|
@ -1984,6 +1983,12 @@ char*f(const char *h,char n) {return strchr(h,n);}]])],[ac_cv_c_logicalop_noisy=
|
|||
esac
|
||||
done
|
||||
|
||||
dnl Disable gcc builtins except for Mingw
|
||||
case $host_os in
|
||||
cygwin*|mingw32*) ;;
|
||||
*) WINE_TRY_CFLAGS([-fno-builtin],[AC_SUBST(BUILTINFLAG,"-fno-builtin")]) ;;
|
||||
esac
|
||||
|
||||
dnl gcc-4.6+ omits frame pointers by default, breaking some copy protections
|
||||
case $host_cpu in
|
||||
*i[[3456789]]86*) WINE_TRY_CFLAGS([-fno-omit-frame-pointer]) ;;
|
||||
|
|
|
@ -2990,7 +2990,6 @@ static void output_source_default( struct makefile *make, struct incl_file *sour
|
|||
output_filenames( make->include_args );
|
||||
output_filenames( make->define_args );
|
||||
output_filenames( extradefs );
|
||||
if (make->use_msvcrt) output_filenames( msvcrt_flags );
|
||||
output_filenames( extra_cross_cflags );
|
||||
output_filenames( cpp_flags );
|
||||
output_filename( "$(CROSSCFLAGS)" );
|
||||
|
|
Loading…
Reference in New Issue