[SOLVED] How to chain multiple Post-Link commands

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [SOLVED] How to chain multiple Post-Link commands

    I would like to have more than one post link command, in SES. I can of course replace the one default to invoke my script say.
    But I wonder if you can do this in SES without custom script.

    So in project settings, User Build Steps, Post-Link Command I would like to replace with 2 in 1 as:
    "$(ToolChainDir)/arm-none-eabi-objcopy" -Oihex "$(RelTargetPath)" "$(PostLinkOutputFilePath)".hex ; "$(ToolChainDir)/arm-none-eabi-objcopy" -v -Obinary "$(RelTargetPath)" "$(PostLinkOutputFilePath)".bin



    But the chaining doesn't work, everything after first objcopy gets passed to it as arguments.

    Additionally, for above I modified Post-Link Output file, to remove extension so that I can add it to the commands above. That, screws up the "Output Files" folder, which appears after you have built project and it contains the outputs. Now, removing extension from Post-Link Output file screws it up - only single no-extension output appears, which you cannot access - because that folder doesn't represent what's on the actual filesystem, it seems contains the targets defined through the project config.

    Would be nice to have option to add multiple Post-link commands, and multiple output files.
  • Hello,

    Thank you for your feature request.
    Chaining User Build Steps commands is currently not supported nor is such a feature planned to be added.
    We can put it on the wish list but no promises that this will be added.

    Best regards,
    Nino
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Hello,

    That's a pity.

    Actually, it would be good if Segger adds not chaining, but executing arbitrary (and number of) Post/Pre build commands.

    Would be best of course if user can dynamically add (in the options list, by adding another raw in the configuration) such commands (or targets).
    If not dynamic, at least provide like 3 customizeable steps like that.

    E..g in that options list:
    -------------------| ------------------------------------------
    UsrPostBuild1 (or UsrPostBuild1Tgt) UsrPostBuild1Cmd

    So you can name the build name (or target) and specify build command. The output should also be automagically reflected in SES's output folder . ( Which currently seems reflects only hard-coded few outputs. )
  • Hello,

    We will discuss this internally and see how this might be added for future versions.

    Best regards,
    Nino
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.