check if the compiler accepts -fno-rtti -fno-exceptions

SVN revision: 41882
This commit is contained in:
Vincent Torri 2009-08-20 08:45:20 +00:00
parent a1b88ea911
commit f29149beab
2 changed files with 18 additions and 1 deletions

View File

@ -198,6 +198,23 @@ case "$host_os" in
esac
AC_SUBST(WIN32_CFLAGS)
EXPEDITE_CXXFLAGS=""
AC_LANG_PUSH([C++])
CXXFLAGS_save="${CXXFLAGS}"
CXXFLAGS="${CXXFLAGS} -fno-rtti -fno-exceptions"
AC_COMPILE_IFELSE(
[AC_LANG_PROGRAM([[]])],
[have_cxx_flags="yes"],
[have_cxx_flags="no"])
AC_MSG_CHECKING([whether the compiler supports -fno-rtti -fno-exceptions])
AC_MSG_RESULT([${have_cxx_flags}])
CXXFLAGS="${CXXFLAGS_save}"
if test "x${have_cxx_flags}" = "xyes" ; then
EXPEDITE_CXXFLAGS="-fno-rtti -fno-exceptions"
fi
AC_LANG_POP([C++])
AC_SUBST(EXPEDITE_CXXFLAGS)
### Checks for linker characteristics

View File

@ -77,7 +77,7 @@ image_blend_occlude3_very_many.c \
poly_blend.c
expedite_CFLAGS = @WIN32_CFLAGS@
expedite_CXXFLAGS = -fno-rtti -fno-exceptions
expedite_CXXFLAGS = @EXPEDITE_CXXFLAGS@
expedite_LDADD = @EVAS_LIBS@ @SDL_LIBS@ @x_libs@ @gdi_libs@ @ddraw_libs@ @ddraw_16_libs@ @d3d_libs@ @wince_16_libs@ @glew_libs@ @DIRECTFB_LIBS@ @XCB_LIBS@ @EVIL_LIBS@ @quartz_libs@ -lm
expedite_LDFLAGS = @lt_enable_auto_import@