Skip to content

Compile error if GX_BINARY_RESOURCE_SUPPORT not defined #134

@int-bio

Description

@int-bio

Describe the bug
When GX_BINARY_RESOURCE_SUPPORT is not defined, there is a compile error with gx_binresfont_load.c and gx_binres_pixelmap_load.c that GX_BINRES_DATA_INFO is not defined.

Please also mention any information which could help others to understand
the problem you're facing:

  • ARM based target
  • Eclipse ThreadX 6.4
  • e2Studio 2025-01
  • The only way around it is to define either GX_BINARY_RESOURCE_SUPPORT or edit GUIX C files to not compile functions if support is not defined.

To Reproduce
Steps to reproduce the behavior:

  1. Upgrading from Renesas SSP 2.4.0 to 2.7.0 (ThreadX 6.2 -> 6.4)
  2. Compile stop due to error

Expected behavior
If you don’t define it correctly, gx_binres_*() APIs become no-ops and your application silently falls back to the old compiled-in resources (or shows nothing).

Impact
Unable to compile target

Logs and console output
Building file: ../synergy/ssp/src/framework/el/gx/gx_src/gx_binres_pixelmap_load.c
arm-none-eabi-gcc -mcpu=cortex-m4 -mthumb -mfloat-abi=hard -mfpu=fpv4-sp-d16 -O0 -fmessage-length=0 -fsigned-char -ffunction-sections -fdata-sections
-Wunused -Wuninitialized -Wall -Wmissing-declarations -Wpointer-arith -Wlogical-op -Waggregate-return -Wfloat-equal -g
-D_RENESAS_SYNERGY_ -DSQLITE_OS_OTHER=1 -DSQLITE_CORE -D_THREADX_KERNEL_ -D_USE_LONG_TIME_T -D_IMAGE_PROD -D_BYPASS_RSC_VERIFY
-I"C:/Projects/src"
-I"C:/Projects/intsrc/synergy_cfg/ssp_cfg/bsp"
-I"C:/Projects/intsrc/synergy_cfg/ssp_cfg/driver"
-I"C:/Projects/intsrc/synergy/ssp/inc"
-I"C:/Projects/intsrc/synergy/ssp/inc/bsp"
-I"C:/Projects/intsrc/synergy/ssp/inc/bsp/cmsis/Include"
-I"C:/Projects/intsrc/synergy/ssp/inc/driver/api"
-I"C:/Projects/intsrc/synergy/ssp/inc/driver/instances"
-I"C:/Projects/intsrc/synergy_cfg/ssp_cfg/framework/el"
-I"C:/Projects/intsrc/synergy/ssp/inc/framework/el"
-I"C:/Projects/intsrc/synergy/ssp/src/framework/el/tx"
-I"C:/Projects/intsrc/synergy_cfg/ssp_cfg/framework"
-I"C:/Projects/intsrc/synergy/ssp/inc/framework/api"
-I"C:/Projects/intsrc/synergy/ssp/inc/framework/instances"
-I"C:/Projects/intsrc/synergy/ssp/inc/framework/tes"
-I"C:/Projects/intsrc/synergy/ssp/src/framework/el/ux"
-I"C:/Projects/intsrc/synergy/ssp/src/framework/el/tx/tx_src"
-I"C:/Projects/intsrc/src/synergy_gen"
-std=gnu99 -Wmissing-prototypes -fstack-usage -fcallgraph-info -MMD -MP -MF"synergy/ssp/src/framework/el/gx/gx_src/gx_binres_pixelmap_load.d" -MT"synergy/ssp/src/framework/el/gx/gx_src/gx_binres_pixelmap_load.o" -c -o "synergy/ssp/src/framework/el/gx/gx_src/gx_binres_pixelmap_load.o" -x c "../synergy/ssp/src/framework/el/gx/gx_src/gx_binres_pixelmap_load.c"

Building file: ../synergy/ssp/src/framework/el/gx/gx_src/gx_binres_theme_load.c
../synergy/ssp/src/framework/el/gx/gx_src/gx_binres_font_load.c:81:6: warning: no previous prototype for '_gx_binres_font_load' [-Wmissing-prototypes]
81 | UINT _gx_binres_font_load(GX_UBYTE *root_address, UINT font_index, GX_UBYTE *buffer, ULONG *buffer_size)
| ^~~~~~~~~~~~~~~~~~~~
../synergy/ssp/src/framework/el/gx/gx_src/gx_binres_font_load.c: In function '_gx_binres_font_load':
../synergy/ssp/src/framework/el/gx/gx_src/gx_binres_font_load.c:84:1: error: unknown type name 'GX_BINRES_DATA_INFO'
84 | GX_BINRES_DATA_INFO info;
| ^~~~~~~~~~~~~~~~~~~
../synergy/ssp/src/framework/el/gx/gx_src/gx_binres_font_load.c:110:29: error: 'GX_BINRES_DATA_INFO' undeclared (first use in this function)
110 | memset(&info, 0, sizeof(GX_BINRES_DATA_INFO));

Additional context
This is a new feature in ThreadX 6.3. It was not available in 6.2 so I am not sure if someone ever tried to build without the option defined.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

Status

Backlog

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions