Waf build for px4

Hi Lucas and Gustavo,
A couple of notes on the waf build for px4.

  • I think at the end of the build it needs to point the developer at the build directory so they know where to find the resulting *.px4 files
  • we need to also leave the *.elf files around (including the px4io one) so we can use gdb
  • I think the *.a files could go in a different directory so the bin/ directory is easier to find things in
  • is there a way to upload a particular build equivalent to “make px4-v2-upload” ?
  • it is good to run size on the elf in the build, so the developer can quickly see if the flash size has grown too much
    Cheers, Tridge
  • is there a way to upload a particular build equivalent to “make px4-v2-upload” ?

That would be what the --upload option does. We wanted a “command” rather than an option, but we couldn’t find a straightforward way to implement it. There was some discussion in the related PR.

  • I think at the end of the build it needs to point the developer at the build directory so they know where to find the resulting *.px4 files
  • it is good to run size on the elf in the build, so the developer can quickly see if the flash size has grown too much

I think these should be part of a summary we print in the end of the build.

  • we need to also leave the *.elf files around (including the px4io one) so we can use gdb
  • I think the *.a files could go in a different directory so the bin/ directory is easier to find things in

Agreed

Lucas De Marchi

Hi Lucas and Gustavo,
I’m having some difficulties getting the waf+cmake build to work with the px4 merge branch:


I think the main problem may be different compiler flags being passed in?
Do you have any time to lorok at this? I’d like to get this merge into master fairly soon.
Cheers, Tridge

We need to update our cmake configs (https://github.com/ArduPilot/ardupilot/tree/master/Tools/ardupilotwaf/px4/cmake/configs), I think @guludo is probably the right person for that job.

Hi!

I’ll try to look at it today.

Best,
Gustavo Sousa

@guludo, thanks!
Note that the merge is now in master. It is a rebase on upstream px4/Firmware, plus a bunch of patches on top.

Haha Just fixed the build today, more than 1 month later. Sorry :sweat_smile: