From 0d7ed8f5f3b8a308c495c71c7427b41157d769b1 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Fri, 10 Feb 2017 17:39:47 +0100 Subject: streamline libdl detection and linking instead of having a library and a test, use a library with two sources, the first being empty (i.e., just libc). this allows us doing away with the "libdl" feature, and using just the "dlopen" one. subsequently, replace all LIBS+=$$QMAKE_LIBS_DYNLOAD with QMAKE_USE+=libdl. the definitions of QMAKE_LIBS_DYNLOAD remain in the qmakespecs for backwards compat only. n.b.: the only specs where it is not empty or "-ldl" (i.e., what we support now) are the hpux ones, where the library is called 'dld'. technically, the "library" feature should depend on '!unix || dlopen', but that's for a later patch. Change-Id: Ib8546affc4b7bc757f1a76729573ddd00e152176 Reviewed-by: Lars Knoll Reviewed-by: Ulf Hermann --- src/plugins/platforms/eglfs/eglfsdeviceintegration.pro | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/plugins/platforms/eglfs') diff --git a/src/plugins/platforms/eglfs/eglfsdeviceintegration.pro b/src/plugins/platforms/eglfs/eglfsdeviceintegration.pro index 35af3615bd..2593df937b 100644 --- a/src/plugins/platforms/eglfs/eglfsdeviceintegration.pro +++ b/src/plugins/platforms/eglfs/eglfsdeviceintegration.pro @@ -17,8 +17,6 @@ QT += \ qtHaveModule(input_support-private): \ QT += input_support-private -LIBS += $$QMAKE_LIBS_DYNLOAD - # Avoid X11 header collision, use generic EGL native types DEFINES += QT_EGL_NO_X11 -- cgit v1.2.3 From d6330a19b29ebff359a6746250c78437dbcaf77d Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Mon, 19 Dec 2016 10:34:32 +0100 Subject: Use QT_CONFIG(library) instead of QT_NO_LIBRARY For the windows file system engine, we add an extra macro to use library loading if configured to do so, but avoid it on WinRT, as none of the symbols would be found. We also QT_REQUIRE_CONFIG(library) in the library headers and exclude the sources from the build if library loading is disabled. This, in turn, makes it necessary to clean up some header inclusions. Change-Id: I2b152cb5b47a2658996b6f4702b038536a5704ec Reviewed-by: Oswald Buddenhagen --- src/plugins/platforms/eglfs/api/qeglfsdeviceintegration.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/plugins/platforms/eglfs') diff --git a/src/plugins/platforms/eglfs/api/qeglfsdeviceintegration.cpp b/src/plugins/platforms/eglfs/api/qeglfsdeviceintegration.cpp index 863a115b74..3558b929fa 100644 --- a/src/plugins/platforms/eglfs/api/qeglfsdeviceintegration.cpp +++ b/src/plugins/platforms/eglfs/api/qeglfsdeviceintegration.cpp @@ -69,16 +69,16 @@ Q_LOGGING_CATEGORY(qLcEglDevDebug, "qt.qpa.egldeviceintegration") Q_GLOBAL_STATIC_WITH_ARGS(QFactoryLoader, loader, (QEglFSDeviceIntegrationFactoryInterface_iid, QLatin1String("/egldeviceintegrations"), Qt::CaseInsensitive)) -#ifndef QT_NO_LIBRARY +#if QT_CONFIG(library) Q_GLOBAL_STATIC_WITH_ARGS(QFactoryLoader, directLoader, (QEglFSDeviceIntegrationFactoryInterface_iid, QLatin1String(""), Qt::CaseInsensitive)) -#endif // QT_NO_LIBRARY +#endif // QT_CONFIG(library) QStringList QEglFSDeviceIntegrationFactory::keys(const QString &pluginPath) { QStringList list; -#ifndef QT_NO_LIBRARY +#if QT_CONFIG(library) if (!pluginPath.isEmpty()) { QCoreApplication::addLibraryPath(pluginPath); list = directLoader()->keyMap().values(); @@ -102,7 +102,7 @@ QStringList QEglFSDeviceIntegrationFactory::keys(const QString &pluginPath) QEglFSDeviceIntegration *QEglFSDeviceIntegrationFactory::create(const QString &key, const QString &pluginPath) { QEglFSDeviceIntegration *integration = Q_NULLPTR; -#ifndef QT_NO_LIBRARY +#if QT_CONFIG(library) if (!pluginPath.isEmpty()) { QCoreApplication::addLibraryPath(pluginPath); integration = qLoadPlugin(directLoader(), key); -- cgit v1.2.3