[Qbs] qbs / QML issue

Jochen Becher jochen_becher at gmx.de
Fri Jul 25 09:50:06 CEST 2025


Am Donnerstag, dem 24.07.2025 um 14:15 +0200 schrieb Christian Kandeler via Qbs:
> On 7/22/25 10:17 PM, Jochen Becher via Qbs wrote:
> > With qbs 3.0.0 I get hundred of thousands (litterally!) warnings from qbs saying that some Qt types are defined twice:
> > 
> > Warning: qabstractitemmodel.h:258: Multiple C++ types called QAbstractItemModel found!
> >   (other occurrence in : qabstractitemmodel.h : 258 )
> >   This violates the One Definition Rule!
> > 
> > Here is the command that was called.
> 
> Can you provide a minimal project that exhibits this problem? Or link to 
> a real project where this happens? You are not setting 
> Qt.qml.extraMetaTypesFiles expicitly, are you?
> 

Yes, we do. This is an  excerpt of our own product item that extends from Product:

    // Workaround for QBS bug that causes Qt.Core metatypes info to be missing
    readonly property string _qtCoreMetatypesPath: Qt.core.installPrefixPath
                                                 + "/metatypes/qt" + Qt.core.versionMajor
                                                   + "core_relwithdebinfo_metatypes.json"
    Qt.qml.extraMetaTypesFiles: [ _qtCoreMetatypesPath ]

> 
> Christian
> 
> _______________________________________________
> Qbs mailing list
> Qbs at qt-project.org
> https://lists.qt-project.org/listinfo/qbs



More information about the Qbs mailing list