Junbo-Zheng commented on PR #3668: URL: https://github.com/apache/nuttx-apps/pull/3668#issuecomment-5087843298
> I also wonder about impact on firmware size, have you compared that @Junbo-Zheng ? Maybe we want this as an option if the function is not part of the firmware by default? I understand that `cp, rm, cat` can use relative paths but these can be disabled by default. If no impact then no problem :-) @cederom The `boot` nsh command is already optional — it is gated by `CONFIG_BOARDCTL_BOOT_IMAGE` (opt-in) together with `CONFIG_NSH_DISABLE_BOOT` (opt-out), see [nsh_syscmds.c#L404](https://github.com/apache/nuttx-apps/blob/master/nshlib/nsh_syscmds.c#L404). Platforms that don't need image boot simply leave CONFIG_BOARDCTL_BOOT_IMAGE unset, and `cmd_boot` (along with its nsh_getfullpath() call) is not compiled in at all. Local build with `Arm GNU Toolchain 13.2.rel1` ``` /home/mi/xiaomi/trunk [26-07-27_13:53:56] arm-none-eabi-gcc --version arm-none-eabi-gcc (Arm GNU Toolchain 13.2.rel1 (Build arm-13.7)) 13.2.1 20231009 Copyright (C) 2023 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ``` - before ``` /home/mi/xiaomi/trunk/out [26-07-27_12:16:26] arm-none-eabi-size nuttx text data bss dec hex filename 469784 15352 49257896 49743032 2f704b8 nuttx ``` - after - CONFIG_BOARDCTL_BOOT_IMAGE=y - CONFIG_NSH_DISABLE_BOOT not set ``` /home/mi/xiaomi/trunk/out [26-07-27_12:18:43] arm-none-eabi-size nuttx text data bss dec hex filename 469792 15352 49257896 49743040 2f704c0 nuttx ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
