-
Notifications
You must be signed in to change notification settings - Fork 683
examples/fbcon: Fix endchoice and help in Kconfig #3032
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This PR fixes the `endchoice` and `help` in the Kconfig for fbcon - apache#3029 (comment) This patch will fix these build errors: ```text apps/examples/fbcon/Kconfig:62: syntax error apps/examples/fbcon/Kconfig:172: unknown option "---help--" ``` https://github.com/lupyuen/nuttx-riscv64/actions/runs/13981663903/job/39147989438#step:5:158 Signed-off-by: Lup Yuen Lee <luppy@appkaki.com>
Merged
cederom
approved these changes
Mar 21, 2025
Contributor
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @lupyuen :-) That fixes build problem introduced by #3029 at ./tools/configure.sh stage other builds now works again :-)
Regarding the fbcon setup some documentation is required and Kconfig dependencies update but this is out of the scope of this fix :-)
Before:
% ./tools/configure.sh -B esp32c3-devkit:lvgl
Copy files
Select CONFIG_HOST_BSD=y
Refreshing...
CP: arch/dummy/Kconfig to /XXX/nuttx.git/arch/dummy/dummy_kconfig
CP: boards/dummy/Kconfig to /XXX/nuttx.git/boards/dummy/dummy_kconfig
LN: platform/board to /XXX/nuttx-apps.git/platform/dummy
LN: include/arch to arch/risc-v/include
LN: include/arch/board to /XXX/nuttx.git/boards/risc-v/esp32c3-legacy/esp32c3-devkit/include
LN: drivers/platform to /XXX/nuttx.git/drivers/dummy
LN: include/arch/chip to /XXX/nuttx.git/arch/risc-v/include/esp32c3-legacy
LN: arch/risc-v/src/chip to /XXX/nuttx.git/arch/risc-v/src/esp32c3-legacy
LN: arch/risc-v/src/board to /XXX/nuttx.git/boards/risc-v/esp32c3-legacy/esp32c3-devkit/../common
LN: arch/risc-v/src/board/board to /XXX/nuttx.git/boards/risc-v/esp32c3-legacy/esp32c3-devkit/src
mkkconfig in /XXX/nuttx-apps.git/audioutils
mkkconfig in /XXX/nuttx-apps.git/benchmarks
mkkconfig in /XXX/nuttx-apps.git/boot
mkkconfig in /XXX/nuttx-apps.git/canutils
mkkconfig in /XXX/nuttx-apps.git/crypto
mkkconfig in /XXX/nuttx-apps.git/database
mkkconfig in /XXX/nuttx-apps.git/examples/mcuboot
mkkconfig in /XXX/nuttx-apps.git/examples/module
mkkconfig in /XXX/nuttx-apps.git/examples/rust
mkkconfig in /XXX/nuttx-apps.git/examples/sotest
mkkconfig in /XXX/nuttx-apps.git/examples
mkkconfig in /XXX/nuttx-apps.git/fsutils
mkkconfig in /XXX/nuttx-apps.git/games
mkkconfig in /XXX/nuttx-apps.git/graphics
mkkconfig in /XXX/nuttx-apps.git/industry
mkkconfig in /XXX/nuttx-apps.git/inertial
mkkconfig in /XXX/nuttx-apps.git/interpreters/luamodules
mkkconfig in /XXX/nuttx-apps.git/interpreters
mkkconfig in /XXX/nuttx-apps.git/logging
mkkconfig in /XXX/nuttx-apps.git/lte
mkkconfig in /XXX/nuttx-apps.git/math
mkkconfig in /XXX/nuttx-apps.git/mlearning
mkkconfig in /XXX/nuttx-apps.git/netutils
mkkconfig in /XXX/nuttx-apps.git/sdr
mkkconfig in /XXX/nuttx-apps.git/system
mkkconfig in /XXX/nuttx-apps.git/testing/arch
mkkconfig in /XXX/nuttx-apps.git/testing/cxx
mkkconfig in /XXX/nuttx-apps.git/testing/drivers
mkkconfig in /XXX/nuttx-apps.git/testing/fs
mkkconfig in /XXX/nuttx-apps.git/testing/libc
mkkconfig in /XXX/nuttx-apps.git/testing/mm
mkkconfig in /XXX/nuttx-apps.git/testing/sched
mkkconfig in /XXX/nuttx-apps.git/testing
mkkconfig in /XXX/nuttx-apps.git/videoutils
mkkconfig in /XXX/nuttx-apps.git/wireless/bluetooth
mkkconfig in /XXX/nuttx-apps.git/wireless/ieee802154
mkkconfig in /XXX/nuttx-apps.git/wireless
mkkconfig in /XXX/nuttx-apps.git
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:62: syntax error
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:51: missing end statement for this entry
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:23: missing end statement for this entry
/XXX/nuttx-apps.git/examples/Kconfig:8: missing end statement for this entry
Kconfig:2785: missing end statement for this entry
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:61: invalid statement
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:62: unexpected option "prompt"
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:63: unexpected option "depends"
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:64: invalid statement
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:65:warning: ignoring unsupported character ':'
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:65: unknown statement "Note"
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:95: unexpected end statement
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:96: unexpected end statement
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:173: syntax error
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:172: unknown option "---help--"
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:173: unknown option "Decode"
/XXX/nuttx-apps.git/examples/fbcon/Kconfig:205: unexpected end statement
/XXX/nuttx-apps.git/examples/Kconfig:211: unexpected end statement
Kconfig:2787: unexpected end statement
gmake: *** [tools/Unix.mk:726: olddefconfig] Error 1
ERROR: failed to refresh
After:
% ./tools/configure.sh -B esp32c3-devkit:lvgl
Copy files
Select CONFIG_HOST_BSD=y
Refreshing...
CP: arch/dummy/Kconfig to /XXX/nuttx.git/arch/dummy/dummy_kconfig
CP: boards/dummy/Kconfig to /XXX/nuttx.git/boards/dummy/dummy_kconfig
LN: platform/board to /XXX/nuttx-apps.git/platform/dummy
LN: include/arch to arch/risc-v/include
LN: include/arch/board to /XXX/nuttx.git/boards/risc-v/esp32c3-legacy/esp32c3-devkit/include
LN: drivers/platform to /XXX/nuttx.git/drivers/dummy
LN: include/arch/chip to /XXX/nuttx.git/arch/risc-v/include/esp32c3-legacy
LN: arch/risc-v/src/chip to /XXX/nuttx.git/arch/risc-v/src/esp32c3-legacy
LN: arch/risc-v/src/board to /XXX/nuttx.git/boards/risc-v/esp32c3-legacy/esp32c3-devkit/../common
LN: arch/risc-v/src/board/board to /XXX/nuttx.git/boards/risc-v/esp32c3-legacy/esp32c3-devkit/src
mkkconfig in /XXX/nuttx-apps.git/audioutils
mkkconfig in /XXX/nuttx-apps.git/benchmarks
mkkconfig in /XXX/nuttx-apps.git/boot
mkkconfig in /XXX/nuttx-apps.git/canutils
mkkconfig in /XXX/nuttx-apps.git/crypto
mkkconfig in /XXX/nuttx-apps.git/database
mkkconfig in /XXX/nuttx-apps.git/examples/mcuboot
mkkconfig in /XXX/nuttx-apps.git/examples/module
mkkconfig in /XXX/nuttx-apps.git/examples/rust
mkkconfig in /XXX/nuttx-apps.git/examples/sotest
mkkconfig in /XXX/nuttx-apps.git/examples
mkkconfig in /XXX/nuttx-apps.git/fsutils
mkkconfig in /XXX/nuttx-apps.git/games
mkkconfig in /XXX/nuttx-apps.git/graphics
mkkconfig in /XXX/nuttx-apps.git/industry
mkkconfig in /XXX/nuttx-apps.git/inertial
mkkconfig in /XXX/nuttx-apps.git/interpreters/luamodules
mkkconfig in /XXX/nuttx-apps.git/interpreters
mkkconfig in /XXX/nuttx-apps.git/logging
mkkconfig in /XXX/nuttx-apps.git/lte
mkkconfig in /XXX/nuttx-apps.git/math
mkkconfig in /XXX/nuttx-apps.git/mlearning
mkkconfig in /XXX/nuttx-apps.git/netutils
mkkconfig in /XXX/nuttx-apps.git/sdr
mkkconfig in /XXX/nuttx-apps.git/system
mkkconfig in /XXX/nuttx-apps.git/testing/arch
mkkconfig in /XXX/nuttx-apps.git/testing/cxx
mkkconfig in /XXX/nuttx-apps.git/testing/drivers
mkkconfig in /XXX/nuttx-apps.git/testing/fs
mkkconfig in /XXX/nuttx-apps.git/testing/libc
mkkconfig in /XXX/nuttx-apps.git/testing/mm
mkkconfig in /XXX/nuttx-apps.git/testing/sched
mkkconfig in /XXX/nuttx-apps.git/testing
mkkconfig in /XXX/nuttx-apps.git/videoutils
mkkconfig in /XXX/nuttx-apps.git/wireless/bluetooth
mkkconfig in /XXX/nuttx-apps.git/wireless/ieee802154
mkkconfig in /XXX/nuttx-apps.git/wireless
mkkconfig in /XXX/nuttx-apps.git
#
# configuration written to .config
#
% gmake -j8 CROSSDEV=riscv32-esp-elf-
Create version.h
LN: platform/board to /XXX/nuttx-apps.git/platform/dummy
Register: nsh
Register: sh
Register: lvgldemo
CC: /XXX/nuttx-apps.git/graphics/lvgl/lvgl/demos/benchmark/assets/lv_font_benchmark_montserrat_12_compr_az.cCC: /XXX/nuttx-apps.git/graphics/lvgl/lvgl/demos/benchmark/assets/lv_font_benchmark_montserrat_16_compr_az.cCC: /XXX/nuttx-apps.git/graphics/lvgl/lvgl/demos/benchmark/assets/lv_font_benchmark_montserrat_28_compr_az.cCC: /XXX/nuttx-apps.git/graphics/lvgl/lvgl/demos/multilang/assets/emojis/img_emoji_earth_globe_europe_africaCPP: /XXX/nuttx.git/boards/risc-v/esp32c3-legacy/esp32c3-devkit/../common/scripts/esp32c3_rom.ld-> /zraid/daCPP: /XXX/nuttx.git/boards/risc-v/esp32c3-legacy/esp32c3-devkit/../common/scripts/flat_memory.ld-> /zraid/daCPP: /XXX/nuttx.git/boards/risc-v/esp32c3-legacy/esp32c3-devkit/../common/scripts/legacy_sections.ld-> /zraiLD: nuttx
Memory region Used Size Region Size %age Used
iram0_0_seg: 6608 B 321296 B 2.06%
irom0_0_seg: 305258 B 4194272 B 7.28%
dram0_0_seg: 18080 B 321296 B 5.63%
drom0_0_seg: 508524 B 4194272 B 12.12%
rtc_seg: 0 GB 8 KB 0.00%
CP: nuttx.hex
MKIMAGE: ESP32-C3 binary
esptool.py -c esp32c3 elf2image -fs 4MB -fm dio -ff 40m -o nuttx.bin nuttx
esptool.py v4.8.1
Creating esp32c3 image...
Merged 1 ELF section
Successfully created esp32c3 image.
Generated: nuttx.bin (ESP32-C3 compatible)
### ADD FBCON EXAMPLE
% gmake menuconfig CROSSDEV=riscv32-esp-elf-
CP: arch/dummy/Kconfig to /XXX/nuttx.git/arch/dummy/dummy_kconfig
CP: boards/dummy/Kconfig to /XXX/nuttx.git/boards/dummy/dummy_kconfig
LN: platform/board to /XXX/nuttx-apps.git/platform/dummy
LN: include/arch to arch/risc-v/include
LN: include/arch/board to /XXX/nuttx.git/boards/risc-v/esp32c3-legacy/esp32c3-devkit/include
LN: drivers/platform to /XXX/nuttx.git/drivers/dummy
LN: include/arch/chip to /XXX/nuttx.git/arch/risc-v/include/esp32c3-legacy
LN: arch/risc-v/src/chip to /XXX/nuttx.git/arch/risc-v/src/esp32c3-legacy
LN: arch/risc-v/src/board to /XXX/nuttx.git/boards/risc-v/esp32c3-legacy/esp32c3-devkit/../common
LN: arch/risc-v/src/board/board to /XXX/nuttx.git/boards/risc-v/esp32c3-legacy/esp32c3-devkit/src
configuration written to .config
*** End of the configuration.
*** Execute 'make' to start the build or try 'make help'.
% kconfig-diff
EXAMPLES_FBCON n -> y
+EXAMPLES_FBCON_BPP_NX_DEFAULT y
+EXAMPLES_FBCON_CURSORCHAR 95
+EXAMPLES_FBCON_CUSTOM_BPP n
+EXAMPLES_FBCON_CUSTOM_FONTID n
+EXAMPLES_FBCON_DEFAULT_COLORS y
+EXAMPLES_FBCON_DEFAULT_FONT y
+EXAMPLES_FBCON_DEF_FB "/dev/fb0"
+EXAMPLES_FBCON_GLCACHE 94
+EXAMPLES_FBCON_LINESPACING 0
+EXAMPLES_FBCON_NOWRAP n
+EXAMPLES_FBCON_PIPE_STDERR y
+EXAMPLES_FBCON_PIPE_STDIN y
+EXAMPLES_FBCON_PIPE_STDOUT y
+EXAMPLES_FBCON_PRIORITY 100
+EXAMPLES_FBCON_SHOW_WELCOME y
+EXAMPLES_FBCON_SPAWN_TASK "nsh"
+EXAMPLES_FBCON_STACKSIZE 2048
+EXAMPLES_FBCON_VT100_DECODE y
% gmake -j8 CROSSDEV=riscv32-esp-elf-
Create version.h
LN: platform/board to /XXX/nuttx-apps.git/platform/dummy
Register: lvgldemo
Register: fbcon
Register: nsh
Register: sh
./fbcon_main.c:51:4: error: #error This application requires NX Graphics
# error This application requires NX Graphics
^~~~~
./fbcon_main.c:57:4: error: #error FIFO and Named Pipe Drivers should be enabled in the configuration
# error FIFO and Named Pipe Drivers should be enabled in the configuration
^~~~~
./fbcon_main.c:176:6: error: #error NXFONT_DEFAULT not defined
# error NXFONT_DEFAULT not defined
^~~~~
CC: dirent/lib_versionsort.c fbcon_main.c:51:4: error: #error This application requires NX Graphics
# error This application requires NX Graphics
^~~~~
fbcon_main.c:57:4: error: #error FIFO and Named Pipe Drivers should be enabled in the configuration
# error FIFO and Named Pipe Drivers should be enabled in the configuration
^~~~~
fbcon_main.c:176:6: error: #error NXFONT_DEFAULT not defined
# error NXFONT_DEFAULT not defined
^~~~~
CC: sched/sched_rrgetinterval.c fbcon_main.c: In function 'fbcon_renderglyph':
fbcon_main.c:1062:22: warning: passing argument 1 of 'nxf_convert_1bpp' from incompatible pointer type [-Wincompatible-pointer-types]
ret = RENDERER((FAR nxgl_mxpixel_t *)glyph->bitmap,
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from fbcon_main.c:41:
/XXX/nuttx.git/include/nuttx/nx/nxfonts.h:553:35: note: expected 'uint8_t *' {aka 'unsigned char *'} but argument is of type 'nxgl_mxpixel_t *' {aka 'long unsigned int *'}
int nxf_convert_1bpp(FAR uint8_t *dest, uint16_t height,
~~~~~~~~~^~~~
fbcon_main.c: In function 'fbcon_initialize':
fbcon_main.c:178:24: error: 'NXFONT_DEFAULT' undeclared (first use in this function); did you mean 'FONTID_DEFAULT'?
# define FBCON_FONTID NXFONT_DEFAULT
^~~~~~~~~~~~~~
xiaoxiang781216
approved these changes
Mar 21, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This PR fixes the
endchoiceandhelpin the Kconfig for fbconThis patch will fix these build errors:
https://github.com/lupyuen/nuttx-riscv64/actions/runs/13981663903/job/39147989438#step:5:158
Impact
This PR will fix the build errors for various NuttX Targets, e.g.
rv-virt:nshTesting
Tested with local build of
rv-virt:nshon macOS.