There is my qbs project:
Project {
StaticLibrary {
name: "targetLib"
files: "main.cpp"
bundle.isBundle: false
multiplexByQbsProperties: "architectures"
aggregate: true
Group {
fileTagsFilter: "bundle.content"
qbs.install: true
qbs.installSourceBase: buildDirectory
}
Depends { name: "nawesome" }
Depends { name: "cpp" }
}
}
On build I pass profile with set property cpp.architectures: ["arm64", "x86_64"].
As I understand multiplexing works in this way: one builds per every architecture and another one for aggregate to build universal binary. Aggregate set to its artifact tag "bundle.content" but it doesn't install.
I don't need non-universal binaries installed, so I need some way to eliminate them. Right now the only way I've found is:
Group {
condition: type.contains("bundle.content")
fileTagsFilter: "staticlibrary"
qbs.install: true
qbs.installSourceBase: buildDirectory
}
But I don't think this is good one.