X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c6712985beea6546e87f3d2eaaf81458e4027d7e..f74ff5efa5604fcde3cc5ba9009cb015a6f388cf:/configure.in diff --git a/configure.in b/configure.in index c1d9d436d0..3c503999c2 100644 --- a/configure.in +++ b/configure.in @@ -261,6 +261,7 @@ case "${host}" in AC_DEFINE(__EMX__) PROGRAM_EXT=".exe" DEFAULT_DEFAULT_wxUSE_PM=1 + LIBS="$LIBS -lstdcpp" ;; powerpc-*-darwin* ) @@ -561,7 +562,7 @@ else DEFAULT_wxUSE_DIALUP_MANAGER=yes DEFAULT_wxUSE_JOYSTICK=yes DEFAULT_wxUSE_DYNLIB_CLASS=yes - DEFAULT_wxUSE_DYNAMIC_LOADER=no + DEFAULT_wxUSE_DYNAMIC_LOADER=yes DEFAULT_wxUSE_LONGLONG=yes DEFAULT_wxUSE_GEOMETRY=yes @@ -716,7 +717,7 @@ AC_ARG_WITH(msw, [ --with-msw use MS-Windows], [wxUSE_MS AC_ARG_WITH(pm, [ --with-pm use OS/2 Presentation Manager], [wxUSE_PM="$withval" CACHE_PM=1 TOOLKIT_GIVEN=1]) AC_ARG_WITH(mgl, [ --with-mgl use SciTech MGL], [wxUSE_MGL="$withval" CACHE_MGL=1 TOOLKIT_GIVEN=1]) AC_ARG_WITH(microwin, [ --with-microwin use MicroWindows], [wxUSE_MICROWIN="$withval" CACHE_MICROWIN=1 TOOLKIT_GIVEN=1]) -AC_ARG_WITH(x11, [ --with-x11 use X11], [wxUSE_X11="$withval" CACHE_X11=1 TOOLKIT_GIVEN=1]) +AC_ARG_WITH(x11, [ --with-x11 use X11], [wxUSE_X11="$withval" wxUSE_UNIVERSAL="yes" CACHE_X11=1 TOOLKIT_GIVEN=1]) WX_ARG_ENABLE(nanox, [ --enable-nanox use NanoX], wxUSE_NANOX) AC_ARG_ENABLE(gtk2, [ --enable-gtk2 use GTK+ 2.0 if available (EXPERIMENTAL)],wxUSE_GTK2=1,wxUSE_GTK2=0) @@ -766,7 +767,7 @@ WX_ARG_ENABLE(permissive, [ --enable-permissive compile code disregardin WX_ARG_ENABLE(no_deps, [ --enable-no_deps create code without dependency information], wxUSE_NO_DEPS) WX_ARG_ENABLE(compat20, [ --enable-compat20 enable wxWindows 2.0 compatibility], WXWIN_COMPATIBILITY_2) -WX_ARG_ENABLE(compat22, [ --enable-compat22 enable wxWindows 2.2 compatibility], WXWIN_COMPATIBILITY_2_2) +WX_ARG_ENABLE(compat22, [ --disable-compat22 disable wxWindows 2.2 compatibility], WXWIN_COMPATIBILITY_2_2) dnl --------------------------------------------------------------------------- dnl (small) optional non GUI classes @@ -1053,6 +1054,21 @@ WX_ARG_ENABLE(xpm, [ --enable-xpm use xpm images (XPM file f WX_ARG_ENABLE(ico_cur, [ --enable-icocur use Windows ICO and CUR formats], wxUSE_ICO_CUR) fi + +dnl General settings (needed for GUI and non-GUI compilations alike). +dnl Path separator; ':' for unix, ';' for OS/2 +dnl Stem for flex output; lexyy for OS/2, lex.yy otherwise +case "${host}" in + *-pc-os2_emx | *-pc-os2-emx ) + dnl PATH_IFS is autodetected by OS/2's configure (usually ';') + LEX_STEM="lexyy" + ;; + *) + PATH_IFS=':' + LEX_STEM="lex.yy" + ;; +esac + dnl for GUI only dnl cache the options values before (may be) aborting below @@ -1094,18 +1110,9 @@ if test "$wxUSE_GUI" = "yes"; then + ${wxUSE_WINE:-0} + ${wxUSE_MSW:-0} + ${wxUSE_MGL:-0} + ${wxUSE_MICROWIN:-0} + ${wxUSE_X11:-0}` dnl Allow wxUSE_PM only for OS/2 with EMX. - dnl Path separator; ':' for unix. - dnl Stem for flex output; lexyy for OS/2, lex.yy otherwise case "${host}" in *-pc-os2_emx | *-pc-os2-emx ) - # PATH_IFS is autodetected by OS/2's configure (usually ';') NUM_TOOLKITS=`expr ${NUM_TOOLKITS} + ${wxUSE_PM:-0}` - LEX_STEM="lexyy" - ;; - *) - PATH_IFS=':' - LEX_STEM="lex.yy" - ;; esac case "$NUM_TOOLKITS" in @@ -1135,7 +1142,6 @@ if test "$wxUSE_GUI" = "yes"; then fi done else - PATH_IFS=':' AC_MSG_RESULT(base ($host_alias hosted) only) fi @@ -1223,7 +1229,7 @@ dnl does make support "-include" (only GNU make does AFAIK)? AC_CACHE_CHECK([if make is GNU make], wx_cv_prog_makeisgnu, [ if ( ${SHELL-sh} -c "${MAKE-make} --version" 2> /dev/null | - egrep -s GNU); then + egrep -s GNU > /dev/null); then wx_cv_prog_makeisgnu="yes" else wx_cv_prog_makeisgnu="no" @@ -1854,13 +1860,14 @@ equivalent variable and GTK+ is version 1.2.3 or above. AFMINSTALL=afminstall COMPILED_X_PROGRAM=0 - if test "$wxUSE_NANOX" = 1; then + if test "$wxUSE_NANOX" = "yes"; then AC_MSG_CHECKING(for MicroWindows/NanoX distribution) if test "x$MICROWIN" = x ; then AC_MSG_RESULT(not found) AC_MSG_ERROR([Cannot find MicroWindows library. Make sure MICROWIN is set.]) else AC_MSG_RESULT($MICROWIN) + AC_DEFINE(wxUSE_NANOX) fi fi @@ -1895,16 +1902,15 @@ equivalent variable and GTK+ is version 1.2.3 or above. ) fi - if test "$wxUSE_NANOX" = 1; then + if test "$wxUSE_NANOX" = "yes"; then TOOLKIT_INCLUDE="-I\$(top_srcdir)/include/wx/x11/nanox -I\$(MICROWIN)/src/include $TOOLKIT_INCLUDE" - TOOLCHAIN_DEFS="${TOOLCHAIN_DEFS} -D__WXUNIVERSAL__ -D__NANOX__" - GUI_TK_LIBRARY="$GUI_TK_LIBRARY \$MICROWIN/src/lib/libnano-X.a \$MICROWIN/src/lib/libmwengine.a \$MICROWIN/src/lib/libmwfonts.a \$MICROWIN/src/lib/libmwdrivers.a \$MICROWIN/src/lib/libmwobjects.a" + TOOLCHAIN_DEFS="${TOOLCHAIN_DEFS} -D__NANOX__ -DMWPIXEL_FORMAT=MWPF_TRUECOLOR0888 -DHAVE_FILEIO -DHAVE_BMP_SUPPORT=1 -DHAVE_GIF_SUPPORT=1 -DHAVE_PNM_SUPPORT=1 -DHAVE_XPM_SUPPORT=1 -DLINUX=1 -DUNIX=1 -O -DUSE_EXPOSURE -DSCREEN_HEIGHT=480 -DSCREEN_WIDTH=640 -DSCREEN_DEPTH=4 -DX11=1" + GUI_TK_LIBRARY="$GUI_TK_LIBRARY \$(MICROWIN)/src/lib/libnano-X.a" else - TOOLCHAIN_DEFS="${TOOLCHAIN_DEFS} -D__WXUNIVERSAL__" - GUI_TK_LIBRARY="$GUI_TK_LIBRARY -lX11" + GUI_TK_LIBRARY="$GUI_TK_LIBRARY -lX11$xpm_link" fi - TOOLKIT_VPATH="\${top_srcdir}/src/x11 \${top_srcdir}/src/univ \${top_srcdir}/src/univ/themes" + TOOLKIT_VPATH="\${top_srcdir}/src/x11" TOOLKIT=X11 GUIDIST=X11_DIST fi @@ -2512,6 +2518,10 @@ if test "$wxUSE_MAC" = 1; then LIBWXMACRES="\$(top_builddir)/lib/lib${WX_LIBRARY}.r" LIBWXMACRESCOMP="\$(RESCOMP) Carbon.r -t APPL ${LIBWXMACRES} -o \$(BIN_PROGRAM)" LIBWXMACRESWXCONFIG="${RESCOMP} Carbon.r -t APPL \${prefix}/lib/${WX_RESOURCES_MACOSX_COMPILED} -o" +else + if test "$wxUSE_PM" = 1; then + LIBWXMACRESCOMP="emxbind -ep \$(BIN_PROGRAM)" + fi fi dnl ------------------------------------------------------------------------ @@ -3408,7 +3418,7 @@ if test "$WXWIN_COMPATIBILITY_2" = "yes"; then WXWIN_COMPATIBILITY_2_2="yes" fi -if test "$WXWIN_COMPATIBILITY_2_2" = "yes"; then +if test "x$WXWIN_COMPATIBILITY_2_2" != "xno"; then AC_DEFINE(WXWIN_COMPATIBILITY_2_2) fi @@ -3724,14 +3734,23 @@ dnl ------------------------------------------------------------------------ dnl wxSocket dnl ------------------------------------------------------------------------ -dnl under MSW we always have sockets -if test "$TOOLKIT" != "MSW"; then +dnl VZ: the GUI hooks wxSocket needs are not implemented yet in wxX11 +if test "$wxUSE_SOCKETS" = "yes"; then + if test "$TOOLKIT" = "X11"; then + AC_MSG_WARN([wxSocket not yet supported under X11... disabled]) + wxUSE_SOCKETS="no" + fi +fi - if test "$wxUSE_SOCKETS" = "yes"; then - dnl under Solaris, socket functions live in -lsocket +if test "$wxUSE_SOCKETS" = "yes"; then + dnl under MSW we always have sockets + if test "$TOOLKIT" != "MSW"; then + dnl under Solaris and OS/2, socket functions live in -lsocket AC_CHECK_FUNC(socket,, AC_CHECK_LIB(socket, socket, - INET_LINK="$INET_LINK -lsocket", + if test "$INET_LINK" != " -lsocket"; then + INET_LINK="$INET_LINK -lsocket" + fi, [ AC_MSG_WARN([socket library not found - sockets will be disabled]) wxUSE_SOCKETS=no @@ -3739,12 +3758,13 @@ if test "$TOOLKIT" != "MSW"; then ) ) fi +fi +if test "$wxUSE_SOCKETS" = "yes" ; then dnl this test may be appropriate if building under cygwin dnl right now I'm assuming it also uses the winsock stuff dnl like mingw does.. -- RL - - if test "$wxUSE_SOCKETS" = "yes" ; then + if test "$TOOLKIT" != "MSW"; then dnl determine the type of third argument for getsockname AC_CACHE_CHECK([what is the type of the third argument of getsockname], wx_cv_type_getsockname3, @@ -3798,7 +3818,6 @@ if test "$TOOLKIT" != "MSW"; then fi fi fi -dnl if !MSW if test "$wxUSE_SOCKETS" = "yes" ; then AC_DEFINE(wxUSE_SOCKETS) @@ -3978,7 +3997,7 @@ fi if test "$wxUSE_MDI_ARCHITECTURE" = "yes"; then if test "$wxUSE_UNIVERSAL" = "yes"; then - AC_MSG_WARN(MDI not yet supported for wxUNIVERSAL... disabled) + AC_MSG_WARN(MDI not yet supported for wxUniversal... disabled) wxUSE_MDI_ARCHITECTURE=no fi @@ -4037,8 +4056,12 @@ if test "$wxUSE_PROLOGIO" = "yes" ; then fi if test "$wxUSE_RESOURCES" = "yes" ; then - AC_DEFINE(wxUSE_RESOURCES) - SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS resource" + if test "$wxUSE_NANOX" = "yes"; then + AC_MSG_WARN([Cannot use resource database functions in NanoX]) + else + AC_DEFINE(wxUSE_RESOURCES) + SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS resource" + fi fi if test "$wxUSE_X_RESOURCES" = "yes"; then @@ -4329,7 +4352,7 @@ if test "$wxUSE_TOGGLEBTN" = "yes"; then wxUSE_TOGGLEBTN=no fi if test "$wxUSE_UNIVERSAL" = "yes"; then - AC_MSG_WARN([Toggle button not yet supported under wxUNIVERSAL... disabled]) + AC_MSG_WARN([Toggle button not yet supported under wxUniversal... disabled]) wxUSE_TOGGLEBTN=no fi @@ -4370,13 +4393,9 @@ if test "$wxUSE_TOOLTIPS" = "yes"; then AC_MSG_WARN([wxTooltip not supported under WINE... disabled]) else if test "$wxUSE_UNIVERSAL" = "yes"; then - AC_MSG_WARN([wxTooltip not supported yet in wxUNIVERSAL... disabled]) + AC_MSG_WARN([wxTooltip not supported yet in wxUniversal... disabled]) else - if test "$wxUSE_X11" = "1"; then - AC_MSG_WARN([wxTooltip not supported yet under X11... disabled]) - else - AC_DEFINE(wxUSE_TOOLTIPS) - fi + AC_DEFINE(wxUSE_TOOLTIPS) fi fi fi