From: Francesco M. <fr...@us...> - 2008-01-14 12:13:46
|
Update of /cvsroot/wxlua/wxLua/build/autoconf In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv23999/build/autoconf Modified Files: aclocal.m4 configure.ac Log Message: cleaned up the wxWidgets libraries detection using a WX_CHECK_FOR_WXLIB instead of lots of copy-and-paste; fixed the order to which libraries where given to wx-config --libs which was causing linker problems Index: aclocal.m4 =================================================================== RCS file: /cvsroot/wxlua/wxLua/build/autoconf/aclocal.m4,v retrieving revision 1.52 retrieving revision 1.53 diff -C2 -d -r1.52 -r1.53 *** aclocal.m4 13 Jan 2008 19:51:04 -0000 1.52 --- aclocal.m4 14 Jan 2008 12:13:33 -0000 1.53 *************** *** 1,6 **** ! # generated automatically by aclocal 1.10 -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, ! # 2005, 2006 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, --- 1,6 ---- ! # generated automatically by aclocal 1.9.6 -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, ! # 2005 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, Index: configure.ac =================================================================== RCS file: /cvsroot/wxlua/wxLua/build/autoconf/configure.ac,v retrieving revision 1.54 retrieving revision 1.55 diff -C2 -d -r1.54 -r1.55 *** configure.ac 14 Jan 2008 05:09:45 -0000 1.54 --- configure.ac 14 Jan 2008 12:13:33 -0000 1.55 *************** *** 25,29 **** ## CONFIGURE OPTIONS ! ##################################################################### # standard wxWidgets options: --- 25,31 ---- ## CONFIGURE OPTIONS ! ################################################################################################# ! ################################################################################################# ! # standard wxWidgets options: *************** *** 56,61 **** [ AC_ARG_ENABLE([$1], ! [AC_HELP_STRING([--enable-wxbind$1], [Compiles the wxLua bindings for $2 lib (default is yes)])], ! [], [enable_wxbind$1=yes; wxbind_list_enabled="$wxbind_list_enabled,$1"]) ]) --- 58,64 ---- [ AC_ARG_ENABLE([$1], ! [AC_HELP_STRING([--enable-wxbind$1], ! [Compiles the wxLua bindings for $2 lib (default is auto)])], ! [], [enable_wxbind$1=auto]) ]) *************** *** 74,78 **** # remove initial comma: ! wxbind_list_enabled=${wxbind_list_enabled:1} AC_ARG_ENABLE([wxluadebug], --- 77,81 ---- # remove initial comma: ! #wxbind_list_enabled=${wxbind_list_enabled:1} AC_ARG_ENABLE([wxluadebug], *************** *** 102,117 **** UTILS_YESNO_OPTCHECK([USE_WXLUAFREEZEAPP], [enable_wxluafreeze_app], [--enable-wxluafreeze-app]) ! UTILS_YESNO_OPTCHECK([USE_WXBINDADV], [enable_wxbindadv], [--enable-wxbindadv]) ! UTILS_YESNO_OPTCHECK([USE_WXBINDAUI], [enable_wxbindaui], [--enable-wxbindaui]) ! UTILS_YESNO_OPTCHECK([USE_WXBINDBASE], [enable_wxbindbase], [--enable-wxbindbase]) ! UTILS_YESNO_OPTCHECK([USE_WXBINDCORE], [enable_wxbindcore], [--enable-wxbindcore]) ! UTILS_YESNO_OPTCHECK([USE_WXBINDGL], [enable_wxbindgl], [--enable-wxbindgl]) ! UTILS_YESNO_OPTCHECK([USE_WXBINDHTML], [enable_wxbindhtml], [--enable-wxbindhtml]) ! UTILS_YESNO_OPTCHECK([USE_WXBINDMEDIA], [enable_wxbindmedia], [--enable-wxbindmedia]) ! UTILS_YESNO_OPTCHECK([USE_WXBINDNET], [enable_wxbindnet], [--enable-wxbindnet]) ! UTILS_YESNO_OPTCHECK([USE_WXBINDRICHTEXT], [enable_wxbindrichtext], [--enable-wxbindrichtext]) ! UTILS_YESNO_OPTCHECK([USE_WXBINDSTC], [enable_wxbindstc], [--enable-wxbindstc]) ! UTILS_YESNO_OPTCHECK([USE_WXBINDXML], [enable_wxbindxml], [--enable-wxbindxml]) ! UTILS_YESNO_OPTCHECK([USE_WXBINDXRC], [enable_wxbindxrc], [--enable-wxbindxrc]) UTILS_YESNO_OPTCHECK([USE_WXLUADEBUG], [enable_wxluadebug], [--enable-wxluadebug]) --- 105,120 ---- UTILS_YESNO_OPTCHECK([USE_WXLUAFREEZEAPP], [enable_wxluafreeze_app], [--enable-wxluafreeze-app]) ! UTILS_YESNOAUTO_OPTCHECK([USE_WXBINDADV], [enable_wxbindadv], [--enable-wxbindadv]) ! UTILS_YESNOAUTO_OPTCHECK([USE_WXBINDAUI], [enable_wxbindaui], [--enable-wxbindaui]) ! UTILS_YESNOAUTO_OPTCHECK([USE_WXBINDBASE], [enable_wxbindbase], [--enable-wxbindbase]) ! UTILS_YESNOAUTO_OPTCHECK([USE_WXBINDCORE], [enable_wxbindcore], [--enable-wxbindcore]) ! UTILS_YESNOAUTO_OPTCHECK([USE_WXBINDGL], [enable_wxbindgl], [--enable-wxbindgl]) ! UTILS_YESNOAUTO_OPTCHECK([USE_WXBINDHTML], [enable_wxbindhtml], [--enable-wxbindhtml]) ! UTILS_YESNOAUTO_OPTCHECK([USE_WXBINDMEDIA], [enable_wxbindmedia], [--enable-wxbindmedia]) ! UTILS_YESNOAUTO_OPTCHECK([USE_WXBINDNET], [enable_wxbindnet], [--enable-wxbindnet]) ! UTILS_YESNOAUTO_OPTCHECK([USE_WXBINDRICHTEXT], [enable_wxbindrichtext], [--enable-wxbindrichtext]) ! UTILS_YESNOAUTO_OPTCHECK([USE_WXBINDSTC], [enable_wxbindstc], [--enable-wxbindstc]) ! UTILS_YESNOAUTO_OPTCHECK([USE_WXBINDXML], [enable_wxbindxml], [--enable-wxbindxml]) ! UTILS_YESNOAUTO_OPTCHECK([USE_WXBINDXRC], [enable_wxbindxrc], [--enable-wxbindxrc]) UTILS_YESNO_OPTCHECK([USE_WXLUADEBUG], [enable_wxluadebug], [--enable-wxluadebug]) *************** *** 161,182 **** - AC_DEFUN([AC_WXLUABINDLIB_ENABLE], - [ - AC_ARG_ENABLE([$1], - [AC_HELP_STRING([--enable-wxbind$1], [Compiles the wxLua bindings for $2 lib (default is yes)])], - [], [enable_wxbind$1=yes; wxbind_list_enabled="$wxbind_list_enabled,$1"]) - ]) - - ## Init libs, we will add to these as we check for their existance - ##################################################################### WXLIB_NAMES="core,base" - WXLUA_LIBS="-llua5.1" ! ! ## CONFIGURE CHECKS ! ##################################################################### # NB: to avoid getting "-g -02" automatically added to C*FLAGS we need --- 164,177 ---- + ## CONFIGURE CHECKS + ################################################################################################# + ################################################################################################# + # Initial wx libs, we will add more to these variables as we check for their existance WXLIB_NAMES="core,base" ! WXLUA_LIBS="-llua5.1" # NB: to avoid getting "-g -02" automatically added to C*FLAGS we need *************** *** 275,283 **** dnl --------------------------------------------------------------------------- ! dnl WX_CHECK_FOR_ADV( ! dnl [action if found], ! dnl [action if not found]) dnl --------------------------------------------------------------------------- ! AC_DEFUN([WX_CHECK_FOR_ADV], [ dnl save original flags into support variables --- 270,281 ---- dnl --------------------------------------------------------------------------- ! dnl WX_CHECK_FOR_WXLIB([wx-lib name lowercase], ! dnl [wx-lib name uppercase prefixed by WX], ! dnl [wx-lib include file with final .h], ! dnl [a C++ line of code which tests for existence of the wx-lib], ! dnl [action if found], ! dnl [action if not found]) dnl --------------------------------------------------------------------------- ! AC_DEFUN([WX_CHECK_FOR_WXLIB], [ dnl save original flags into support variables *************** *** 302,325 **** CFLAGS="$CFLAGS $WX_CFLAGS_ONLY" ! dnl before WX_LIBS we want the lib of Adv ! # Note: The dependencies were found in wxGTK using ldd ! #WX_LIKE_LIBNAME([_WX_ADV_LIBNAME], [wx], [adv]) ! #LIBS="$LIBS -l$_WX_ADV_LIBNAME $WX_LIBS" ! LIBS=`$WX_CONFIG_NAME $WXCONFIG_FLAGS --libs base,core,adv` dnl check for this component presence ! AC_MSG_CHECKING([if wxWidgets Adv bindings are available]) AC_LINK_IFELSE([ ! AC_LANG_PROGRAM([#include <wx/grid.h>], ! [wxGrid dummy(NULL, -1, wxDefaultPosition);]) ], ! [WXADV_PRESENCE=1], [WXADV_PRESENCE=0]) ! if test "$WXADV_PRESENCE" = "1"; then AC_MSG_RESULT([yes]) ! $1 else AC_MSG_RESULT([no]) ! $2 fi --- 300,321 ---- CFLAGS="$CFLAGS $WX_CFLAGS_ONLY" ! dnl the WXLIB_NAMES variable contains the names of the wxWidgets ! dnl library whose presence was already verified. ! LIBS=`$WX_CONFIG_NAME $WXCONFIG_FLAGS --libs $1,$WXLIB_NAMES` dnl check for this component presence ! AC_MSG_CHECKING([if wxWidgets $1 bindings are available]) AC_LINK_IFELSE([ ! AC_LANG_PROGRAM([#include <$3>], ! [$4]) ], ! [$2_PRESENCE=1], [$2_PRESENCE=0]) ! if test "$$2_PRESENCE" = "1"; then AC_MSG_RESULT([yes]) ! $5 else AC_MSG_RESULT([no]) ! $6 fi *************** *** 328,772 **** ]) - WX_CHECK_FOR_ADV - if [[[ "$USE_WXBINDADV" = "1" && "$WXADV_PRESENCE" = "1" ]]]; then - - dnl # add to the library to link to the wxADV lib - dnl WX_LIKE_LIBNAME([_WX_STC_LIBNAME], [wx], [adv]) *** Doesn't work for static builds - dnl WX_LIBS="-l$_WX_ADV_LIBNAME $WX_LIBS" *** nor this - - # add adv to the list of wx-config --libs xxx - WXLIB_NAMES="adv,$WXLIB_NAMES" - else - USE_WXBINDADV=0 - CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXADV=0" - fi ! dnl --------------------------------------------------------------------------- ! dnl WX_CHECK_FOR_AUI( ! dnl [action if found], ! dnl [action if not found]) ! dnl --------------------------------------------------------------------------- ! AC_DEFUN([WX_CHECK_FOR_AUI], ! [ ! dnl save original flags into support variables ! UTILS_SAVE_COREVAR() ! CPPFLAGS="$CPPFLAGS $WX_CPPFLAGS" ! CFLAGS="$CFLAGS $WX_CFLAGS_ONLY" ! LIBS=`$WX_CONFIG_NAME $WXCONFIG_FLAGS --libs base,core,adv,aui` ! dnl check for this component presence ! AC_MSG_CHECKING([if wxWidgets AUI bindings are available]) ! AC_LINK_IFELSE([ ! AC_LANG_PROGRAM([#include <wx/aui/aui.h>], ! [wxAuiPaneInfo dummy();]) ! ], ! [WXAUI_PRESENCE=1], [WXAUI_PRESENCE=0]) ! if test "$WXAUI_PRESENCE" = "1"; then ! AC_MSG_RESULT([yes]) ! $1 ! else ! AC_MSG_RESULT([no]) ! $2 ! fi ! dnl restore the original flags ! UTILS_RESTORE_COREVAR() ! ]) ! WX_CHECK_FOR_AUI ! if test "$WXAUI_PRESENCE" = "1"; then ! # add aui to the list of wx-config --libs ! WXLIB_NAMES="aui,$WXLIB_NAMES" ! else ! USE_WXBINDAUI=0 CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXAUI=0" fi ! dnl --------------------------------------------------------------------------- ! dnl WX_CHECK_FOR_GL( ! dnl [action if found], ! dnl [action if not found]) ! dnl --------------------------------------------------------------------------- ! AC_DEFUN([WX_CHECK_FOR_GL], ! [ ! dnl save original flags into support variables ! UTILS_SAVE_COREVAR() ! ! CPPFLAGS="$CPPFLAGS $WX_CPPFLAGS" ! CFLAGS="$CFLAGS $WX_CFLAGS_ONLY" ! LIBS=`$WX_CONFIG_NAME $WXCONFIG_FLAGS --libs base,core,gl` ! ! dnl check for this component presence ! AC_MSG_CHECKING([if wxWidgets OpenGL bindings are available]) ! AC_LINK_IFELSE([ ! AC_LANG_PROGRAM([#include <wx/glcanvas.h>], ! [wxGLCanvas dummy(NULL, -1, wxDefaultPosition);]) ! ], ! [WXGL_PRESENCE=1], [WXGL_PRESENCE=0]) ! ! if test "$WXGL_PRESENCE" = "1"; then ! AC_MSG_RESULT([yes]) ! $1 ! else ! AC_MSG_RESULT([no]) ! $2 ! fi ! ! dnl restore the original flags ! UTILS_RESTORE_COREVAR() ! ]) ! WX_CHECK_FOR_GL ! if test "$WXGL_PRESENCE" = "1"; then ! # add gl to the list of wx-config --libs ! WXLIB_NAMES="gl,$WXLIB_NAMES" ! else ! USE_WXBINDGL=0 CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXGL=0" fi ! dnl --------------------------------------------------------------------------- ! dnl WX_CHECK_FOR_HTML( ! dnl [action if found], ! dnl [action if not found]) ! dnl --------------------------------------------------------------------------- ! AC_DEFUN([WX_CHECK_FOR_HTML], ! [ ! dnl save original flags into support variables ! UTILS_SAVE_COREVAR() ! ! CPPFLAGS="$CPPFLAGS $WX_CPPFLAGS" ! CFLAGS="$CFLAGS $WX_CFLAGS_ONLY" ! LIBS=`$WX_CONFIG_NAME $WXCONFIG_FLAGS --libs base,core,html` ! ! dnl check for this component presence ! AC_MSG_CHECKING([if wxWidgets HTML bindings are available]) ! AC_LINK_IFELSE([ ! AC_LANG_PROGRAM([#include <wx/html/htmlcell.h>], ! [wxHtmlSelection dummy;]) ! ], ! [WXHTML_PRESENCE=1], [WXHTML_PRESENCE=0]) ! ! if test "$WXHTML_PRESENCE" = "1"; then ! AC_MSG_RESULT([yes]) ! $1 ! else ! AC_MSG_RESULT([no]) ! $2 ! fi ! ! dnl restore the original flags ! UTILS_RESTORE_COREVAR() ! ]) ! WX_CHECK_FOR_HTML ! if test "$WXHTML_PRESENCE" = "1"; then ! # add html to the list of wx-config --libs ! WXLIB_NAMES="html,$WXLIB_NAMES" ! else ! USE_WXBINDHTML=0 CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXHTML=0" fi ! dnl --------------------------------------------------------------------------- ! dnl WX_CHECK_FOR_MEDIA( ! dnl [action if found], ! dnl [action if not found]) ! dnl --------------------------------------------------------------------------- ! AC_DEFUN([WX_CHECK_FOR_MEDIA], ! [ ! dnl save original flags into support variables ! UTILS_SAVE_COREVAR() ! ! CPPFLAGS="$CPPFLAGS $WX_CPPFLAGS" ! CFLAGS="$CFLAGS $WX_CFLAGS_ONLY" ! LIBS=`$WX_CONFIG_NAME $WXCONFIG_FLAGS --libs base,core,media` ! ! dnl check for this component presence ! AC_MSG_CHECKING([if wxWidgets Media bindings are available]) ! AC_LINK_IFELSE([ ! AC_LANG_PROGRAM([#include <wx/mediactrl.h>], ! [wxMediaCtrl dummy();]) ! ], ! [WXMEDIA_PRESENCE=1], [WXMEDIA_PRESENCE=0]) ! ! if test "$WXMEDIA_PRESENCE" = "1"; then ! AC_MSG_RESULT([yes]) ! $1 ! else ! AC_MSG_RESULT([no]) ! $2 ! fi ! ! dnl restore the original flags ! UTILS_RESTORE_COREVAR() ! ]) ! WX_CHECK_FOR_MEDIA ! if test "$WXMEDIA_PRESENCE" = "1"; then ! # add media to the list of wx-config --libs ! WXLIB_NAMES="media,$WXLIB_NAMES" ! else ! USE_WXBINDMEDIA=0 CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXMEDIA=0" fi ! dnl --------------------------------------------------------------------------- ! dnl WX_CHECK_FOR_NET( ! dnl [action if found], ! dnl [action if not found]) ! dnl --------------------------------------------------------------------------- ! AC_DEFUN([WX_CHECK_FOR_NET], ! [ ! dnl save original flags into support variables ! UTILS_SAVE_COREVAR() ! ! CPPFLAGS="$CPPFLAGS $WX_CPPFLAGS" ! CFLAGS="$CFLAGS $WX_CFLAGS_ONLY" ! LIBS=`$WX_CONFIG_NAME $WXCONFIG_FLAGS --libs base,net` ! ! dnl check for this component presence ! AC_MSG_CHECKING([if wxWidgets Net bindings are available]) ! AC_LINK_IFELSE([ ! AC_LANG_PROGRAM([#include <wx/socket.h>], ! [wxSocketClient dummy;]) ! ], ! [WXNET_PRESENCE=1], [WXNET_PRESENCE=0]) ! ! if test "$WXNET_PRESENCE" = "1"; then ! AC_MSG_RESULT([yes]) ! $1 ! else ! AC_MSG_RESULT([no]) ! $2 ! fi ! ! dnl restore the original flags ! UTILS_RESTORE_COREVAR() ! ]) ! WX_CHECK_FOR_NET ! if test "$WXNET_PRESENCE" = "1"; then ! # add net to the list of wx-config --libs ! WXLIB_NAMES="net,$WXLIB_NAMES" ! else ! USE_WXBINDNET=0 CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXNET=0" fi ! dnl --------------------------------------------------------------------------- ! dnl WX_CHECK_FOR_RICHTEXT( ! dnl [action if found], ! dnl [action if not found]) ! dnl --------------------------------------------------------------------------- ! AC_DEFUN([WX_CHECK_FOR_RICHTEXT], ! [ ! dnl save original flags into support variables ! UTILS_SAVE_COREVAR() ! ! CPPFLAGS="$CPPFLAGS $WX_CPPFLAGS" ! CFLAGS="$CFLAGS $WX_CFLAGS_ONLY" ! LIBS=`$WX_CONFIG_NAME $WXCONFIG_FLAGS --libs base,core,xml,html,adv,richtext` ! ! dnl check for this component presence ! AC_MSG_CHECKING([if wxWidgets Richtext bindings are available]) ! AC_LINK_IFELSE([ ! AC_LANG_PROGRAM([#include <wx/richtext/richtextctrl.h>], ! [wxRichTextCtrl dummy;]) ! ], ! [WXRICHTEXT_PRESENCE=1], [WXRICHTEXT_PRESENCE=0]) ! ! if test "$WXRICHTEXT_PRESENCE" = "1"; then ! AC_MSG_RESULT([yes]) ! $1 ! else ! AC_MSG_RESULT([no]) ! $2 ! fi ! ! dnl restore the original flags ! UTILS_RESTORE_COREVAR() ! ]) ! WX_CHECK_FOR_RICHTEXT ! if test "$WXRICHTEXT_PRESENCE" = "1"; then ! # add richtext to the list of wx-config --libs ! WXLIB_NAMES="richtext,$WXLIB_NAMES" ! else ! USE_WXBINDRICHTEXT=0 ! CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXRICHTEXT=0" fi ! ! ! dnl --------------------------------------------------------------------------- ! dnl WX_CHECK_FOR_XML( ! dnl [action if found], ! dnl [action if not found]) ! dnl --------------------------------------------------------------------------- ! AC_DEFUN([WX_CHECK_FOR_XML], ! [ ! dnl save original flags into support variables ! UTILS_SAVE_COREVAR() ! ! CPPFLAGS="$CPPFLAGS $WX_CPPFLAGS" ! CFLAGS="$CFLAGS $WX_CFLAGS_ONLY" ! LIBS=`$WX_CONFIG_NAME $WXCONFIG_FLAGS --libs base,xml` ! ! dnl check for this component presence ! AC_MSG_CHECKING([if wxWidgets XML bindings are available]) ! AC_LINK_IFELSE([ ! AC_LANG_PROGRAM([#include <wx/xml/xml.h>], ! [wxXmlProperty dummy;]) ! ], ! [WXXML_PRESENCE=1], [WXXML_PRESENCE=0]) ! ! if test "$WXXML_PRESENCE" = "1"; then ! AC_MSG_RESULT([yes]) ! $1 ! else ! AC_MSG_RESULT([no]) ! $2 ! fi ! ! dnl restore the original flags ! UTILS_RESTORE_COREVAR() ! ]) ! ! WX_CHECK_FOR_XML ! if test "$WXXML_PRESENCE" = "1"; then ! # add xrc to the list of wx-config --libs ! WXLIB_NAMES="xml,$WXLIB_NAMES" ! else ! USE_WXBINDXML=0 ! CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXXML=0" fi ! dnl --------------------------------------------------------------------------- ! dnl WX_CHECK_FOR_XRC( ! dnl [action if found], ! dnl [action if not found]) ! dnl --------------------------------------------------------------------------- ! AC_DEFUN([WX_CHECK_FOR_XRC], ! [ ! dnl save original flags into support variables ! UTILS_SAVE_COREVAR() ! ! CPPFLAGS="$CPPFLAGS $WX_CPPFLAGS" ! CFLAGS="$CFLAGS $WX_CFLAGS_ONLY" ! LIBS=`$WX_CONFIG_NAME $WXCONFIG_FLAGS --libs base,xml,core,adv,html,xrc` ! ! dnl check for this component presence ! AC_MSG_CHECKING([if wxWidgets XRC bindings are available]) ! AC_LINK_IFELSE([ ! AC_LANG_PROGRAM([#include <wx/xrc/xh_all.h>], ! [wxSizerXmlHandler dummy;]) ! ], ! [WXXRC_PRESENCE=1], [WXXRC_PRESENCE=0]) ! ! if test "$WXXRC_PRESENCE" = "1"; then ! AC_MSG_RESULT([yes]) ! $1 ! else ! AC_MSG_RESULT([no]) ! $2 ! fi ! ! dnl restore the original flags ! UTILS_RESTORE_COREVAR() ! ]) ! WX_CHECK_FOR_XRC ! if test "$WXXRC_PRESENCE" = "1"; then ! # add xrc to the list of wx-config --libs ! WXLIB_NAMES="xrc,$WXLIB_NAMES" ! else ! USE_WXBINDXRC=0 CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXXRC=0" fi ! dnl --------------------------------------------------------------------------- ! dnl WX_STC_CHECK( ! dnl [action if found], ! dnl [action if not found]) ! dnl --------------------------------------------------------------------------- ! AC_DEFUN([WX_STC_CHECK], ! [ ! dnl save original flags into support variables ! UTILS_SAVE_COREVAR() ! ! CPPFLAGS="$CPPFLAGS $WX_CPPFLAGS" ! CFLAGS="$CFLAGS $WX_CFLAGS_ONLY" ! LIBS=`$WX_CONFIG_NAME $WXCONFIG_FLAGS --libs base,core,stc` ! ! dnl check for this component presence ! AC_MSG_CHECKING([if wxWidgets STC contrib is available]) ! AC_LINK_IFELSE([ ! AC_LANG_PROGRAM([#include <wx/stc/stc.h>], ! [wxStyledTextCtrl dummy;]) ! ], ! [WXSTC_PRESENCE=1], [WXSTC_PRESENCE=0]) ! ! if test "$WXSTC_PRESENCE" = "1"; then ! AC_MSG_RESULT([yes]) ! $1 ! else ! AC_MSG_RESULT([no]) ! $2 ! fi ! ! dnl restore the original flags ! UTILS_RESTORE_COREVAR() ! ]) ! # check for STC wrapper for wxWidgets ! if [[ "$USE_WXBINDSTC" = "1" ]]; then ! AC_CACHE_VAL([ac_cv_prog_stc_set], ! [WX_STC_CHECK([ac_cv_prog_stc_set=1], [ac_cv_prog_stc_set=0])]) ! if test $ac_cv_prog_stc_set = "1"; then ! # add stc to the list of wx-config --libs ! WXLIB_NAMES="stc,$WXLIB_NAMES" ! else ! WXBUILD_STR="$($WX_CONFIG_WITH_ARGS --selected_config)" ! AC_MSG_NOTICE([ ! The wxWidgets wrappers for Scintilla text control could not be found ! (at least not for the '$WXBUILD_STR' wxWidgets build). ! Please be sure that you compiled and installed it since they are ! not built together with wxWidgets by default. ! E.g. from wxWidgets build directory type: ! cd contrib/src/stc && make && sudo make install ! cd contrib/samples/stc && make ! If you still get this error message, look at config.log for more details ! or report this problem to $PACKAGE_BUGREPORT. ! NOTE: build is proceeding without Scintilla wrappers, but you will miss ! the wxLuaApp and wxLuaEdit applications! ! ]) ! USE_WXBINDSTC=0 ! USE_WXLUAAPP=0 ! USE_WXLUAEDITAPP=0 ! CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXSTC=0" ! fi ! else # these depends from wxSTC ! USE_WXLUAAPP=0 USE_WXLUAEDITAPP=0 ! CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXSTC=0" fi dnl --------------------------------------------------------------------------- dnl wxStEdit check --- 324,522 ---- ]) + # + # now check for wxWidgets libraries presence in the correct order + # + # NOTE: in wx >= 2.9 this won't be necessary since we'll be able to + # simply search in the `wx-config --libs all` string which + # contains all the available wx libraries for a certain wx build + # ! if [[[ "$USE_WXBINDADV" = "1" ]]]; then ! # the user set the relative --enable-wxbindXXX option to 'auto' or to 'yes' value: ! # check if the XXX library is available: ! WX_CHECK_FOR_WXLIB([adv], [WXADV], ! [wx/grid.h], [wxGrid dummy(NULL, -1, wxDefaultPosition);], ! [USE_WXBINDADV=1; WXLIB_NAMES="adv,$WXLIB_NAMES"], ! [USE_WXBINDADV=0]) ! fi ! if [[[ "$USE_WXBINDADV" = "0" ]]]; then ! # either the user set --enable-wxbindXXX=no or the test above failed ! # as the wx XXX library is not available... ! CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXADV=0" ! fi ! if [[[ "$USE_WXBINDAUI" = "1" ]]]; then ! # the user set the relative --enable-wxbindXXX option to 'auto' or to 'yes' value: ! # check if the XXX library is available: ! WX_CHECK_FOR_WXLIB([aui], [WXAUI], ! [wx/aui/aui.h], [wxAuiPaneInfo dummy();], ! [USE_WXBINDAUI=1; WXLIB_NAMES="aui,$WXLIB_NAMES"], ! [USE_WXBINDAUI=0]) ! fi ! if [[[ "$USE_WXBINDAUI" = "0" ]]]; then ! # either the user set --enable-wxbindXXX=no or the test above failed ! # as the wx XXX library is not available... CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXAUI=0" fi + if [[[ "$USE_WXBINDGL" = "1" ]]]; then ! # the user set the relative --enable-wxbindXXX option to 'auto' or to 'yes' value: ! # check if the XXX library is available: ! WX_CHECK_FOR_WXLIB([gl], [WXGL], ! [wx/glcanvas.h], [wxGLCanvas dummy(NULL, -1, wxDefaultPosition);], ! [USE_WXBINDGL=1; WXLIB_NAMES="gl,$WXLIB_NAMES"], ! [USE_WXBINDGL=0]) ! fi ! if [[[ "$USE_WXBINDGL" = "0" ]]]; then ! # either the user set --enable-wxbindXXX=no or the test above failed ! # as the wx XXX library is not available... CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXGL=0" fi + if [[[ "$USE_WXBINDHTML" = "1" ]]]; then ! # the user set the relative --enable-wxbindXXX option to 'auto' or to 'yes' value: ! # check if the XXX library is available: ! WX_CHECK_FOR_WXLIB([html], [WXHTML], ! [wx/html/htmlcell.h], [wxHtmlSelection dummy;], ! [USE_WXBINDHTML=1; WXLIB_NAMES="html,$WXLIB_NAMES"], ! [USE_WXBINDHTML=0]) ! fi ! if [[[ "$USE_WXBINDHTML" = "0" ]]]; then ! # either the user set --enable-wxbindXXX=no or the test above failed ! # as the wx XXX library is not available... CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXHTML=0" fi + if [[[ "$USE_WXBINDMEDIA" = "1" ]]]; then ! # the user set the relative --enable-wxbindXXX option to 'auto' or to 'yes' value: ! # check if the XXX library is available: ! WX_CHECK_FOR_WXLIB([media], [WXMEDIA], ! [wx/mediactrl.h], [wxMediaCtrl dummy();], ! [USE_WXBINDMEDIA=1; WXLIB_NAMES="media,$WXLIB_NAMES"], ! [USE_WXBINDMEDIA=0]) ! fi ! if [[[ "$USE_WXBINDMEDIA" = "0" ]]]; then ! # either the user set --enable-wxbindXXX=no or the test above failed ! # as the wx XXX library is not available... CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXMEDIA=0" fi + if [[[ "$USE_WXBINDNET" = "1" ]]]; then ! # the user set the relative --enable-wxbindXXX option to 'auto' or to 'yes' value: ! # check if the XXX library is available: ! WX_CHECK_FOR_WXLIB([net], [WXNET], ! [wx/socket.h], [wxSocketClient dummy;], ! [USE_WXBINDNET=1; WXLIB_NAMES="net,$WXLIB_NAMES"], ! [USE_WXBINDNET=0]) ! fi ! if [[[ "$USE_WXBINDNET" = "0" ]]]; then ! # either the user set --enable-wxbindXXX=no or the test above failed ! # as the wx XXX library is not available... CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXNET=0" fi + if [[[ "$USE_WXBINDXML" = "1" ]]]; then ! # the user set the relative --enable-wxbindXXX option to 'auto' or to 'yes' value: ! # check if the XXX library is available: ! WX_CHECK_FOR_WXLIB([xml], [WXXML], ! [wx/xml/xml.h], [wxXmlProperty dummy;], ! [USE_WXBINDXML=1; WXLIB_NAMES="xml,$WXLIB_NAMES"], ! [USE_WXBINDXML=0]) fi ! if [[[ "$USE_WXBINDXML" = "0" ]]]; then ! # either the user set --enable-wxbindXXX=no or the test above failed ! # as the wx XXX library is not available... ! CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXXML=0" fi + if [[[ "$USE_WXBINDXRC" = "1" ]]]; then ! # the user set the relative --enable-wxbindXXX option to 'auto' or to 'yes' value: ! # check if the XXX library is available: ! WX_CHECK_FOR_WXLIB([xrc], [WXXRC], ! [wx/xrc/xh_all.h], [wxSizerXmlHandler dummy;], ! [USE_WXBINDXRC=1; WXLIB_NAMES="xrc,$WXLIB_NAMES"], ! [USE_WXBINDXRC=0]) ! fi ! if [[[ "$USE_WXBINDXRC" = "0" ]]]; then ! # either the user set --enable-wxbindXXX=no or the test above failed ! # as the wx XXX library is not available... CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXXRC=0" fi + if [[[ "$USE_WXBINDRICHTEXT" = "1" ]]]; then ! # the user set the relative --enable-wxbindXXX option to 'auto' or to 'yes' value: ! # check if the XXX library is available: + WX_CHECK_FOR_WXLIB([richtext], [WXRICHTEXT], + [wx/richtext/richtextctrl.h], [wxRichTextCtrl dummy;], + [USE_WXBINDRICHTEXT=1; WXLIB_NAMES="richtext,$WXLIB_NAMES"], + [USE_WXBINDRICHTEXT=0]) + fi + if [[[ "$USE_WXBINDRICHTEXT" = "0" ]]]; then + # either the user set --enable-wxbindXXX=no or the test above failed + # as the wx XXX library is not available... + CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXRICHTEXT=0" + fi ! # NOTE: even if the STC library is a contrib in wx <= 2.8, we can still use ! # the WX_CHECK_FOR_WXLIB macro to test for it ! if [[[ "$USE_WXBINDSTC" = "1" ]]]; then ! # the user set the relative --enable-wxbindXXX option to 'auto' or to 'yes' value: ! # check if the XXX library is available: ! WX_CHECK_FOR_WXLIB([stc], [WXSTC], ! [wx/stc/stc.h], [wxStyledTextCtrl dummy;], ! [USE_WXBINDSTC=1; WXLIB_NAMES="stc,$WXLIB_NAMES"], ! [USE_WXBINDSTC=0]) ! fi ! if [[[ "$USE_WXBINDSTC" = "0" ]]]; then ! # either the user set --enable-wxbindXXX=no or the test above failed ! # as the wx XXX library is not available... ! CPPFLAGS="$CPPFLAGS -DwxLUA_USEBINDING_WXSTC=0" # these depends from wxSTC ! USE_WXLUAAPP=0 USE_WXLUAEDITAPP=0 ! ! WXBUILD_STR="$($WX_CONFIG_WITH_ARGS --selected_config)" ! AC_MSG_NOTICE([ ! The wxWidgets wrappers for Scintilla text control could not be found ! (at least not for the '$WXBUILD_STR' wxWidgets build). ! Please be sure that you compiled and installed it since they are ! not built together with wxWidgets <= 2.8 by default. ! E.g. from wxWidgets build directory type: ! ! cd contrib/src/stc && make && sudo make install ! cd contrib/samples/stc && make ! ! If you still get this error message, look at config.log for more details ! or report this problem to $PACKAGE_BUGREPORT. ! NOTE: build is proceeding without Scintilla wrappers, but you will miss ! the wxLuaApp and wxLuaEdit applications! ! ]) fi + dnl --------------------------------------------------------------------------- dnl wxStEdit check *************** *** 818,822 **** fi ! dnl --------------------------------------------------------------------------- # recreate the wx-config --libs after determining what libs we've found --- 568,573 ---- fi ! # -------------------------------------------------------------------------- ! # -------------------------------------------------------------------------- # recreate the wx-config --libs after determining what libs we've found *************** *** 828,832 **** [ if test $1 == "1"; then - #"-lwxlua_\$(WX_PORT)\$(WXLIBPOSTFIX)_$2-\$(WX_VERSION_MAJOR).\$(WX_VERSION_MINOR) $WXLUA_LIBS" WX_LIKE_LIBNAME([_TMP], [wxlua], [$2]) if test "$SHARED" = "1" ; then --- 579,582 ---- *************** *** 859,864 **** ! dnl -------------------------------------------------------------------------- ! dnl -------------------------------------------------------------------------- # Produce some useful info for pkg-config: --- 609,614 ---- ! # -------------------------------------------------------------------------- ! # -------------------------------------------------------------------------- # Produce some useful info for pkg-config: *************** *** 910,914 **** ## END OF CONFIGURE SCRIPT ! ##################################################################### AC_BAKEFILE([m4_include(autoconf_inc.m4)]) --- 660,665 ---- ## END OF CONFIGURE SCRIPT ! ################################################################################################# ! ################################################################################################# AC_BAKEFILE([m4_include(autoconf_inc.m4)]) *************** *** 1015,1018 **** --- 766,775 ---- [" - enable_wxbindxrc module: no"]) + echo + echo " - compact list of the wxWidgets library for which" + echo " binding modules will be created: " + echo " $WXLIB_NAMES" + echo + UTILS_BOOLOPT_SUMMARY([USE_WXLUADEBUG], [" - enable_wxluadebug module: yes"], *************** *** 1031,1054 **** [" - install custom wxBind stuff: no"]) - echo " " - echo " - wxBind modules desired by configure options: " - echo " $wxbind_list_enabled" - - echo " - wxBind modules that will be created satisfying dependencies: " - echo " $WXLIB_NAMES" - echo " " - # It is sometimes hard to dig out these values from the Makefiles ! echo " - wxLua complier and linker directives summary: " ! echo " CFLAGS : '$CFLAGS'" ! echo " CXXFLAGS : '$CXXFLAGS'" ! echo " CPPFLAGS : '$CPPFLAGS'" ! echo " WX_CXXFLAGS : '$WX_CXXFLAGS'" ! echo " LDFLAGS : '$LDFLAGS'" ! echo " WX_LIBS : '$WX_LIBS'" ! echo " WXLUA_LIBS : '$WXLUA_LIBS'" ! echo " " echo " - wxLua make install path settings:" echo " prefix : '$prefix'" --- 788,804 ---- [" - install custom wxBind stuff: no"]) # It is sometimes hard to dig out these values from the Makefiles ! #echo " - wxLua compiler and linker directives summary: " ! #echo " CFLAGS : '$CFLAGS'" ! #echo " CXXFLAGS : '$CXXFLAGS'" ! #echo " CPPFLAGS : '$CPPFLAGS'" ! #echo " WX_CXXFLAGS : '$WX_CXXFLAGS'" ! #echo " LDFLAGS : '$LDFLAGS'" ! #echo " WX_LIBS : '$WX_LIBS'" ! #echo " WXLUA_LIBS : '$WXLUA_LIBS'" ! #echo " " + echo echo " - wxLua make install path settings:" echo " prefix : '$prefix'" *************** *** 1056,1071 **** echo " libdir : '$libdir'" echo " datadir : '$datadir'" - echo " " ! echo " - wxWidgets wx-config information summary: " ! echo " wx-config : '$WX_CONFIG_NAME'" ! echo " wx-config flags : '$WXCONFIG_FLAGS'" ! echo " wx-config with args : '$WX_CONFIG_WITH_ARGS'" ! echo " wx-config --release : '`$WX_CONFIG_NAME $WXCONFIG_FLAGS --release`'" ! echo " wx-config --version-full : '`$WX_CONFIG_NAME $WXCONFIG_FLAGS --version-full`'" ! echo " wx-config --selected-config : '`$WX_CONFIG_NAME $WXCONFIG_FLAGS --selected-config`'" ! echo " wx-config --prefix : '`$WX_CONFIG_NAME $WXCONFIG_FLAGS --prefix`'" ! echo " wx-config --exec-prefix : '`$WX_CONFIG_NAME $WXCONFIG_FLAGS --exec-prefix`'" ! echo " " WX_STANDARD_OPTIONS_SUMMARY_MSG_END --- 806,820 ---- echo " libdir : '$libdir'" echo " datadir : '$datadir'" ! #echo " - wxWidgets wx-config information summary: " ! #echo " wx-config : '$WX_CONFIG_NAME'" ! #echo " wx-config flags : '$WXCONFIG_FLAGS'" ! #echo " wx-config with args : '$WX_CONFIG_WITH_ARGS'" ! #echo " wx-config --release : '`$WX_CONFIG_NAME $WXCONFIG_FLAGS --release`'" ! #echo " wx-config --version-full : '`$WX_CONFIG_NAME $WXCONFIG_FLAGS --version-full`'" ! #echo " wx-config --selected-config : '`$WX_CONFIG_NAME $WXCONFIG_FLAGS --selected-config`'" ! #echo " wx-config --prefix : '`$WX_CONFIG_NAME $WXCONFIG_FLAGS --prefix`'" ! #echo " wx-config --exec-prefix : '`$WX_CONFIG_NAME $WXCONFIG_FLAGS --exec-prefix`'" ! #echo WX_STANDARD_OPTIONS_SUMMARY_MSG_END |