X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/3f345b477e74ef2b81e4d757587bd0958a0a1641..8916d00747c8e7b704ad549afcd8d0f88b6d861e:/configure.in?ds=sidebyside diff --git a/configure.in b/configure.in index 79abcc27b1..eb66fb25ad 100644 --- a/configure.in +++ b/configure.in @@ -365,14 +365,14 @@ dnl libwx_$(TOOLKIT)-$(WX_RELEASE).so.$(WX_CURRENT).$(WX_REVISION).$(WX_AGE) WX_MAJOR_VERSION_NUMBER=2 WX_MINOR_VERSION_NUMBER=3 -WX_RELEASE_NUMBER=2 +WX_RELEASE_NUMBER=3 WX_VERSION=$WX_MAJOR_VERSION_NUMBER.$WX_MINOR_VERSION_NUMBER.$WX_RELEASE_NUMBER WX_RELEASE=$WX_MAJOR_VERSION_NUMBER.$WX_MINOR_VERSION_NUMBER WX_MSW_VERSION=$WX_MAJOR_VERSION_NUMBER$WX_MINOR_VERSION_NUMBER$WX_RELEASE_NUMBER -WX_CURRENT=1 +WX_CURRENT=2 WX_REVISION=0 WX_AGE=0 @@ -384,6 +384,7 @@ dnl ------------------------------------------------------------------------ dnl assume Unix USE_UNIX=1 USE_WIN32=0 +USE_DOS=0 USE_BEOS=0 USE_MAC=0 @@ -561,6 +562,15 @@ case "${host}" in DEFAULT_DEFAULT_wxUSE_MSW=1 ;; + *-pc-msdosdjgpp ) + USE_UNIX=0 + USE_DOS=1 + AC_DEFINE(__DOS__) + PROGRAM_EXT=".exe" + DEFAULT_DEFAULT_wxUSE_MGL=1 + DEFAULT_DEFAULT_wxUSE_SHARED=0 + ;; + *-pc-os2_emx | *-pc-os2-emx ) AC_DEFINE(__EMX__) PROGRAM_EXT=".exe" @@ -689,9 +699,9 @@ if test $DEBUG_CONFIGURE = 1; then DEFAULT_wxUSE_STREAMS=no DEFAULT_wxUSE_SOCKETS=no DEFAULT_wxUSE_DIALUP_MANAGER=no - DEFAULT_wxUSE_SERIAL=no DEFAULT_wxUSE_JOYSTICK=no DEFAULT_wxUSE_DYNLIB_CLASS=no + DEFAULT_wxUSE_DYNAMIC_LOADER=no DEFAULT_wxUSE_LONGLONG=no DEFAULT_wxUSE_GEOMETRY=no @@ -853,9 +863,9 @@ else DEFAULT_wxUSE_STREAMS=yes DEFAULT_wxUSE_SOCKETS=yes DEFAULT_wxUSE_DIALUP_MANAGER=yes - DEFAULT_wxUSE_SERIAL=yes DEFAULT_wxUSE_JOYSTICK=yes - DEFAULT_wxUSE_DYNLIB_CLASS=yes + DEFAULT_wxUSE_DYNLIB_CLASS=no + DEFAULT_wxUSE_DYNAMIC_LOADER=yes DEFAULT_wxUSE_LONGLONG=yes DEFAULT_wxUSE_GEOMETRY=yes @@ -1073,6 +1083,7 @@ WX_ARG_ENABLE(timer, [ --enable-timer use wxTimer class], wxUS WX_ARG_ENABLE(wave, [ --enable-wave use wxWave class], wxUSE_WAVE) WX_ARG_ENABLE(fraction, [ --enable-fraction use wxFraction class], wxUSE_FRACTION) WX_ARG_ENABLE(dynlib, [ --enable-dynlib use wxLibrary class for DLL loading], wxUSE_DYNLIB_CLASS) +WX_ARG_ENABLE(dynamicloader, [ --enable-dynamicloader use (new) wxDynamicLibrary class], wxUSE_DYNAMIC_LOADER) WX_ARG_ENABLE(longlong, [ --enable-longlong use wxLongLong class], wxUSE_LONGLONG) WX_ARG_ENABLE(geometry, [ --enable-geometry use geometry class], wxUSE_GEOMETRY) WX_ARG_ENABLE(log, [ --enable-log use logging system], wxUSE_LOG) @@ -1101,7 +1112,6 @@ dnl "big" options (i.e. those which change a lot of things throughout the librar dnl --------------------------------------------------------------------------- WX_ARG_ENABLE(threads, [ --enable-threads use threads], wxUSE_THREADS) -WX_ARG_ENABLE(serial, [ --enable-serial use class serialization], wxUSE_SERIAL) if test "$wxUSE_GUI" = "yes"; then @@ -1419,7 +1429,7 @@ AC_CACHE_SAVE dnl cross-compiling support: we're cross compiling if the build system is dnl different from the target one (assume host and target be always the same) if test "$build" != "$host" ; then - if test "$USE_WIN32" = 1 ; then + if test "$USE_WIN32" = 1 -o "$USE_DOS" = 1 ; then CC=$host_alias-gcc CXX=$host_alias-c++ AR=$host_alias-ar @@ -2031,8 +2041,6 @@ equivalent variable and GTK+ is version 1.2.3 or above. fi if test "$wxUSE_MGL" = 1; then - dnl FIXME_MGL - test for MGL's variants for freebsd etc. - AC_MSG_CHECKING(for SciTech MGL library) if test "x$MGL_ROOT" = x ; then AC_MSG_RESULT(not found) @@ -2041,7 +2049,19 @@ equivalent variable and GTK+ is version 1.2.3 or above. AC_MSG_RESULT($MGL_ROOT) fi - mgl_os=linux/gcc/glibc + dnl Find MGL library that we want + dnl FIXME_MGL - test for MGL variants for freebsd etc. + case "${host}" in + *-*-linux* ) + mgl_os=linux/gcc/glibc + ;; + *-pc-msdosdjgpp ) + mgl_os=dos32/dj2 + ;; + *) + AC_MSG_ERROR(This system type ${host} is not yet supported by wxMGL.) + esac + mgl_lib_type="" if test "$wxUSE_DEBUG_FLAG" = yes ; then @@ -2254,7 +2274,7 @@ equivalent variable and GTK+ is version 1.2.3 or above. ALL_OBJECTS="${ALL_OBJECTS} \$(COMMONOBJS) \$(GENERICOBJS)" - if test "$TOOLKIT" != "MSW"; then + if test "$TOOLKIT" != "MSW" -a "$USE_DOS" != 1; then ALL_OBJECTS="${ALL_OBJECTS} \$(UNIXOBJS)" fi @@ -2901,20 +2921,21 @@ AC_FUNC_VPRINTF dnl check for vsscanf() and vsnprintf() - on some platforms (Linux, glibc dnl 2.1.1 for the first one, HP-UX for the second) it's available in the -dnl library but the prototype is missing, so we can't use AC_CHECK_FUNCS here, -dnl do it manually +dnl library but the prototype is missing, so we can't use AC_CHECK_FUNCS() here, +dnl do it manually. We can't use AC_TRY_COMPILE(), either, because it doesn't +dnl check if the symbol is available at linking time -dnl we use AC_TRY_COMPILE() here instead of AC_TRY_RUN() to make the checks -dnl work for cross-compilation, but AC_TRY_COMPILE() normally only compiles +dnl we use AC_TRY_LINK() here instead of AC_TRY_RUN() to make the checks +dnl work for cross-compilation, but AC_TRY_LINK() normally only compiles dnl one function while we need at least 2 - hence the ugly hack below. To -dnl understand why it works, remember that AC_TRY_COMPILE() just prepends +dnl understand why it works, remember that AC_TRY_LINK() just prepends dnl "int main() {" in the beginning of the code and "; return 0; }" at the dnl end... dnl if we fail to find vsnprintf, also try for _vsnprintf as that is what dnl we'll find under MSW if it exists. -dnl final note: AC_TRY_COMPILE will only be executed if there is nothing in +dnl final note: AC_TRY_LINK will only be executed if there is nothing in dnl the cache so we have to do AC_DEFINE(HAVE_VSNPRINTF) below and not inside dnl it or the symbol wouldn't be defined for the 2nd and subsequent configure dnl runs @@ -2922,7 +2943,7 @@ dnl runs dnl check for vsnprintf() - a safe version of vsprintf() AC_CACHE_CHECK([for vsnprintf], wx_cv_func_vsnprintf, [ - AC_TRY_COMPILE([ + AC_TRY_LINK([ #include #include ], [ @@ -2943,7 +2964,7 @@ AC_CACHE_CHECK([for vsnprintf], wx_cv_func_vsnprintf, ], [ wx_cv_func_vsnprintf=yes ], [ - AC_TRY_COMPILE([ + AC_TRY_LINK([ #include #include ], [ @@ -2972,7 +2993,7 @@ AC_CACHE_CHECK([for vsnprintf], wx_cv_func_vsnprintf, if test "$wx_cv_func_vsnprintf" = yes; then AC_DEFINE(HAVE_VSNPRINTF) else - AC_MSG_WARN(unsafe function sprintf will be used instead of snprintf) + AC_MSG_WARN(unsafe function vsprintf will be used instead of vsnprintf) fi dnl check for vsscanf() @@ -3773,7 +3794,11 @@ if test "$wxUSE_DATETIME" = "yes"; then [ wx_cv_var_timezone=__timezone ], - AC_MSG_ERROR(no timezone variable) + [ + if test "$USE_DOS" = 0 ; then + AC_MSG_ERROR(no timezone variable) + fi + ] ) ] ) @@ -3783,7 +3808,9 @@ if test "$wxUSE_DATETIME" = "yes"; then ) dnl as we want $wx_cv_var_timezone to be expanded, use AC_DEFINE_UNQUOTED - AC_DEFINE_UNQUOTED(WX_TIMEZONE, $wx_cv_var_timezone) + if test "x$wx_cv_var_timezone" != x ; then + AC_DEFINE_UNQUOTED(WX_TIMEZONE, $wx_cv_var_timezone) + fi dnl check for localtime (it's POSIX, but the check can do no harm...) AC_CHECK_FUNCS(localtime) @@ -3989,7 +4016,7 @@ if test "$TOOLKIT" != "MSW"; then HAVE_DL_FUNCS=0 HAVE_SHL_FUNCS=0 - if test "$wxUSE_DYNLIB_CLASS" = "yes"; then + if test "$wxUSE_DYNAMIC_LOADER" = "yes" -o "$wxUSE_DYNLIB_CLASS" = "yes" ; then if test "$USE_DARWIN" = 1; then dnl dlopen/dlerror is implemented in dynlib.cpp for Darwin/Mac OS X HAVE_DL_FUNCS=1 @@ -4037,6 +4064,7 @@ if test "$TOOLKIT" != "MSW"; then if test "$HAVE_SHL_FUNCS" = 0; then if test "$USE_UNIX" = 1; then AC_MSG_WARN([Missing dynamic loading support, several features will be disabled]) + wxUSE_DYNAMIC_LOADER=no wxUSE_DYNLIB_CLASS=no else AC_MSG_WARN([Assuming wxLibrary class works on this platform]) @@ -4046,11 +4074,10 @@ if test "$TOOLKIT" != "MSW"; then fi fi -if test "$wxUSE_DYNLIB_CLASS" = "yes" ; then +if test "$wxUSE_DYNAMIC_LOADER" = "yes" ; then + AC_DEFINE(wxUSE_DYNAMIC_LOADER) +elif test "$wxUSE_DYNLIB_CLASS" = "yes" ; then AC_DEFINE(wxUSE_DYNLIB_CLASS) -else - wxUSE_ODBC=no - wxUSE_SERIAL=no fi dnl --------------------------------------------------------------------------- @@ -4069,13 +4096,6 @@ if test "$wxUSE_wxUSE_EXPERIMENTAL_PRINTF" = "yes"; then AC_DEFINE(wxUSE_EXPERIMENTAL_PRINTF) fi -dnl ---------------------------------------------------------------- -dnl serialization support -dnl ---------------------------------------------------------------- - -if test "$wxUSE_SERIAL" = "yes" ; then - AC_DEFINE(wxUSE_SERIAL) -fi dnl ---------------------------------------------------------------- dnl iODBC support