Skip to content

Commit 57b6522

Browse files
committed
build, qt: Make Qt static libs check regardless of plugindir
Qt static libs reside in libdir.
1 parent 6203457 commit 57b6522

File tree

1 file changed

+12
-10
lines changed

1 file changed

+12
-10
lines changed

build-aux/m4/bitcoin_qt.m4

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,17 @@ AC_DEFUN([BITCOIN_QT_CONFIGURE],[
121121
_BITCOIN_QT_IS_STATIC
122122
if test "x$bitcoin_cv_static_qt" = xyes; then
123123
_BITCOIN_QT_CHECK_STATIC_LIBS
124+
125+
if test "x$qt_plugin_path" != x; then
126+
QT_LIBS="$QT_LIBS -L$qt_plugin_path/platforms"
127+
if test -d "$qt_plugin_path/accessible"; then
128+
QT_LIBS="$QT_LIBS -L$qt_plugin_path/accessible"
129+
fi
130+
if test -d "$qt_plugin_path/platforms/android"; then
131+
QT_LIBS="$QT_LIBS -L$qt_plugin_path/platforms/android -lqtfreetype -lEGL"
132+
fi
133+
fi
134+
124135
AC_DEFINE(QT_STATICPLUGIN, 1, [Define this symbol if qt plugins are static])
125136
if test "x$TARGET_OS" != xandroid; then
126137
_BITCOIN_QT_CHECK_STATIC_PLUGIN([QMinimalIntegrationPlugin], [-lqminimal])
@@ -307,16 +318,8 @@ dnl _BITCOIN_QT_CHECK_STATIC_LIBS
307318
dnl -----------------------------
308319
dnl
309320
dnl Inputs: no inputs.
310-
dnl Outputs: QT_LIBS is appended
321+
dnl Outputs: QT_LIBS is prepended.
311322
AC_DEFUN([_BITCOIN_QT_CHECK_STATIC_LIBS], [
312-
if test "x$qt_plugin_path" != x; then
313-
QT_LIBS="$QT_LIBS -L$qt_plugin_path/platforms"
314-
if test -d "$qt_plugin_path/accessible"; then
315-
QT_LIBS="$QT_LIBS -L$qt_plugin_path/accessible"
316-
fi
317-
if test -d "$qt_plugin_path/platforms/android"; then
318-
QT_LIBS="$QT_LIBS -L$qt_plugin_path/platforms/android -lqtfreetype -lEGL"
319-
fi
320323
PKG_CHECK_MODULES([QTFONTDATABASE], [Qt5FontDatabaseSupport${qt_lib_suffix}], [QT_LIBS="-lQt5FontDatabaseSupport${qt_lib_suffix} $QT_LIBS"])
321324
PKG_CHECK_MODULES([QTEVENTDISPATCHER], [Qt5EventDispatcherSupport${qt_lib_suffix}], [QT_LIBS="-lQt5EventDispatcherSupport${qt_lib_suffix} $QT_LIBS"])
322325
PKG_CHECK_MODULES([QTTHEME], [Qt5ThemeSupport${qt_lib_suffix}], [QT_LIBS="-lQt5ThemeSupport${qt_lib_suffix} $QT_LIBS"])
@@ -330,7 +333,6 @@ AC_DEFUN([_BITCOIN_QT_CHECK_STATIC_LIBS], [
330333
PKG_CHECK_MODULES([QTGRAPHICS], [Qt5GraphicsSupport${qt_lib_suffix}], [QT_LIBS="-lQt5GraphicsSupport${qt_lib_suffix} $QT_LIBS"])
331334
PKG_CHECK_MODULES([QTCGL], [Qt5CglSupport${qt_lib_suffix}], [QT_LIBS="-lQt5CglSupport${qt_lib_suffix} $QT_LIBS"])
332335
fi
333-
fi
334336
])
335337

336338
dnl Internal. Find Qt libraries using pkg-config.

0 commit comments

Comments
 (0)