qt5base-lts/sync.profile
Girish Ramakrishnan 36547f4eff Expose QPA API under qpa/*
The main reasons for doing this are:
1. _qpa.h end up in the master QtGui include file. QtGui is meant for
userland applications. qpa code is neither binary nor source compatible.
Inadvertant use of QPA api makes the user code binary-incompatible.
2. syncqt creates forwarding headers for non-private header files. This
gives people the impression that this is public API.

As discussed on the mailing list, even though QPA api is internal and subject
to change, it needs to  treated differently from private headers since they
will be used by  in-qtbase and out-of-qtbase plugins.

This commit does the following:
1. The _qpa in QPA header files is dropped.
2. syncqt now treats any file with qplatform prefix as a special file and
moves it to qpa/ directory. The recommended way of using QPA API in plugins
is: #include <qpa/qplatformfoo.h>. This allows the user include QPA API
from multiple modules (for example, qplatformfoo might be in QtPrintSupport)
3. The user needs to explicitly add QT += <module>-private to get access to
the qpa api.
4. Creates compat headers for the olden style qplatformfoo_qpa.h and QPlatformFoo
includes.

This commit does not change the cpp filenames. This requires a more careful
merging of existing non qpa cpp files and existing cpp files on a case by
case basis. This can be done at anytime.

The following files are not renamed as part of this changed but will be fixed
as part of a future change:
src/gui/kernel/qgenericpluginfactory_qpa.h
src/gui/kernel/qgenericplugin_qpa.h
src/gui/kernel/qwindowsysteminterface_qpa.h

files were renamed using

    for x in `find . -name "qplatform*_qpa.h"`; do git mv $x "${x/_qpa.h/.h}"; done
    for x in `find . -name "qplatform*_qpa_p.h"`; do git mv $x "${x/_qpa_p.h/_p.h}"; done

includes were renamed using script

for file in `find . -name "*.h" -or -name "*.cpp" -or -name "*.mm"`; do
    sed -i -e 's,.*#.*include.*<\(Qt.*/\)\?\(QPlatform.*\)>,#include <qpa/\L\2.h>,g' \
        -e 's,.*#.*include.*"\(Qt.*/\)\?\(QPlatform.*\)",#include <qpa/\L\2.h>,g' \
        -e 's,.*#.*include.* "\(qplatform.*\)_qpa.h",#include <qpa/\L\1.h>,g' \
        -e 's,.*#.*include.*"\(qplatform.*\)_qpa_p.h",#include <qpa/\L\1_p.h>,g' \
        -e 's,.*#.*include.*<\(Qt.*/\|Qt.*/private/\|private/\)\?\(qplatform.*\)_qpa\(.*\)>,#include <qpa/\2\3>,g' \
        -e 's,.*#.*include.*"\(Qt.*/\|Qt.*/private/\|private/\)\?\(qplatform.*\)_qpa\(.*\)",#include <qpa/\2\3>,g' \
        $file
done

Change-Id: I04a350314a45746e3911f54b3b21ad03315afb67
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
2012-05-07 20:25:24 +02:00

168 lines
8.5 KiB
Plaintext

%modules = ( # path to module name map
"QtGui" => "$basedir/src/gui",
"QtWidgets" => "$basedir/src/widgets",
"QtPrintSupport" => "$basedir/src/printsupport",
"QtOpenGL" => "$basedir/src/opengl",
"QtCore" => "$basedir/src/corelib",
"QtXml" => "$basedir/src/xml",
"QtSql" => "$basedir/src/sql",
"QtNetwork" => "$basedir/src/network",
"QtTest" => "$basedir/src/testlib",
"QtDBus" => "$basedir/src/dbus",
"QtConcurrent" => "$basedir/src/concurrent",
"QtPlatformSupport" => "$basedir/src/platformsupport",
);
%moduleheaders = ( # restrict the module headers to those found in relative path
);
@allmoduleheadersprivate = (
);
%classnames = (
"qglobal.h" => "QtGlobal",
"qendian.h" => "QtEndian",
"qconfig.h" => "QtConfig",
"qplugin.h" => "QtPlugin",
"qalgorithms.h" => "QtAlgorithms",
"qcontainerfwd.h" => "QtContainerFwd",
"qdebug.h" => "QtDebug",
"qevent.h" => "QtEvents",
"qnamespace.h" => "Qt",
"qssl.h" => "QSsl",
"qtest.h" => "QTest",
"qtconcurrentmap.h" => "QtConcurrentMap",
"qtconcurrentfilter.h" => "QtConcurrentFilter",
"qtconcurrentrun.h" => "QtConcurrentRun",
"qtcoreversion.h" => "QtCoreVersion",
"qtdbusversion.h" => "QtDBusVersion",
"qtguiversion.h" => "QtGuiVersion",
"qtnetworkversion.h" => "QtNetworkVersion",
"qtopenglversion.h" => "QtOpenGLVersion",
"qtsqlversion.h" => "QtSqlVersion",
"qttestversion.h" => "QtTestVersion",
"qtxmlversion.h" => "QtXmlVersion",
"qtwidgetsversion.h" => "QtWidgetsVersion",
"qtprintsupportversion.h" => "QtPrintSupportVersion",
"qtconcurrentversion.h" => "QtConcurrentVersion",
"qtplatformsupportversion.h" => "QtPlatformSupportVersion",
);
%mastercontent = (
"core" => "#include <QtCore/QtCore>\n",
"gui" => "#include <QtGui/QtGui>\n",
"printsupport" => "#include <QtPrintSupport/QtPrintSupport>\n",
"widgets" => "#include <QtWidgets/QtWidgets>\n",
"network" => "#include <QtNetwork/QtNetwork>\n",
"opengl" => "#include <QtOpenGL/QtOpenGL>\n",
"xml" => "#include <QtXml/QtXml>\n",
"concurrent" => "#include <QtConcurrent/QtConcurrent>\n",
);
%modulepris = (
"QtCore" => "$basedir/src/modules/qt_core.pri",
"QtDBus" => "$basedir/src/modules/qt_dbus.pri",
"QtGui" => "$basedir/src/modules/qt_gui.pri",
"QtPrintSupport" => "$basedir/src/modules/qt_printsupport.pri",
"QtWidgets" => "$basedir/src/modules/qt_widgets.pri",
"QtNetwork" => "$basedir/src/modules/qt_network.pri",
"QtOpenGL" => "$basedir/src/modules/qt_opengl.pri",
"QtSql" => "$basedir/src/modules/qt_sql.pri",
"QtTest" => "$basedir/src/modules/qt_testlib.pri",
"QtXml" => "$basedir/src/modules/qt_xml.pri",
"QtConcurrent" => "$basedir/src/modules/qt_concurrent.pri",
"QtPlatformSupport" => "$basedir/src/modules/qt_platformsupport.pri",
);
%deprecatedheaders = (
"QtGui" => {
"qplatformaccessibility_qpa.h" => "qpa/qplatformaccessibility.h",
"QPlatformAccessibility" => "qpa/qplatformaccessibility.h",
"qplatformbackingstore_qpa.h" => "qpa/qplatformbackingstore.h",
"QPlatformBackingStore" => "qpa/qplatformbackingstore.h",
"qplatformclipboard_qpa.h" => "qpa/qplatformclipboard.h",
"QPlatformClipboard" => "qpa/qplatformclipboard.h",
"QPlatformColorDialogHelper" => "qpa/qplatformdialoghelper.h",
"qplatformcursor_qpa.h" => "qpa/qplatformcursor.h",
"QPlatformCursor" => "qpa/qplatformcursor.h",
"QPlatformCursorImage" => "qpa/qplatformcursor.h",
"QPlatformCursorPrivate" => "qpa/qplatformcursor.h",
"qplatformdrag_qpa.h" => "qpa/qplatformdrag.h",
"QPlatformDrag" => "qpa/qplatformdrag.h",
"QPlatformDragQtResponse" => "qpa/qplatformdrag.h",
"QPlatformDropQtResponse" => "qpa/qplatformdrag.h",
"qplatformdialoghelper_qpa.h" => "qpa/qplatformdialoghelper.h",
"QPlatformDialogHelper" => "qpa/qplatformdialoghelper.h",
"QPlatformFileDialogHelper" => "qpa/qplatformdialoghelper.h",
"qplatformfontdatabase_qpa.h" => "qpa/qplatformfontdatabase.h",
"QPlatformFontDatabase" => "qpa/qplatformfontdatabase.h",
"qplatforminputcontext_qpa.h" => "qpa/qplatforminputcontext.h",
"QPlatformInputContext" => "qpa/qplatforminputcontext.h",
"qplatforminputcontext_qpa_p.h" => "qpa/qplatforminputcontext_p.h",
"qplatformintegration_qpa.h" => "qpa/qplatformintegration.h",
"QPlatformIntegration" => "qpa/qplatformintegration.h",
"qplatformintegrationfactory_qpa_p.h" => "qpa/qplatformintegrationfactory_p.h",
"QPlatformIntegrationFactory" => "qpa/qplatformintegrationfactory_p.h",
"qplatformintegrationplugin_qpa.h" => "qpa/qplatformintegrationplugin.h",
"QPlatformIntegrationPlugin" => "qpa/qplatformintegrationplugin.h",
"qplatformnativeinterface_qpa.h" => "qpa/qplatformnativeinterface.h",
"QPlatformNativeInterface" => "qpa/qplatformnativeinterface.h",
"qplatformopenglcontext_qpa.h" => "qpa/qplatformopenglcontext.h",
"QPlatformOpenGLContext" => "qpa/qplatformopenglcontext.h",
"qplatformpixmap_qpa.h" => "qpa/qplatformpixmap.h",
"QPlatformPixmap" => "qpa/qplatformpixmap.h",
"qplatformscreen_qpa.h" => "qpa/qplatformscreen.h",
"QPlatformScreen" => "qpa/qplatformscreen.h",
"qplatformscreen_qpa_p.h" => "qpa/qplatformscreen_p.h",
"QPlatformScreenBuffer" => "qpa/qplatformscreenpageflipper.h",
"qplatformscreenpageflipper_qpa.h" => "qpa/qplatformscreenpageflipper.h",
"QPlatformScreenPageFlipper" => "qpa/qplatformscreenpageflipper.h",
"qplatformservices_qpa.h" => "qpa/qplatformservices.h",
"QPlatformServices" => "qpa/qplatformservices.h",
"qplatformsharedgraphicscache_qpa.h" => "qpa/qplatformsharedgraphicscache.h",
"QPlatformSharedGraphicsCache" => "qpa/qplatformsharedgraphicscache.h",
"qplatformsurface_qpa.h" => "qpa/qplatformsurface.h",
"QPlatformSurface" => "qpa/qplatformsurface.h",
"qplatformtheme_qpa.h" => "qpa/qplatformtheme.h",
"QPlatformTheme" => "qpa/qplatformtheme.h",
"qplatformthemefactory_qpa_p.h" => "qpa/qplatformthemefactory_p.h",
"qplatformthemeplugin_qpa.h" => "qpa/qplatformthemeplugin.h",
"QPlatformThemePlugin" => "qpa/qplatformthemeplugin.h",
"qplatformwindow_qpa.h" => "qpa/qplatformwindow.h",
"QPlatformWindow" => "qpa/qplatformwindow.h"
},
"QtWidgets" => {
"qplatformmenu_qpa.h" => "qpa/qplatformmenu.h",
"QPlatformMenu" => "qpa/qplatformmenu.h",
"QPlatformMenuAction" => "qpa/qplatformmenu.h",
"QPlatformMenuBar" => "qpa/qplatformmenu.h"
},
"QtPrintSupport" => {
"qplatformprintersupport_qpa.h" => "qpa/qplatformprintersupport.h",
"QPlatformPrinterSupport" => "qpa/qplatformprintersupport.h",
"QPlatformPrinterSupportPlugin" => "XXXXXXXXXXXXXXXXXXXX",
"qplatformprintplugin_qpa.h" => "qpa/qplatformprintplugin.h",
"QPlatformPrintPlugin" => "qpa/qplatformprintplugin.h"
},
"QtPlatformSupport" => {
"qplatforminputcontextfactory_qpa_p.h" => "qpa/qplatforminputcontextfactory_p.h",
"qplatforminputcontextplugin_qpa_p.h" => "qpa/qplatforminputcontextplugin_p.h",
"QPlatformInputContextPlugin" => "qpa/qplatforminputcontextplugin_p.h"
}
);
%explicitheaders = (
"QtCore" => {
"QVariantHash" => "qvariant.h",
"QVariantList" => "qvariant.h",
"QVariantMap" => "qvariant.h",
}
);
@ignore_for_master_contents = ( "qt.h", "qpaintdevicedefs.h" );
@ignore_for_include_check = ( "qsystemdetection.h", "qcompilerdetection.h", "qprocessordetection.h" );
@ignore_for_qt_begin_header_check = ( "qiconset.h", "qconfig.h", "qconfig-dist.h", "qconfig-large.h", "qconfig-medium.h", "qconfig-minimal.h", "qconfig-small.h", "qfeatures.h", "qt_windows.h" );
@ignore_for_qt_begin_namespace_check = ( "qconfig.h", "qconfig-dist.h", "qconfig-large.h", "qconfig-medium.h", "qconfig-minimal.h", "qconfig-small.h", "qfeatures.h", "qatomic_arch.h", "qatomic_windowsce.h", "qt_windows.h", "qatomic_macosx.h" );
@ignore_for_qt_module_check = ( "$modules{QtCore}/arch", "$modules{QtCore}/global", "$modules{QtTest}", "$modules{QtDBus}" );
# Module dependencies.
# Every module that is required to build this module should have one entry.
# Each of the module version specifiers can take one of the following values:
# - A specific Git revision.
# - any git symbolic ref resolvable from the module's repository (e.g. "refs/heads/master" to track master branch)
#
%dependencies = (
);