X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/527479c46ee026fae35cf6ebca0c7f8520ef746d..32a925f832ce34ee19c013e7aa025178e0a6eb27:/configure.in diff --git a/configure.in b/configure.in index 830e31f162..2cd138264d 100644 --- a/configure.in +++ b/configure.in @@ -845,11 +845,12 @@ WX_ARG_FEATURE(mdi, [ --enable-mdi use multiple document int WX_ARG_FEATURE(mdidoc, [ --enable-mdidoc use docview architecture with MDI], wxUSE_MDI_ARCHITECTURE) WX_ARG_FEATURE(mediactrl, [ --enable-mediactrl use wxMediaCtrl class], wxUSE_MEDIACTRL) WX_ARG_FEATURE(gstreamer8, [ --enable-gstreamer8 force GStreamer 0.8 instead of 0.10 with the wxMediaCtrl class on unix], wxUSE_GSTREAMER8) -WX_ARG_FEATURE(webkit, [ --enable-webkit use wxWebKitCtrl (Mac)], wxUSE_WEBKIT) WX_ARG_FEATURE(richtext, [ --enable-richtext use wxRichTextCtrl], wxUSE_RICHTEXT) WX_ARG_FEATURE(postscript, [ --enable-postscript use wxPostscriptDC device context (default for gtk+)], wxUSE_POSTSCRIPT) WX_ARG_FEATURE(printarch, [ --enable-printarch use printing architecture], wxUSE_PRINTING_ARCHITECTURE) WX_ARG_FEATURE(svg, [ --enable-svg use wxSVGFileDC device context], wxUSE_SVG) +WX_ARG_FEATURE(webkit, [ --enable-webkit use wxWebKitCtrl (Mac-only, use wxWebView instead)], wxUSE_WEBKIT) +WX_ARG_FEATURE(webview, [ --enable-webview use wxWebView library], wxUSE_WEBVIEW) dnl wxDC is implemented in terms of wxGraphicsContext in wxOSX so the latter dnl can't be disabled, don't even provide an option to do it @@ -1047,6 +1048,7 @@ WX_ARG_FEATURE(dragimage, [ --enable-dragimage use wxDragImage], wxUSE_D WX_ARG_FEATURE(accessibility,[ --enable-accessibility enable accessibility support], wxUSE_ACCESSIBILITY) WX_ARG_FEATURE(uiactionsim, [ --enable-uiactionsim use wxUIActionSimulator (experimental)], wxUSE_UIACTIONSIMULATOR) WX_ARG_FEATURE(dctransform, [ --enable-dctransform use wxDC::SetTransformMatrix and related], wxUSE_DC_TRANSFORM_MATRIX) +WX_ARG_FEATURE(webviewwebkit,[ --enable-webview-webkit use wxWebView WebKit backend], wxUSE_WEBVIEW_WEBKIT) dnl --------------------------------------------------------------------------- dnl support for image formats that do not rely on external library @@ -1071,6 +1073,7 @@ WX_ARG_FEATURE(ps-in-msw, [ --enable-ps-in-msw use PS printing in wxMSW WX_ARG_FEATURE(ownerdrawn, [ --enable-ownerdrawn use owner drawn controls (Win32 and OS/2 only)], wxUSE_OWNER_DRAWN) WX_ARG_FEATURE(uxtheme, [ --enable-uxtheme enable support for Windows XP themed look (Win32 only)], wxUSE_UXTHEME) WX_ARG_FEATURE(wxdib, [ --enable-wxdib use wxDIB class (Win32 only)], wxUSE_DIB) +WX_ARG_FEATURE(webviewie, [ --enable-webview-ie use wxWebView IE backend (Win32 only)], wxUSE_WEBVIEW_IE) dnl this one is not really MSW-specific but it exists mainly to be turned off dnl under MSW, it should be off by default on the other platforms @@ -2963,9 +2966,6 @@ if test "$wxUSE_GUI" = "yes"; then esac AM_PATH_GTK_2_0(2.4.0, wx_cv_lib_gtk=2.0, , $GTK_MODULES) - - dnl we use symbols from X11 directly so we should link with it - GTK_LIBS="$GTK_LIBS -lX11" fi dnl detect GTK1.x @@ -2983,6 +2983,9 @@ if test "$wxUSE_GUI" = "yes"; then dnl looks better in AC_MSG_RESULT wx_cv_lib_gtk=none else + dnl we use symbols from X11 directly so we should link with it + GTK_LIBS="$GTK_LIBS -lX11" + dnl we need to cache GTK_CFLAGS and GTK_LIBS for the dnl subsequent runs wx_cv_cflags_gtk=$GTK_CFLAGS @@ -3108,7 +3111,6 @@ libraries returned by 'pkg-config gtk+-2.0 --libs' or 'gtk-config TOOLKIT_INCLUDE="$wx_cv_cflags_gtk" GUI_TK_LIBRARY="$wx_cv_libs_gtk $GUI_TK_LIBRARY" - AFMINSTALL=afminstall TOOLKIT=GTK GUIDIST=GTK_DIST @@ -7364,6 +7366,95 @@ if test "$wxUSE_RICHTEXT" = "yes"; then SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS richtext" fi +if test "$wxUSE_WEBVIEW" = "yes"; then + USE_WEBVIEW_WEBKIT=0 + if test "$wxUSE_WEBVIEW_WEBKIT" = "yes"; then + if test "$wxUSE_GTK" = 1; then + AC_MSG_CHECKING([for webkitgtk libraries]) + WX_PATH_FIND_LIBRARIES([$SEARCH_LIB],webkitgtk-1.0) + if test "$ac_find_libraries" != "" ; then + WX_LINK_PATH_EXIST([$ac_find_libraries],[$LDFLAGS]) + if test "$ac_path_to_link" != " -L/usr/lib" ; then + LDFLAGS="$LDFLAGS $ac_path_to_link" + fi + GUI_TK_LIBRARY="$GUI_TK_LIBRARY -lwebkitgtk-1.0" + AC_MSG_RESULT([yes]) + + AC_MSG_CHECKING(for webkitgtk headers) + WX_PATH_FIND_INCLUDES([$SEARCH_INCLUDE /usr/include/webkit-1.0], webkit/webkit.h) + if test "$ac_find_includes" != "" ; then + AC_MSG_RESULT(found in $ac_find_includes) + WX_INCLUDE_PATH_EXIST($ac_find_includes, $CPPFLAGS) + CPPFLAGS="$ac_path_to_include $CPPFLAGS" + + dnl we also depend on libsoup + AC_MSG_CHECKING(for libsoup headers) + WX_PATH_FIND_INCLUDES([$SEARCH_INCLUDE /usr/include/libsoup-2.4], libsoup/soup.h) + if test "$ac_find_includes" != "" ; then + AC_MSG_RESULT(found in $ac_find_includes) + WX_INCLUDE_PATH_EXIST($ac_find_includes, $CPPFLAGS) + CPPFLAGS="$ac_path_to_include $CPPFLAGS" + + USE_WEBVIEW_WEBKIT=1 + else + AC_MSG_RESULT([not found]) + AC_MSG_WARN([libsoup headers not found; disabling WebKit backend]) + fi + else + AC_MSG_RESULT([not found]) + AC_MSG_WARN([WebKit headers not found; disabling WebKit backend]) + fi + else + AC_MSG_RESULT([no]) + AC_MSG_WARN([WebKit libraries not found; disabling WebKit backend]) + fi + elif test "$wxUSE_MAC" = 1 -a "$USE_DARWIN" = 1; then + dnl Under Mac we always have the libraries but check for the + dnl headers + old_CPPFLAGS="$CPPFLAGS" + CPPFLAGS="-x objective-c++ $CPPFLAGS" + AC_CHECK_HEADER([WebKit/HIWebView.h], + [ + USE_WEBVIEW_WEBKIT=1 + WEBKIT_LINK="-framework WebKit" + ], + [ + AC_MSG_WARN([WebKit headers not found]) + ], + [ + #include + #include + ]) + CPPFLAGS="$old_CPPFLAGS" + fi + fi + + wxUSE_WEBVIEW="no" + if test "$wxUSE_GTK" = 1 -o "$wxUSE_MAC" = 1; then + if test "$USE_WEBVIEW_WEBKIT" = 1; then + wxUSE_WEBVIEW="yes" + AC_DEFINE(wxUSE_WEBVIEW_WEBKIT) + else + AC_MSG_WARN([WebKit not available, disabling wxWebView]) + fi + elif test "$wxUSE_MSW" = 1; then + if test "wxUSE_WEBVIEW_IE" = "yes"; then + dnl TODO: Check for the required headers/libraries under Windows + dnl too and do the right thing automatically there too. + wxUSE_WEBVIEW="yes" + AC_DEFINE(wxUSE_WEBVIEW_IE) + fi + fi +fi + +if test "$wxUSE_WEBVIEW" = "yes"; then + USE_WEBVIEW=1 + AC_DEFINE(wxUSE_WEBVIEW) + SAMPLES_SUBDIRS="$SAMPLES_SUBDIRS webview" +else + USE_WEBVIEW=0 +fi + dnl --------------------------------------------------------------------------- dnl wxImage options dnl --------------------------------------------------------------------------- @@ -7746,6 +7837,10 @@ if test "$wxUSE_GUI" = "yes"; then if test "$wxUSE_STC" = "yes" ; then BUILT_WX_LIBS="stc $BUILT_WX_LIBS" fi + if test "$wxUSE_WEBVIEW" = "yes" ; then + STD_GUI_LIBS="webview $STD_GUI_LIBS" + BUILT_WX_LIBS="webview $BUILT_WX_LIBS" + fi if test "$wxUSE_XRC" = "yes" ; then STD_GUI_LIBS="xrc $STD_GUI_LIBS" BUILT_WX_LIBS="xrc $BUILT_WX_LIBS"