The Qt 5 file hierarchy upon installation should be:

bin/            - executables run by the user
                - unversioned applications, like assistant, linguist, qdbus,
                  qdbusviewer
                - versioned applications, like qmake[35], qdoc5, qmlviewer5,
                 maybe moc5, uic5, rcc5
doc/            - gone to share/qt5/doc
examples/ - gone to share/qt5/examples
include/        - versioned include dirs:
        QtCore5 or QtCore-5 or QtCore.5 or Qt5Core/
        [...]
        Qt/     - gone, forever, no replacement
imports/        - horribly flawed design, see below
lib/            - arch-specific files (also lib<qual> or lib/<arch>/)
        ./               - versioned libraries (.a, .so, .la, .prl)
        pkgconfig/ - versioned .pc files
        qt5/             - arch-specific support files:
                bin/ or libexec/
                 - executables not run by the user, like syncqt, lrelease, 
lupdate
                imports/
                 - QtDeclarative imports
                qml2/
                 - QML2 (including QtQuick2) arch-specific imports
                mkspecs/ ?
share/  - arch-independent files
        qml2/    - QML2 (including QtQuick2) arch-independent imports
        qt5/
                doc/
                examples/
                mkspecs/        ?

Note on imports: the design is flawed. It was flawed in Qt 4 and it's worse now
on Qt 5. For Qt 4, the flaw was that it did not differentiate QML imports that
were arch-independent from the ones that required plugins. With Qt 5, it
becomes worse because Qt Quick 1 and 2 share the same directory.

Instead, I recommend we immediately change QML2 to the system that Perl uses:
put the arch-specific files inside the lib hierarchy, for which distributions
have already solved the multiarch problem, but put arch-independent files in
the share hierarchy.

In addition, the loader should be clever to merge similar names from the two
different paths. That is, imagine a .qml file in share/qml2 that requires a
plugin: if the loader is a 32-bit application, it would search for the plugin
in lib/qt5/qml2, but if it's a 64-bit application it would search in
lib64/qt5/qml2.

Additionally, if we're still using QML2 by the Qt 6 release, the plugins could
be made available in lib/qt6/qml2.

As for mkspecs, I believe they should be in share, since they are technically-
speaking arch-independent.

--
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center
     Intel Sweden AB - Registration Number: 556189-6027
     Knarrarnäsgatan 15, 164 40 Kista, Stockholm, Sweden

Attachment: signature.asc
Description: This is a digitally signed message part.

_______________________________________________
Development mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/development

Reply via email to