]> git.lyx.org Git - lyx.git/blobdiff - config/qt4.m4
Fix #10760
[lyx.git] / config / qt4.m4
index 2f5f775632cb63fa9ebff1d25e5e33bf4fa4e9e9..1cf557d637239bd9ce3fb0df98904c9e283fde6b 100644 (file)
@@ -179,11 +179,14 @@ AC_DEFUN([QT_DO_IT_ALL],
        ])
 
        save_CPPFLAGS=$CPPFLAGS
-       AC_MSG_CHECKING([whether Qt uses the X Window system])
        CPPFLAGS="$save_CPPFLAGS $QT_CORE_INCLUDES"
+       AC_CHECK_HEADER(QtGui/qtgui-config.h,
+         [lyx_qt5_config=QtGui/qtgui-config.h],
+         [lyx_qt5_config=qconfig.h],[-])
+       AC_MSG_CHECKING([whether Qt uses the X Window system])
        if test x$USE_QT5 = xyes ; then
          AC_EGREP_CPP(xcb,
-           [#include <qconfig.h>
+           [#include <$lyx_qt5_config>
            QT_QPA_DEFAULT_PLATFORM_NAME],
            [AC_MSG_RESULT(yes)
             AC_DEFINE(QPA_XCB, 1, [Define if Qt uses the X Window System])],