added --disable-vararg_macros option to allow not using vararg macros even if they're supported (useful if the user code doesn't want to use C99 extensions)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43754 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
33dddf589a
commit
70c536f394
59
configure
vendored
59
configure
vendored
@ -965,6 +965,7 @@ Optional Features:
|
||||
--enable-no_exceptions create code without C++ exceptions handling
|
||||
--enable-permissive compile code disregarding strict ANSI
|
||||
--enable-no_deps create code without dependency information
|
||||
--disable-vararg_macros don't use vararg macros, even if they are supported
|
||||
--enable-universal_binary[=SDK] create Mac PowerPC and Intel Universal binary (not yet working)
|
||||
--enable-compat24 enable wxWidgets 2.4 compatibility
|
||||
--disable-compat26 disable wxWidgets 2.6 compatibility
|
||||
@ -2190,6 +2191,7 @@ if test $DEBUG_CONFIGURE = 1; then
|
||||
DEFAULT_wxUSE_OPTIMISE=no
|
||||
DEFAULT_wxUSE_PROFILE=no
|
||||
DEFAULT_wxUSE_NO_DEPS=no
|
||||
DEFAULT_wxUSE_VARARG_MACROS=no
|
||||
DEFAULT_wxUSE_NO_RTTI=no
|
||||
DEFAULT_wxUSE_NO_EXCEPTIONS=no
|
||||
DEFAULT_wxUSE_UNIVERSAL_BINARY=no
|
||||
@ -2413,6 +2415,7 @@ else
|
||||
DEFAULT_wxUSE_OPTIMISE=yes
|
||||
DEFAULT_wxUSE_PROFILE=no
|
||||
DEFAULT_wxUSE_NO_DEPS=no
|
||||
DEFAULT_wxUSE_VARARG_MACROS=yes
|
||||
DEFAULT_wxUSE_NO_RTTI=no
|
||||
DEFAULT_wxUSE_NO_EXCEPTIONS=no
|
||||
DEFAULT_wxUSE_UNIVERSAL_BINARY=no
|
||||
@ -4418,6 +4421,47 @@ echo "${ECHO_T}no" >&6
|
||||
fi
|
||||
|
||||
|
||||
enablestring=
|
||||
echo "$as_me:$LINENO: checking for --${enablestring:-enable}-vararg_macros" >&5
|
||||
echo $ECHO_N "checking for --${enablestring:-enable}-vararg_macros... $ECHO_C" >&6
|
||||
no_cache=0
|
||||
# Check whether --enable-vararg_macros or --disable-vararg_macros was given.
|
||||
if test "${enable_vararg_macros+set}" = set; then
|
||||
enableval="$enable_vararg_macros"
|
||||
|
||||
if test "$enableval" = yes; then
|
||||
ac_cv_use_vararg_macros='wxUSE_VARARG_MACROS=yes'
|
||||
else
|
||||
ac_cv_use_vararg_macros='wxUSE_VARARG_MACROS=no'
|
||||
fi
|
||||
|
||||
else
|
||||
|
||||
LINE=`grep "wxUSE_VARARG_MACROS" ${wx_arg_cache_file}`
|
||||
if test "x$LINE" != x ; then
|
||||
eval "DEFAULT_$LINE"
|
||||
else
|
||||
no_cache=1
|
||||
fi
|
||||
|
||||
ac_cv_use_vararg_macros='wxUSE_VARARG_MACROS='$DEFAULT_wxUSE_VARARG_MACROS
|
||||
|
||||
fi;
|
||||
|
||||
eval "$ac_cv_use_vararg_macros"
|
||||
if test "$no_cache" != 1; then
|
||||
echo $ac_cv_use_vararg_macros >> ${wx_arg_cache_file}.tmp
|
||||
fi
|
||||
|
||||
if test "$wxUSE_VARARG_MACROS" = yes; then
|
||||
echo "$as_me:$LINENO: result: yes" >&5
|
||||
echo "${ECHO_T}yes" >&6
|
||||
else
|
||||
echo "$as_me:$LINENO: result: no" >&5
|
||||
echo "${ECHO_T}no" >&6
|
||||
fi
|
||||
|
||||
|
||||
enablestring=
|
||||
echo "$as_me:$LINENO: checking for --${enablestring:-enable}-universal_binary" >&5
|
||||
echo $ECHO_N "checking for --${enablestring:-enable}-universal_binary... $ECHO_C" >&6
|
||||
@ -21597,6 +21641,8 @@ _ACEOF
|
||||
fi
|
||||
fi
|
||||
|
||||
if test "$wxUSE_VARARG_MACROS" = "yes"; then
|
||||
|
||||
echo "$as_me:$LINENO: checking whether the compiler supports variadic macros" >&5
|
||||
echo $ECHO_N "checking whether the compiler supports variadic macros... $ECHO_C" >&6
|
||||
if test "${wx_cv_have_variadic_macros+set}" = set; then
|
||||
@ -21679,6 +21725,7 @@ _ACEOF
|
||||
|
||||
fi
|
||||
|
||||
fi
|
||||
# Check whether --enable-largefile or --disable-largefile was given.
|
||||
if test "${enable_largefile+set}" = set; then
|
||||
enableval="$enable_largefile"
|
||||
@ -29201,7 +29248,7 @@ _ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
#include <X11/Intrinsic.h>
|
||||
#include <X11/Xlib.h>
|
||||
_ACEOF
|
||||
if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
|
||||
(eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
|
||||
@ -29228,7 +29275,7 @@ else
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
for ac_dir in $ac_x_header_dirs; do
|
||||
if test -r "$ac_dir/X11/Intrinsic.h"; then
|
||||
if test -r "$ac_dir/X11/Xlib.h"; then
|
||||
ac_x_includes=$ac_dir
|
||||
break
|
||||
fi
|
||||
@ -29242,18 +29289,18 @@ if test "$ac_x_libraries" = no; then
|
||||
# See if we find them without any special options.
|
||||
# Don't add to $LIBS permanently.
|
||||
ac_save_LIBS=$LIBS
|
||||
LIBS="-lXt $LIBS"
|
||||
LIBS="-lX11 $LIBS"
|
||||
cat >conftest.$ac_ext <<_ACEOF
|
||||
/* confdefs.h. */
|
||||
_ACEOF
|
||||
cat confdefs.h >>conftest.$ac_ext
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
#include <X11/Intrinsic.h>
|
||||
#include <X11/Xlib.h>
|
||||
int
|
||||
main ()
|
||||
{
|
||||
XtMalloc (0)
|
||||
XrmInitialize ()
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
@ -29291,7 +29338,7 @@ for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
|
||||
do
|
||||
# Don't even attempt the hair of trying to link an X program!
|
||||
for ac_extension in a so sl; do
|
||||
if test -r $ac_dir/libXt.$ac_extension; then
|
||||
if test -r $ac_dir/libX11.$ac_extension; then
|
||||
ac_x_libraries=$ac_dir
|
||||
break 2
|
||||
fi
|
||||
|
10
configure.in
10
configure.in
@ -378,6 +378,7 @@ if test $DEBUG_CONFIGURE = 1; then
|
||||
DEFAULT_wxUSE_OPTIMISE=no
|
||||
DEFAULT_wxUSE_PROFILE=no
|
||||
DEFAULT_wxUSE_NO_DEPS=no
|
||||
DEFAULT_wxUSE_VARARG_MACROS=no
|
||||
DEFAULT_wxUSE_NO_RTTI=no
|
||||
DEFAULT_wxUSE_NO_EXCEPTIONS=no
|
||||
DEFAULT_wxUSE_UNIVERSAL_BINARY=no
|
||||
@ -601,6 +602,7 @@ else
|
||||
DEFAULT_wxUSE_OPTIMISE=yes
|
||||
DEFAULT_wxUSE_PROFILE=no
|
||||
DEFAULT_wxUSE_NO_DEPS=no
|
||||
DEFAULT_wxUSE_VARARG_MACROS=yes
|
||||
DEFAULT_wxUSE_NO_RTTI=no
|
||||
DEFAULT_wxUSE_NO_EXCEPTIONS=no
|
||||
DEFAULT_wxUSE_UNIVERSAL_BINARY=no
|
||||
@ -930,6 +932,7 @@ WX_ARG_ENABLE(no_rtti, [ --enable-no_rtti create code without RTTI
|
||||
WX_ARG_ENABLE(no_exceptions, [ --enable-no_exceptions create code without C++ exceptions handling], wxUSE_NO_EXCEPTIONS)
|
||||
WX_ARG_ENABLE(permissive, [ --enable-permissive compile code disregarding strict ANSI], wxUSE_PERMISSIVE)
|
||||
WX_ARG_ENABLE(no_deps, [ --enable-no_deps create code without dependency information], wxUSE_NO_DEPS)
|
||||
WX_ARG_ENABLE(vararg_macros, [ --disable-vararg_macros don't use vararg macros, even if they are supported], wxUSE_VARARG_MACROS)
|
||||
WX_ARG_ENABLE_PARAM(universal_binary, [[ --enable-universal_binary[=SDK] create Mac PowerPC and Intel Universal binary (not yet working)]], wxUSE_UNIVERSAL_BINARY)
|
||||
|
||||
WX_ARG_ENABLE(compat24, [ --enable-compat24 enable wxWidgets 2.4 compatibility], WXWIN_COMPATIBILITY_2_4, enable)
|
||||
@ -1968,6 +1971,11 @@ else
|
||||
fi
|
||||
fi
|
||||
|
||||
dnl don't check for vararg macros if they're explicitly disabled: this is
|
||||
dnl useful if the user code using the library wants to limit itself to standard
|
||||
dnl C++ only (e.g. is compiled with g++ -std=c++98)
|
||||
if test "$wxUSE_VARARG_MACROS" = "yes"; then
|
||||
|
||||
dnl Check if variadic macros (C99 feature) are supported:
|
||||
AC_CACHE_CHECK(
|
||||
[whether the compiler supports variadic macros],
|
||||
@ -1997,6 +2005,8 @@ if test $wx_cv_have_variadic_macros = "yes"; then
|
||||
AC_DEFINE(HAVE_VARIADIC_MACROS)
|
||||
fi
|
||||
|
||||
fi dnl wxUSE_VARARG_MACROS == yes
|
||||
|
||||
dnl check for large file support
|
||||
AC_SYS_LARGEFILE
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user