diff --git a/build/aclocal/bakefile.m4 b/build/aclocal/bakefile.m4 index efa98ae0d0..c45c736cc1 100644 --- a/build/aclocal/bakefile.m4 +++ b/build/aclocal/bakefile.m4 @@ -377,7 +377,7 @@ AC_DEFUN([AC_BAKEFILE_SHARED_LD], fi ;; - *-*-cygwin* | *-*-mingw32* ) + *-*-cygwin* | *-*-mingw32* | *-*-mingw64* ) PIC_FLAG="" SHARED_LD_CC="\$(CC) -shared -o" SHARED_LD_CXX="\$(CXX) -shared -o" @@ -578,7 +578,7 @@ AC_DEFUN([AC_BAKEFILE_CHECK_BASIC_STUFF], LDFLAGS_GUI= case ${BAKEFILE_HOST} in - *-*-cygwin* | *-*-mingw32* ) + *-*-cygwin* | *-*-mingw32* | *-*-mingw64* ) LDFLAGS_GUI="-mwindows" esac AC_SUBST(LDFLAGS_GUI) @@ -594,7 +594,7 @@ dnl --------------------------------------------------------------------------- AC_DEFUN([AC_BAKEFILE_RES_COMPILERS], [ case ${BAKEFILE_HOST} in - *-*-cygwin* | *-*-mingw32* ) + *-*-cygwin* | *-*-mingw32* | *-*-mingw64* ) dnl Check for win32 resources compiler: AC_CHECK_TOOL(WINDRES, windres) ;; diff --git a/configure b/configure index 42edeae0c8..1b11ac5dc3 100755 --- a/configure +++ b/configure @@ -1040,6 +1040,7 @@ infodir docdir oldincludedir includedir +runstatedir localstatedir sharedstatedir sysconfdir @@ -1460,6 +1461,7 @@ datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' +runstatedir='${localstatedir}/run' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' @@ -1712,6 +1714,15 @@ do | -silent | --silent | --silen | --sile | --sil) silent=yes ;; + -runstatedir | --runstatedir | --runstatedi | --runstated \ + | --runstate | --runstat | --runsta | --runst | --runs \ + | --run | --ru | --r) + ac_prev=runstatedir ;; + -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \ + | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \ + | --run=* | --ru=* | --r=*) + runstatedir=$ac_optarg ;; + -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ @@ -1849,7 +1860,7 @@ fi for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir + libdir localedir mandir runstatedir do eval ac_val=\$$ac_var # Remove trailing slashes. @@ -2002,6 +2013,7 @@ Fine tuning of the installation directories: --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] + --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] @@ -3991,7 +4003,7 @@ case "${host}" in ;; - *-*-cygwin* | *-*-mingw32* ) + *-*-cygwin* | *-*-mingw32* | *-*-mingw64* ) PROGRAM_EXT=".exe" DEFAULT_DEFAULT_wxUSE_MSW=1 ;; @@ -27002,6 +27014,20 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test "$wxUSE_QT" = 1; then + TOOLKIT=QT + GUIDIST=QT_DIST + TOOLKIT_DIR="qt" + + if test -n "$QT5_CUSTOM_DIR" ; then + TOOLKIT_INCLUDE="${TOOLKIT_INCLUDE} -I${QT5_CUSTOM_DIR}/include" + GUI_TK_LIBRARY="${GUI_TK_LIBRARY} -L${QT5_CUSTOM_DIR}/lib \ + -lQt5Core -lQt5Widgets -lQt5Gui -lQt5OpenGL -lQt5Test \ + -Wl,-rpath,${QT5_CUSTOM_DIR}/lib" + + elif test -z "$PKG_CONFIG" ; then + as_fn_error $? "specify QT5_CUSTOM_DIR or make sure pkg-config is available to search for Qt5 libraries" "$LINENO" 5 + + else pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for QT5" >&5 @@ -27062,12 +27088,12 @@ fi echo "$QT5_PKG_ERRORS" >&5 - as_fn_error $? "Qt5 libraries are not available" "$LINENO" 5 + as_fn_error $? "Qt5 libraries are not available" "$LINENO" 5 elif test $pkg_failed = untried; then - as_fn_error $? "Qt5 libraries are not available" "$LINENO" 5 + as_fn_error $? "Qt5 libraries are not available" "$LINENO" 5 else @@ -27076,9 +27102,6 @@ else { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } - TOOLKIT=QT - GUIDIST=QT_DIST - TOOLKIT_DIR="qt" TOOLKIT_INCLUDE="${TOOLKIT_INCLUDE} ${QT5_CFLAGS}" GUI_TK_LIBRARY="${GUI_TK_LIBRARY} ${QT5_LIBS}" if `pkg-config --variable qt_config Qt5Core | grep "reduce_relocations" >/dev/null`; then @@ -27087,6 +27110,7 @@ $as_echo "yes" >&6; } fi fi + fi fi TOOLKIT_DIR=`echo ${TOOLKIT} | tr '[A-Z]' '[a-z]'` @@ -29855,7 +29879,7 @@ EOF HEADER_PAD_OPTION="-headerpad_max_install_names" ;; - *-*-cygwin* | *-*-mingw32* ) + *-*-cygwin* | *-*-mingw32* | *-*-mingw64* ) ;; *-*-hpux* ) @@ -39632,7 +39656,7 @@ fi LDFLAGS_GUI= case ${BAKEFILE_HOST} in - *-*-cygwin* | *-*-mingw32* ) + *-*-cygwin* | *-*-mingw32* | *-*-mingw64* ) LDFLAGS_GUI="-mwindows" esac @@ -40066,7 +40090,7 @@ fi fi ;; - *-*-cygwin* | *-*-mingw32* ) + *-*-cygwin* | *-*-mingw32* | *-*-mingw64* ) PIC_FLAG="" SHARED_LD_CC="\$(CC) -shared -o" SHARED_LD_CXX="\$(CXX) -shared -o" @@ -40311,7 +40335,7 @@ EOF case ${BAKEFILE_HOST} in - *-*-cygwin* | *-*-mingw32* ) + *-*-cygwin* | *-*-mingw32* | *-*-mingw64* ) if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args. set dummy ${ac_tool_prefix}windres; ac_word=$2 diff --git a/configure.in b/configure.in index e0f500ce93..cbd7392216 100644 --- a/configure.in +++ b/configure.in @@ -262,7 +262,7 @@ case "${host}" in AC_DEFINE(__UNIXWARE__) ;; - *-*-cygwin* | *-*-mingw32* ) + *-*-cygwin* | *-*-mingw32* | *-*-mingw64* ) dnl MBN: some of the defines have been moved after toolkit detection dnl because for wxMotif/wxGTK/wxX11 to build on Cygwin dnl USE_UNIX must be set and not USE_WIN32 @@ -3361,12 +3361,24 @@ libraries returned by 'pkg-config gtk+-2.0 --libs' or 'gtk-config if test "$wxUSE_QT" = 1; then - PKG_CHECK_MODULES(QT5, + TOOLKIT=QT + GUIDIST=QT_DIST + TOOLKIT_DIR="qt" + + if test -n "$QT5_CUSTOM_DIR" ; then + dnl the name of the directory where the files for this toolkit live + TOOLKIT_INCLUDE="${TOOLKIT_INCLUDE} -I${QT5_CUSTOM_DIR}/include" + GUI_TK_LIBRARY="${GUI_TK_LIBRARY} -L${QT5_CUSTOM_DIR}/lib \ + -lQt5Core -lQt5Widgets -lQt5Gui -lQt5OpenGL -lQt5Test \ + -Wl,-rpath,${QT5_CUSTOM_DIR}/lib" + + elif test -z "$PKG_CONFIG" ; then + AC_MSG_ERROR([specify QT5_CUSTOM_DIR or make sure pkg-config is available to search for Qt5 libraries]) + + else + PKG_CHECK_MODULES(QT5, [Qt5Core Qt5Widgets Qt5Gui Qt5OpenGL Qt5Test], - [ - TOOLKIT=QT - GUIDIST=QT_DIST - TOOLKIT_DIR="qt" + [ TOOLKIT_INCLUDE="${TOOLKIT_INCLUDE} ${QT5_CFLAGS}" GUI_TK_LIBRARY="${GUI_TK_LIBRARY} ${QT5_LIBS}" if `pkg-config --variable qt_config Qt5Core | grep "reduce_relocations" >/dev/null`; then @@ -3374,11 +3386,12 @@ libraries returned by 'pkg-config gtk+-2.0 --libs' or 'gtk-config SAMPLES_CXXFLAGS="-fPIC $SAMPLES_CXXFLAGS" WXCONFIG_CXXFLAGS="-fPIC $WXCONFIG_CXXFLAGS" fi - ], - [ - AC_MSG_ERROR([Qt5 libraries are not available]) - ] - ) + ], + [ + AC_MSG_ERROR([Qt5 libraries are not available]) + ] + ) + fi fi dnl the name of the directory where the files for this toolkit live TOOLKIT_DIR=`echo ${TOOLKIT} | tr '[[A-Z]]' '[[a-z]]'` @@ -3699,7 +3712,7 @@ EOF HEADER_PAD_OPTION="-headerpad_max_install_names" ;; - *-*-cygwin* | *-*-mingw32* ) + *-*-cygwin* | *-*-mingw32* | *-*-mingw64* ) ;; *-*-hpux* ) diff --git a/docs/qt/install.txt b/docs/qt/install.txt index 3bed60b9a5..c3868ab6c7 100644 --- a/docs/qt/install.txt +++ b/docs/qt/install.txt @@ -91,6 +91,21 @@ cd tests make ./test_gui +* Building wxQT, using qt-unified-XXX-online installer +------------------------------------------------------ + +Download qt-unified-XXX-online installer from the qt website. +Install the Qt package of your choice (with the same minimum version +restriction as above). +The same build instructions apply, except that you need to explicitly pass +to configure the Qt dir of the build intended to use as QT5_CUSTOM_DIR, i.e. + +# for Linux: +../configure --with-qt --enable-debug QT5_CUSTOM_DIR=~/Qt/5.11.0/gcc_64 + +# for Windows (ran from Git Bash, or any other Unix-like shell): +../configure --with-qt --enable-debug QT5_CUSTOM_DIR=/c/Qt/5.11.0/mingw53_32 + * Building wxGT on Android -------------------------- diff --git a/include/wx/chkconf.h b/include/wx/chkconf.h index 106918e031..586680b307 100644 --- a/include/wx/chkconf.h +++ b/include/wx/chkconf.h @@ -1721,6 +1721,11 @@ # endif #endif +#if wxUSE_ACTIVITYINDICATOR && !wxUSE_GRAPHICS_CONTEXT +# undef wxUSE_ACTIVITYINDICATOR +# define wxUSE_ACTIVITYINDICATOR 0 +#endif /* wxUSE_ACTIVITYINDICATOR */ + #if wxUSE_GRAPHICS_CONTEXT && !wxUSE_GEOMETRY # ifdef wxABORT_ON_CONFIG_ERROR # error "wxUSE_GRAPHICS_CONTEXT requires wxUSE_GEOMETRY" @@ -1737,7 +1742,7 @@ # undef wxUSE_DC_TRANSFORM_MATRIX # define wxUSE_DC_TRANSFORM_MATRIX 0 # endif -#endif /* wxUSE_GRAPHICS_CONTEXT */ +#endif /* wxUSE_DC_TRANSFORM_MATRIX */ /* generic controls dependencies */ #if !defined(__WXMSW__) || defined(__WXUNIVERSAL__) diff --git a/src/common/utilscmn.cpp b/src/common/utilscmn.cpp index 6000660563..729c51da67 100644 --- a/src/common/utilscmn.cpp +++ b/src/common/utilscmn.cpp @@ -108,7 +108,7 @@ #endif #if wxUSE_GUI && defined(__WXQT__) - #include // for QT_VERSION_STR constants + #include // for QT_VERSION_STR constants #endif #if wxUSE_BASE diff --git a/src/qt/apptraits.cpp b/src/qt/apptraits.cpp index f196158be2..1f1553f6c0 100644 --- a/src/qt/apptraits.cpp +++ b/src/qt/apptraits.cpp @@ -15,7 +15,7 @@ #include "wx/timer.h" #include "wx/qt/private/timer.h" -#include +#include wxEventLoopBase *wxGUIAppTraits::CreateEventLoop() { diff --git a/src/qt/clipbrd.cpp b/src/qt/clipbrd.cpp index d692f6627e..5a39a623c2 100644 --- a/src/qt/clipbrd.cpp +++ b/src/qt/clipbrd.cpp @@ -12,8 +12,8 @@ #pragma hdrstop #endif -#include -#include +#include +#include #include "wx/clipbrd.h" #include "wx/scopedarray.h" diff --git a/src/qt/cursor.cpp b/src/qt/cursor.cpp index 442e250458..880a2799fa 100644 --- a/src/qt/cursor.cpp +++ b/src/qt/cursor.cpp @@ -12,8 +12,8 @@ #pragma hdrstop #endif -#include -#include +#include +#include #ifndef WX_PRECOMP #include "wx/bitmap.h" diff --git a/src/qt/dcscreen.cpp b/src/qt/dcscreen.cpp index dd0e6f11b8..b42445ea3a 100644 --- a/src/qt/dcscreen.cpp +++ b/src/qt/dcscreen.cpp @@ -13,8 +13,8 @@ #include #include -#include -#include +#include +#include wxIMPLEMENT_ABSTRACT_CLASS(wxScreenDCImpl, wxWindowDCImpl); diff --git a/src/qt/listctrl.cpp b/src/qt/listctrl.cpp index 7c9c9940cd..7ddd3b8d79 100644 --- a/src/qt/listctrl.cpp +++ b/src/qt/listctrl.cpp @@ -12,7 +12,7 @@ #pragma hdrstop #endif -#include +#include #ifndef WX_PRECOMP #include "wx/bitmap.h" diff --git a/src/qt/toolbar.cpp b/src/qt/toolbar.cpp index cad52f82cb..c6ec8adc5c 100644 --- a/src/qt/toolbar.cpp +++ b/src/qt/toolbar.cpp @@ -14,7 +14,7 @@ #if wxUSE_TOOLBAR -#include +#include #include #ifndef WX_PRECOMP diff --git a/src/qt/uiaction.cpp b/src/qt/uiaction.cpp index 6490cf35d9..0df9863b9c 100644 --- a/src/qt/uiaction.cpp +++ b/src/qt/uiaction.cpp @@ -16,8 +16,8 @@ #include "wx/private/uiaction.h" #include -#include -#include +#include +#include #include "wx/qt/defs.h" #include "wx/qt/private/utils.h"