|
|
@ -84,7 +84,7 @@ dnl Outputs: bitcoin_enable_qt, bitcoin_enable_qt_dbus, bitcoin_enable_qt_test |
|
|
|
AC_DEFUN([BITCOIN_QT_CONFIGURE],[ |
|
|
|
AC_DEFUN([BITCOIN_QT_CONFIGURE],[ |
|
|
|
use_pkgconfig=$1 |
|
|
|
use_pkgconfig=$1 |
|
|
|
|
|
|
|
|
|
|
|
if test x$use_pkgconfig == x; then |
|
|
|
if test x$use_pkgconfig = x; then |
|
|
|
use_pkgconfig=yes |
|
|
|
use_pkgconfig=yes |
|
|
|
fi |
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
@ -106,9 +106,9 @@ AC_DEFUN([BITCOIN_QT_CONFIGURE],[ |
|
|
|
BITCOIN_QT_CHECK([ |
|
|
|
BITCOIN_QT_CHECK([ |
|
|
|
TEMP_CPPFLAGS=$CPPFLAGS |
|
|
|
TEMP_CPPFLAGS=$CPPFLAGS |
|
|
|
CPPFLAGS=$QT_INCLUDES |
|
|
|
CPPFLAGS=$QT_INCLUDES |
|
|
|
if test x$bitcoin_qt_got_major_vers == x5; then |
|
|
|
if test x$bitcoin_qt_got_major_vers = x5; then |
|
|
|
_BITCOIN_QT_IS_STATIC |
|
|
|
_BITCOIN_QT_IS_STATIC |
|
|
|
if test x$bitcoin_cv_static_qt == xyes; then |
|
|
|
if test x$bitcoin_cv_static_qt = xyes; then |
|
|
|
AC_DEFINE(QT_STATICPLUGIN, 1, [Define this symbol if qt plugins are static]) |
|
|
|
AC_DEFINE(QT_STATICPLUGIN, 1, [Define this symbol if qt plugins are static]) |
|
|
|
if test x$qt_plugin_path != x; then |
|
|
|
if test x$qt_plugin_path != x; then |
|
|
|
QT_LIBS="$QT_LIBS -L$qt_plugin_path/accessible" |
|
|
|
QT_LIBS="$QT_LIBS -L$qt_plugin_path/accessible" |
|
|
@ -118,14 +118,14 @@ AC_DEFUN([BITCOIN_QT_CONFIGURE],[ |
|
|
|
PKG_CHECK_MODULES([QTPLATFORM], [Qt5PlatformSupport], [QT_LIBS="$QTPLATFORM_LIBS $QT_LIBS"]) |
|
|
|
PKG_CHECK_MODULES([QTPLATFORM], [Qt5PlatformSupport], [QT_LIBS="$QTPLATFORM_LIBS $QT_LIBS"]) |
|
|
|
fi |
|
|
|
fi |
|
|
|
_BITCOIN_QT_CHECK_STATIC_PLUGINS([Q_IMPORT_PLUGIN(AccessibleFactory)], [-lqtaccessiblewidgets]) |
|
|
|
_BITCOIN_QT_CHECK_STATIC_PLUGINS([Q_IMPORT_PLUGIN(AccessibleFactory)], [-lqtaccessiblewidgets]) |
|
|
|
if test x$TARGET_OS == xwindows; then |
|
|
|
if test x$TARGET_OS = xwindows; then |
|
|
|
_BITCOIN_QT_CHECK_STATIC_PLUGINS([Q_IMPORT_PLUGIN(QWindowsIntegrationPlugin)],[-lqwindows]) |
|
|
|
_BITCOIN_QT_CHECK_STATIC_PLUGINS([Q_IMPORT_PLUGIN(QWindowsIntegrationPlugin)],[-lqwindows]) |
|
|
|
AC_DEFINE(QT_QPA_PLATFORM_WINDOWS, 1, [Define this symbol if the qt platform is windows]) |
|
|
|
AC_DEFINE(QT_QPA_PLATFORM_WINDOWS, 1, [Define this symbol if the qt platform is windows]) |
|
|
|
elif test x$TARGET_OS == xlinux; then |
|
|
|
elif test x$TARGET_OS = xlinux; then |
|
|
|
PKG_CHECK_MODULES([X11XCB], [x11-xcb], [QT_LIBS="$X11XCB_LIBS $QT_LIBS"]) |
|
|
|
PKG_CHECK_MODULES([X11XCB], [x11-xcb], [QT_LIBS="$X11XCB_LIBS $QT_LIBS"]) |
|
|
|
_BITCOIN_QT_CHECK_STATIC_PLUGINS([Q_IMPORT_PLUGIN(QXcbIntegrationPlugin)],[-lqxcb -lxcb-static]) |
|
|
|
_BITCOIN_QT_CHECK_STATIC_PLUGINS([Q_IMPORT_PLUGIN(QXcbIntegrationPlugin)],[-lqxcb -lxcb-static]) |
|
|
|
AC_DEFINE(QT_QPA_PLATFORM_XCB, 1, [Define this symbol if the qt platform is xcb]) |
|
|
|
AC_DEFINE(QT_QPA_PLATFORM_XCB, 1, [Define this symbol if the qt platform is xcb]) |
|
|
|
elif test x$TARGET_OS == xdarwin; then |
|
|
|
elif test x$TARGET_OS = xdarwin; then |
|
|
|
if test x$use_pkgconfig = xyes; then |
|
|
|
if test x$use_pkgconfig = xyes; then |
|
|
|
PKG_CHECK_MODULES([QTPRINT], [Qt5PrintSupport], [QT_LIBS="$QTPRINT_LIBS $QT_LIBS"]) |
|
|
|
PKG_CHECK_MODULES([QTPRINT], [Qt5PrintSupport], [QT_LIBS="$QTPRINT_LIBS $QT_LIBS"]) |
|
|
|
fi |
|
|
|
fi |
|
|
@ -135,7 +135,7 @@ AC_DEFUN([BITCOIN_QT_CONFIGURE],[ |
|
|
|
fi |
|
|
|
fi |
|
|
|
fi |
|
|
|
fi |
|
|
|
else |
|
|
|
else |
|
|
|
if test x$TARGET_OS == xwindows; then |
|
|
|
if test x$TARGET_OS = xwindows; then |
|
|
|
AC_DEFINE(QT_STATICPLUGIN, 1, [Define this symbol if qt plugins are static]) |
|
|
|
AC_DEFINE(QT_STATICPLUGIN, 1, [Define this symbol if qt plugins are static]) |
|
|
|
if test x$qt_plugin_path != x; then |
|
|
|
if test x$qt_plugin_path != x; then |
|
|
|
QT_LIBS="$QT_LIBS -L$qt_plugin_path/accessible" |
|
|
|
QT_LIBS="$QT_LIBS -L$qt_plugin_path/accessible" |
|
|
@ -196,7 +196,7 @@ AC_DEFUN([BITCOIN_QT_CONFIGURE],[ |
|
|
|
if test x$use_dbus = xyes && test x$have_qt_dbus = xno; then |
|
|
|
if test x$use_dbus = xyes && test x$have_qt_dbus = xno; then |
|
|
|
AC_MSG_ERROR("libQtDBus not found. Install libQtDBus or remove --with-qtdbus.") |
|
|
|
AC_MSG_ERROR("libQtDBus not found. Install libQtDBus or remove --with-qtdbus.") |
|
|
|
fi |
|
|
|
fi |
|
|
|
if test x$LUPDATE == x; then |
|
|
|
if test x$LUPDATE = x; then |
|
|
|
AC_MSG_WARN("lupdate is required to update qt translations") |
|
|
|
AC_MSG_WARN("lupdate is required to update qt translations") |
|
|
|
fi |
|
|
|
fi |
|
|
|
],[ |
|
|
|
],[ |
|
|
@ -291,10 +291,10 @@ dnl Outputs: have_qt_test and have_qt_dbus are set (if applicable) to yes|no. |
|
|
|
AC_DEFUN([_BITCOIN_QT_FIND_LIBS_WITH_PKGCONFIG],[ |
|
|
|
AC_DEFUN([_BITCOIN_QT_FIND_LIBS_WITH_PKGCONFIG],[ |
|
|
|
m4_ifdef([PKG_CHECK_MODULES],[ |
|
|
|
m4_ifdef([PKG_CHECK_MODULES],[ |
|
|
|
auto_priority_version=$1 |
|
|
|
auto_priority_version=$1 |
|
|
|
if test x$auto_priority_version == x; then |
|
|
|
if test x$auto_priority_version = x; then |
|
|
|
auto_priority_version=qt5 |
|
|
|
auto_priority_version=qt5 |
|
|
|
fi |
|
|
|
fi |
|
|
|
if test x$bitcoin_qt_want_version == xqt5 || ( test x$bitcoin_qt_want_version == xauto && test x$auto_priority_version == xqt5 ); then |
|
|
|
if test x$bitcoin_qt_want_version = xqt5 || ( test x$bitcoin_qt_want_version = xauto && test x$auto_priority_version = xqt5 ); then |
|
|
|
QT_LIB_PREFIX=Qt5 |
|
|
|
QT_LIB_PREFIX=Qt5 |
|
|
|
bitcoin_qt_got_major_vers=5 |
|
|
|
bitcoin_qt_got_major_vers=5 |
|
|
|
else |
|
|
|
else |
|
|
@ -304,14 +304,14 @@ AC_DEFUN([_BITCOIN_QT_FIND_LIBS_WITH_PKGCONFIG],[ |
|
|
|
qt5_modules="Qt5Core Qt5Gui Qt5Network Qt5Widgets" |
|
|
|
qt5_modules="Qt5Core Qt5Gui Qt5Network Qt5Widgets" |
|
|
|
qt4_modules="QtCore QtGui QtNetwork" |
|
|
|
qt4_modules="QtCore QtGui QtNetwork" |
|
|
|
BITCOIN_QT_CHECK([ |
|
|
|
BITCOIN_QT_CHECK([ |
|
|
|
if test x$bitcoin_qt_want_version == xqt5 || ( test x$bitcoin_qt_want_version == xauto && test x$auto_priority_version == xqt5 ); then |
|
|
|
if test x$bitcoin_qt_want_version = xqt5 || ( test x$bitcoin_qt_want_version = xauto && test x$auto_priority_version = xqt5 ); then |
|
|
|
PKG_CHECK_MODULES([QT], [$qt5_modules], [QT_INCLUDES="$QT_CFLAGS"; have_qt=yes],[have_qt=no]) |
|
|
|
PKG_CHECK_MODULES([QT], [$qt5_modules], [QT_INCLUDES="$QT_CFLAGS"; have_qt=yes],[have_qt=no]) |
|
|
|
elif test x$bitcoin_qt_want_version == xqt4 || ( test x$bitcoin_qt_want_version == xauto && test x$auto_priority_version == xqt4 ); then |
|
|
|
elif test x$bitcoin_qt_want_version = xqt4 || ( test x$bitcoin_qt_want_version = xauto && test x$auto_priority_version = xqt4 ); then |
|
|
|
PKG_CHECK_MODULES([QT], [$qt4_modules], [QT_INCLUDES="$QT_CFLAGS"; have_qt=yes], [have_qt=no]) |
|
|
|
PKG_CHECK_MODULES([QT], [$qt4_modules], [QT_INCLUDES="$QT_CFLAGS"; have_qt=yes], [have_qt=no]) |
|
|
|
fi |
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
dnl qt version is set to 'auto' and the preferred version wasn't found. Now try the other. |
|
|
|
dnl qt version is set to 'auto' and the preferred version wasn't found. Now try the other. |
|
|
|
if test x$have_qt == xno && test x$bitcoin_qt_want_version == xauto; then |
|
|
|
if test x$have_qt = xno && test x$bitcoin_qt_want_version = xauto; then |
|
|
|
if test x$auto_priority_version = x$qt5; then |
|
|
|
if test x$auto_priority_version = x$qt5; then |
|
|
|
PKG_CHECK_MODULES([QT], [$qt4_modules], [QT_INCLUDES="$QT_CFLAGS"; have_qt=yes; QT_LIB_PREFIX=Qt; bitcoin_qt_got_major_vers=4], [have_qt=no]) |
|
|
|
PKG_CHECK_MODULES([QT], [$qt4_modules], [QT_INCLUDES="$QT_CFLAGS"; have_qt=yes; QT_LIB_PREFIX=Qt; bitcoin_qt_got_major_vers=4], [have_qt=no]) |
|
|
|
else |
|
|
|
else |
|
|
@ -358,7 +358,7 @@ AC_DEFUN([_BITCOIN_QT_FIND_LIBS_WITHOUT_PKGCONFIG],[ |
|
|
|
if test x$bitcoin_qt_want_version = xauto; then |
|
|
|
if test x$bitcoin_qt_want_version = xauto; then |
|
|
|
_BITCOIN_QT_CHECK_QT5 |
|
|
|
_BITCOIN_QT_CHECK_QT5 |
|
|
|
fi |
|
|
|
fi |
|
|
|
if test x$bitcoin_cv_qt5 == xyes || test x$bitcoin_qt_want_version = xqt5; then |
|
|
|
if test x$bitcoin_cv_qt5 = xyes || test x$bitcoin_qt_want_version = xqt5; then |
|
|
|
QT_LIB_PREFIX=Qt5 |
|
|
|
QT_LIB_PREFIX=Qt5 |
|
|
|
bitcoin_qt_got_major_vers=5 |
|
|
|
bitcoin_qt_got_major_vers=5 |
|
|
|
else |
|
|
|
else |
|
|
@ -373,7 +373,7 @@ AC_DEFUN([_BITCOIN_QT_FIND_LIBS_WITHOUT_PKGCONFIG],[ |
|
|
|
LIBS="$LIBS -L$qt_lib_path" |
|
|
|
LIBS="$LIBS -L$qt_lib_path" |
|
|
|
fi |
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
if test x$TARGET_OS == xwindows; then |
|
|
|
if test x$TARGET_OS = xwindows; then |
|
|
|
AC_CHECK_LIB([imm32], [main],, BITCOIN_QT_FAIL(libimm32 not found)) |
|
|
|
AC_CHECK_LIB([imm32], [main],, BITCOIN_QT_FAIL(libimm32 not found)) |
|
|
|
fi |
|
|
|
fi |
|
|
|
]) |
|
|
|
]) |
|
|
@ -385,7 +385,7 @@ AC_DEFUN([_BITCOIN_QT_FIND_LIBS_WITHOUT_PKGCONFIG],[ |
|
|
|
BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}Core] ,[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXCore not found))) |
|
|
|
BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}Core] ,[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXCore not found))) |
|
|
|
BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}Gui] ,[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXGui not found))) |
|
|
|
BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}Gui] ,[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXGui not found))) |
|
|
|
BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}Network],[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXNetwork not found))) |
|
|
|
BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}Network],[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXNetwork not found))) |
|
|
|
if test x$bitcoin_qt_got_major_vers == x5; then |
|
|
|
if test x$bitcoin_qt_got_major_vers = x5; then |
|
|
|
BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}Widgets],[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXWidgets not found))) |
|
|
|
BITCOIN_QT_CHECK(AC_CHECK_LIB([${QT_LIB_PREFIX}Widgets],[main],,BITCOIN_QT_FAIL(lib$QT_LIB_PREFIXWidgets not found))) |
|
|
|
fi |
|
|
|
fi |
|
|
|
QT_LIBS="$LIBS" |
|
|
|
QT_LIBS="$LIBS" |
|
|
|