[QBS] How to redirect Command output into file

Andrii Anpilogov anpilog at gmail.com
Fri Jul 17 13:43:26 CEST 2015


I could not find a way to generate symbol file with QBS and GCC.

This is where I stuck:

    Rule {

        id: sym

        inputs: ["application"]

        Artifact {

            fileTags: ["sym"]

            filePath: input.fileName.replace(".elf", ".sym")


        prepare: {

            var CmdPath = "arm-none-eabi-nm";

            var args = ["-n", input.filePath]; // <- Here is where
output needs to be redirected into output.fileName

            var cmd = new Command(CmdPath, args);

            cmd.description = "Generating Symbol file: " + input.fileName;

            cmd.highlight = "linker";

            return cmd;



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/qbs/attachments/20150717/beda631c/attachment.html>

More information about the Qbs mailing list