AP_DDS: Support custom build server enabling DDS
The custom build server has the ability to build custom firmware. Since users may want to add DDS support to their firmware, without compiling on their own computers, it is ideally added as an option to the custom firmware builder.
See the ArduPilot Dev Call 2023-03-20 notes for more info: https://docs.google.com/document/d/1DPtwTY-D-KeboL2WmKkYTOYxiZDSPSYEFVfH-kpkue0/edit#heading=h.kdoemjxcl7ua
Hi, I read the source code of custom server. I wanted to confirm that just need to add just the appropriate entry in BUILD_OPTIONS, or are there changes need to be made under ardupilotwaf as well.
Thanks
Hi, I read the source code of custom server. I wanted to confirm that just need to add just the appropriate entry in
BUILD_OPTIONS, or are there changes need to be made underardupilotwafas well. Thanks
Yep, please give that a try and see what happens.
@Ryanf55 I ran the custom build server locally with modified BUILD_OPTIONS, encountering a redefined error for AP_DDS_ENABLED. The back-end commands with verbose showed that waf is configured with -DAP_DDS_ENABLED=0 by default, unlike other libraries in the custom build server, causing a compiler warning. I attempted to locate where this flag is initialized but couldn't find it. Could you kindly give me some direction? Thanks
AP_DDS_ENABLED
Yep! Right here: https://github.com/ArduPilot/ardupilot/blob/8c72304ab912b42d38bd3301fd964aaec7149e77/Tools/ardupilotwaf/boards.py#L85
By default, running ./waf configure --board sitl does NOT include --enable-dds, so the above if cfg.options.enable_dds evaluates to False, and DDS is not included.
The compiler is unable to recognize any definition of AP_DDS_ENABLED, even though it's clearly defined in hwdef.h generated by the custom build sever. Edit: Fixed by adding the missing includes similar to #26342
The compiler is unable to recognize any definition of AP_DDS_ENABLED, even though it's clearly defined in hwdef.h generated by the custom build sever. Edit: Fixed by adding the missing includes similar to #26342
Can you contribute the fixes for those?
Can you contribute the fixes for those?
Hi, I am really sorry for the delay. I will be sure to put up a pull request with requested changes for this ticket by next week. The issues I mentioned earlier were fixed after I raised them on discord (#26405 #26342). I will be sure to make PRs if I face any similar hiccups.
I have made a release here: https://github.com/ArduPilot/Micro-XRCE-DDS-Gen/releases/tag/v4.5.0
We should be able to use this binary in the setup scripts and thus no changes will be needed to the build server.