[Qbs] Dependencies on internal products using 'submodules'

Christian Gagneraud chgans at gmail.com
Sun Dec 3 08:27:34 CET 2017

Hi there,

I would like to know if it's possible to list internal product 
dependencies using the 'submodules' syntax, eg:

MyProduct {
	name: "foo"
	files: [
	Depends {
		name: "Qt"
		submodules: [
	Depends {
		name: "LibrarySubProject"
		submodules: [ // <=====

Where "LibrarySubProject" is an inline sub-project in the root project 
and lib1, lib2 are internal library products referenced by "SubProject".
This is different from my "third party" modules defined in 

I know I can use the Depends { name: "lib1" } form, but for "cosmetic" 
reasons, I would like to use the 'submodules' approach.

You might think that i'm a bit picky, but using this syntax, it makes 
the product.qbs easy to read, pleasant *and* easy to understand.
That could help me to convince people while show-casing qbs.

I could write one module per library in $qbsSearchPath/modules/ but that 
would be redundant and a bit awkward to maintain.


More information about the Qbs mailing list