[Libreoffice-commits] core.git: Branch 'feature/kde5' - configure.ac vcl/unx

Katarina Behrens Katarina.Behrens at cib.de
Thu Oct 19 20:53:00 UTC 2017


Rebased ref, commits from common ancestor:
commit f8151b9fa3b743fb05b23f042b75ea20afa49510
Author: Katarina Behrens <Katarina.Behrens at cib.de>
Date:   Thu Oct 19 22:25:49 2017 +0200

    Fix glib detection for KF5
    
    Change-Id: Ibd25502384cd248f1070d26266222e18fb9e2e47

diff --git a/configure.ac b/configure.ac
index a14fded670a9..892d77b917bb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -11014,10 +11014,21 @@ int main(int argc, char **argv) {
        if (KCOREADDONS_VERSION_MAJOR == 5 && KCOREADDONS_VERSION_MINOR >= 0) return 0;
        else return 1;
 }
-       ]])],[AC_MSG_RESULT([yes])],[AC_MSG_ERROR([KDE version too old])],[])
+]])],[AC_MSG_RESULT([yes])],[AC_MSG_ERROR([KDE5 version too old])],[])
     CXXFLAGS=$save_CXXFLAGS
     AC_LANG_POP([C++])
 
+    # Glib is needed for properly handling Qt event loop with Qt's Glib integration enabled.
+    # Sets also KF5_GLIB_CFLAGS/KF5_GLIB_LIBS if successful.
+    PKG_CHECK_MODULES(KF5_GLIB,[glib-2.0 >= 2.4],
+        [
+            KF5_HAVE_GLIB=TRUE
+            AC_DEFINE(KF5_HAVE_GLIB,1)
+            KF5_GLIB_CFLAGS=$(printf '%s' "$KF5_GLIB_CFLAGS" | sed -e "s/-I/${ISYSTEM?}/g")
+            FilterLibs "${KF5_GLIB_LIBS}"
+            KF5_GLIB_LIBS="${filteredlibs}"
+        ],
+        AC_MSG_WARN([[No Glib found, KDE5 support will not use native file pickers!]]))
 fi
 AC_SUBST(KF5_CFLAGS)
 AC_SUBST(KF5_LIBS)
diff --git a/vcl/unx/kde5/KDE5XLib.cxx b/vcl/unx/kde5/KDE5XLib.cxx
index d9b8e747f3c8..32a80ad8644a 100644
--- a/vcl/unx/kde5/KDE5XLib.cxx
+++ b/vcl/unx/kde5/KDE5XLib.cxx
@@ -397,7 +397,7 @@ uno::Reference< ui::dialogs::XFilePicker2 > KDE5XLib::createFilePicker(
         SalYieldMutexReleaser aReleaser;
         return Q_EMIT createFilePickerSignal( xMSF );
     }
-    return uno::Reference< ui::dialogs::XFilePicker2 >( new KDE4FilePicker( xMSF ) );
+    //return uno::Reference< ui::dialogs::XFilePicker2 >( new KDE4FilePicker( xMSF ) );
 #else
     (void)xMSF;
     return NULL;


More information about the Libreoffice-commits mailing list