Hi,

I think there is some inconsistency regarding the treatment of
qbsSearchPath. Consider a Qbs project like this:


Project {

    name: "My Project"

    CppApplication {

        files: ["main.cpp"]

        Group {

            fileTagsFilter: product.type

            qbs.install: true

        }

    }

}


This works as expected. Now I like to add a bit more convenience, by
providing an item type "MyCppApplication" which has (in this case) the
install group predefined (but there are many other use cases I can think
of).

Project {    name: "My Project"    qbsSearchPaths: "qbs"
MyCppApplication {        files: ["main.cpp"]    }
}

Of course I added the "qbs" directory, an "imports" subdirectory, and a
file MyCppApplication.qbs within "imports":


import qbs 1.0


CppApplication {

    Group {

        fileTagsFilter: product.type

        qbs.install: true

    }

}


But this doesn't work. The message I'm getting is "Unexpected item type
'MyCppApplication'. If I move MyCppApplication part out to a separate .qbs
file and reference it (via "references"), everything works fine.

In my opinion, this behavior is inconsistent and it's really hard to
understand why the qbsSearchPath is applied only to the "next level of
indirection".

What do you think about this? Is it working as designed now? Or should it
be treated as a bug?

Regards,
Thomas
_______________________________________________
QBS mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/qbs

Reply via email to