mirror of
https://github.com/apache/nuttx-apps.git
synced 2026-08-01 20:29:00 +00:00
tools/mksymtab.sh: Add symbol table for modlib
Configs: +CONFIG_MODLIB_HAVE_SYMTAB=y CONFIG_MODLIB_SYMTAB_ARRAY="g_mod_symtab" CONFIG_MODLIB_NSYMBOLS_VAR="g_mod_nsymbols" Link error: LD: nuttx aarch64-none-elf-ld: /workspace/nuttx/staging/libc.a(modlib_symtab.o): in function `modlib_getsymtab': /workspace/nuttx/libs/libc/modlib/modlib_symtab.c:97:(.text.modlib_getsymtab+0xa0): undefined reference to `g_mod_symtab' aarch64-none-elf-ld: /workspace/nuttx/libs/libc/modlib/modlib_symtab.c:97:(.text.modlib_getsymtab+0xa4): undefined reference to `g_mod_symtab' aarch64-none-elf-ld: /workspace/nuttx/libs/libc/modlib/modlib_symtab.c:98:(.text.modlib_getsymtab+0xa8): undefined reference to `g_mod_nsymbols' aarch64-none-elf-ld: /workspace/nuttx/libs/libc/modlib/modlib_symtab.c:98:(.text.modlib_getsymtab+0xac): undefined reference to `g_mod_nsymbols' Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
This commit is contained in:
parent
30df081276
commit
98427f67f1
1 changed files with 4 additions and 0 deletions
|
|
@ -114,6 +114,8 @@ if [ -z "$prefix" ]; then
|
|||
echo "const struct symtab_s CONFIG_EXECFUNCS_SYMTAB_ARRAY[] = "
|
||||
echo "#elif defined(CONFIG_NSH_SYMTAB)"
|
||||
echo "const struct symtab_s CONFIG_NSH_SYMTAB_ARRAYNAME[] = "
|
||||
echo "#elif defined(CONFIG_MODLIB_HAVE_SYMTAB)"
|
||||
echo "const struct symtab_s CONFIG_MODLIB_SYMTAB_ARRAY[] = "
|
||||
echo "#else"
|
||||
echo "const struct symtab_s dummy_symtab[] = "
|
||||
echo "#endif"
|
||||
|
|
@ -134,6 +136,8 @@ if [ -z "$prefix" ]; then
|
|||
echo "const int CONFIG_EXECFUNCS_NSYMBOLS_VAR = sizeof(CONFIG_EXECFUNCS_SYMTAB_ARRAY) / sizeof(struct symtab_s);"
|
||||
echo "#elif defined(CONFIG_NSH_SYMTAB)"
|
||||
echo "const int CONFIG_NSH_SYMTAB_COUNTNAME = sizeof(CONFIG_NSH_SYMTAB_ARRAYNAME) / sizeof(struct symtab_s);"
|
||||
echo "#elif defined(CONFIG_MODLIB_HAVE_SYMTAB)"
|
||||
echo "const int CONFIG_MODLIB_NSYMBOLS_VAR = sizeof(CONFIG_MODLIB_SYMTAB_ARRAY) / sizeof(struct symtab_s);"
|
||||
echo "#else"
|
||||
echo "const int dummy_nsymtabs = sizeof(dummy_symtab) / sizeof(struct symtab_s);"
|
||||
echo "#endif"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue