Hi all. Seems, this issue is similar to my question: http://lists.qt-project.org/pipermail/qbs/2015-February/001217.html
I too need to run the WiX product after building of all others products. But I can't get any suggestion how to do it.. :( In previous solution is offers to use the "uses" directive inside of Rule.. But, what if the "end" product (for example as WiX) has not any of "public" rules? I mean that it is impossible to add the "usings" directive (has not a place for it).. 2015-03-03 12:22 GMT+03:00 Christian Kandeler < [email protected]>: > On 03/02/2015 08:16 PM, Stephan Gatzka wrote: > > I've to build a bare metal project, consisting of two elf binaries and > > an FPGA image. > > > > Building both elf binaries worked like charm. But after building both > > elf binaries I have to combine both elf files and the pre-built FPGA > > image into a single image. This involves some fancy calls to objcopy > > and dd. > > > > Now I'm struggling with the task how to implement that in a qbs product. > > > > This is my current structure: > > Project { > > name: "productName" > > > > Application { > > name: "app1" > > ... > > } > > > > Application { > > name: "app2" > > ... > > } > > > > Product { > > name: "image" > > > > Depends { > > name:"app1" > > required:true > > "true" is the default. > > > } > > Depends { > > name:"app2" > > required:true > > } > > > > } > > } > > > > Inside the image product I tried to make the calls to objcopy and dd > > in the prepare script of a Rule or a Transformer. I think I haven't > > totally understood the behavior or intention of the usings and input > > directives. > > "usings" has a bad name and it will be called "inputsFromDependencies" > in qbs 1.4, which tells you what it means. > Your use case sounds rather straightforward to implement, but it's hard > to say what it should look like exactly without concrete knowledge about > your project. Anyway, here's a rough sketch: > Product { > name: "image" > type: ["custom-image"] > Rule { > usings: ["application"] // Provided you want to call objcopy on > the exeutables > Artifact { > filePath: ... // Whatever your output is > fileTags: ["custom-image"] > } > ... // Possibly more artifacts here > prepare: { > var cmds = []; > // Add your Process commands here. > // The application products are available as > inputs["application"][0] and inputs["application"][1] (but not in a > guaranteed order). > return cmds; > } > } > } > > Hope this helps a little. > > > Christian > _______________________________________________ > QBS mailing list > [email protected] > http://lists.qt-project.org/mailman/listinfo/qbs >
_______________________________________________ QBS mailing list [email protected] http://lists.qt-project.org/mailman/listinfo/qbs
