From 9e87457f4b97e5ebd2c049e90948aa21f4844817 Mon Sep 17 00:00:00 2001 From: Ivailo Monev Date: Mon, 14 Nov 2022 15:36:36 +0200 Subject: [PATCH] remove now unused plugin verification section and data it should've been added even if QT_NO_PLUGIN_CHECK was defined btw, now only ELF header is checked tho Signed-off-by: Ivailo Monev --- src/core/plugin/qplugin.h | 26 +++++++------------------- 1 file changed, 7 insertions(+), 19 deletions(-) diff --git a/src/core/plugin/qplugin.h b/src/core/plugin/qplugin.h index 73e0da858..9495097c6 100644 --- a/src/core/plugin/qplugin.h +++ b/src/core/plugin/qplugin.h @@ -24,34 +24,22 @@ #include - QT_BEGIN_NAMESPACE typedef QObject *(*QtPluginInstanceFunction)(); -#define Q_EXPORT_PLUGIN(PLUGIN) \ - Q_EXPORT_PLUGIN2(PLUGIN, PLUGIN) - -#if !defined(QT_NO_PLUGIN_CHECK) -# define Q_PLUGIN_VERIFICATION_SECTION \ - __attribute__((section (".ktplugin"))) __attribute__((used)) \ - static const char kt_plugin_verification_data[] = QT_VERSION_HEX_STR; -#else -# define Q_PLUGIN_VERIFICATION_SECTION -#endif - // NOTE: if you change pattern, you MUST change the pattern in // qlibrary.cpp as well. changing the pattern will break all // backwards compatibility as well (no old plugins will be loaded). #define Q_EXPORT_PLUGIN2(PLUGIN, PLUGINCLASS) \ - Q_PLUGIN_VERIFICATION_SECTION \ - extern "C" Q_DECL_EXPORT QT_PREPEND_NAMESPACE(QObject) * kt_plugin_instance() \ - { \ - static QT_PREPEND_NAMESPACE(QPointer) _instance(new PLUGINCLASS); \ - return _instance; \ - } + extern "C" Q_DECL_EXPORT QT_PREPEND_NAMESPACE(QObject) * kt_plugin_instance() \ + { \ + static QT_PREPEND_NAMESPACE(QPointer) _instance(new PLUGINCLASS); \ + return _instance; \ + } + +#define Q_EXPORT_PLUGIN(PLUGIN) Q_EXPORT_PLUGIN2(PLUGIN, PLUGIN) QT_END_NAMESPACE - #endif // Q_PLUGIN_H