mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2026-02-06 00:13:37 +08:00
fix: 在没有定义FINSH_USING_SYMTAB时编译报错以及IPC及finsh启用时自动选择必要的功能
Some checks failed
ToolsCI / Tools (push) Has been cancelled
AutoTestCI / components/cpp11 (push) Has been cancelled
AutoTestCI / kernel/atomic (push) Has been cancelled
AutoTestCI / kernel/atomic/riscv64 (push) Has been cancelled
AutoTestCI / kernel/atomic_c11 (push) Has been cancelled
AutoTestCI / kernel/atomic_c11/riscv64 (push) Has been cancelled
AutoTestCI / kernel/device (push) Has been cancelled
AutoTestCI / kernel/ipc (push) Has been cancelled
AutoTestCI / kernel/irq (push) Has been cancelled
AutoTestCI / kernel/mem (push) Has been cancelled
AutoTestCI / kernel/mem/riscv64 (push) Has been cancelled
AutoTestCI / kernel/thread (push) Has been cancelled
AutoTestCI / kernel/timer (push) Has been cancelled
AutoTestCI / rtsmart/aarch64 (push) Has been cancelled
AutoTestCI / rtsmart/arm (push) Has been cancelled
AutoTestCI / rtsmart/riscv64 (push) Has been cancelled
AutoTestCI / components/utest (push) Has been cancelled
RT-Thread BSP Static Build Check / 🔍 Summary of Git Diff Changes (push) Has been cancelled
doc_doxygen / doxygen_doc generate (push) Has been cancelled
pkgs_test / change (push) Has been cancelled
utest_auto_run / AARCH64-rtsmart :default.cfg (push) Has been cancelled
utest_auto_run / A9-rtsmart :default.cfg (push) Has been cancelled
utest_auto_run / RISCV-rtsmart :default.cfg (push) Has been cancelled
utest_auto_run / XUANTIE-rtsmart :default.cfg (push) Has been cancelled
utest_auto_run / AARCH64 :default.cfg (push) Has been cancelled
utest_auto_run / A9 :default.cfg (push) Has been cancelled
utest_auto_run / A9-smp :default.cfg (push) Has been cancelled
utest_auto_run / RISCV :default.cfg (push) Has been cancelled
RT-Thread BSP Static Build Check / ${{ matrix.legs.RTT_BSP }} (push) Has been cancelled
RT-Thread BSP Static Build Check / collect-artifacts (push) Has been cancelled
doc_doxygen / deploy (push) Has been cancelled
Some checks failed
ToolsCI / Tools (push) Has been cancelled
AutoTestCI / components/cpp11 (push) Has been cancelled
AutoTestCI / kernel/atomic (push) Has been cancelled
AutoTestCI / kernel/atomic/riscv64 (push) Has been cancelled
AutoTestCI / kernel/atomic_c11 (push) Has been cancelled
AutoTestCI / kernel/atomic_c11/riscv64 (push) Has been cancelled
AutoTestCI / kernel/device (push) Has been cancelled
AutoTestCI / kernel/ipc (push) Has been cancelled
AutoTestCI / kernel/irq (push) Has been cancelled
AutoTestCI / kernel/mem (push) Has been cancelled
AutoTestCI / kernel/mem/riscv64 (push) Has been cancelled
AutoTestCI / kernel/thread (push) Has been cancelled
AutoTestCI / kernel/timer (push) Has been cancelled
AutoTestCI / rtsmart/aarch64 (push) Has been cancelled
AutoTestCI / rtsmart/arm (push) Has been cancelled
AutoTestCI / rtsmart/riscv64 (push) Has been cancelled
AutoTestCI / components/utest (push) Has been cancelled
RT-Thread BSP Static Build Check / 🔍 Summary of Git Diff Changes (push) Has been cancelled
doc_doxygen / doxygen_doc generate (push) Has been cancelled
pkgs_test / change (push) Has been cancelled
utest_auto_run / AARCH64-rtsmart :default.cfg (push) Has been cancelled
utest_auto_run / A9-rtsmart :default.cfg (push) Has been cancelled
utest_auto_run / RISCV-rtsmart :default.cfg (push) Has been cancelled
utest_auto_run / XUANTIE-rtsmart :default.cfg (push) Has been cancelled
utest_auto_run / AARCH64 :default.cfg (push) Has been cancelled
utest_auto_run / A9 :default.cfg (push) Has been cancelled
utest_auto_run / A9-smp :default.cfg (push) Has been cancelled
utest_auto_run / RISCV :default.cfg (push) Has been cancelled
RT-Thread BSP Static Build Check / ${{ matrix.legs.RTT_BSP }} (push) Has been cancelled
RT-Thread BSP Static Build Check / collect-artifacts (push) Has been cancelled
doc_doxygen / deploy (push) Has been cancelled
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
menuconfig RT_USING_DEVICE_IPC
|
||||
bool "Using device drivers IPC"
|
||||
default y
|
||||
select RT_USING_MUTEX
|
||||
select RT_USING_SEMAPHORE
|
||||
|
||||
if RT_USING_DEVICE_IPC
|
||||
config RT_UNAMED_PIPE_NUMBER
|
||||
|
||||
@@ -2,6 +2,7 @@ menuconfig RT_USING_MSH
|
||||
bool "MSH: command shell"
|
||||
default n if RT_USING_NANO
|
||||
default y
|
||||
select RT_USING_SEMAPHORE
|
||||
|
||||
if RT_USING_MSH
|
||||
|
||||
|
||||
@@ -88,6 +88,8 @@ typedef long (*syscall_func)(void);
|
||||
};
|
||||
|
||||
#endif /* _MSC_VER */
|
||||
#else
|
||||
#define MSH_FUNCTION_EXPORT_CMD(name, cmd, desc, opt)
|
||||
#endif /* FINSH_USING_SYMTAB */
|
||||
|
||||
/**
|
||||
|
||||
@@ -37,17 +37,18 @@ static int msh_help(int argc, char **argv)
|
||||
rt_kprintf("RT-Thread shell commands:\n");
|
||||
{
|
||||
struct finsh_syscall *index;
|
||||
|
||||
#if defined(FINSH_USING_SYMTAB)
|
||||
for (index = _syscall_table_begin;
|
||||
index < _syscall_table_end;
|
||||
FINSH_NEXT_SYSCALL(index))
|
||||
{
|
||||
#if defined(FINSH_USING_DESCRIPTION) && defined(FINSH_USING_SYMTAB)
|
||||
#if defined(FINSH_USING_DESCRIPTION)
|
||||
rt_kprintf("%-16s - %s\n", index->name, index->desc);
|
||||
#else
|
||||
rt_kprintf("%s ", index->name);
|
||||
#endif
|
||||
#endif /* FINSH_USING_DESCRIPTION */
|
||||
}
|
||||
#endif /* FINSH_USING_SYMTAB */
|
||||
}
|
||||
rt_kprintf("\n");
|
||||
|
||||
@@ -231,7 +232,7 @@ static cmd_function_t msh_get_cmd(char *cmd, int size)
|
||||
{
|
||||
struct finsh_syscall *index;
|
||||
cmd_function_t cmd_func = RT_NULL;
|
||||
|
||||
#if defined(FINSH_USING_SYMTAB)
|
||||
for (index = _syscall_table_begin;
|
||||
index < _syscall_table_end;
|
||||
FINSH_NEXT_SYSCALL(index))
|
||||
@@ -243,7 +244,7 @@ static cmd_function_t msh_get_cmd(char *cmd, int size)
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* FINSH_USING_SYMTAB */
|
||||
return cmd_func;
|
||||
}
|
||||
|
||||
@@ -814,7 +815,7 @@ void msh_auto_complete(char *prefix)
|
||||
#endif /* RT_USING_MODULE */
|
||||
}
|
||||
#endif /* DFS_USING_POSIX */
|
||||
|
||||
#if defined(FINSH_USING_SYMTAB)
|
||||
/* checks in internal command */
|
||||
{
|
||||
for (index = _syscall_table_begin; index < _syscall_table_end; FINSH_NEXT_SYSCALL(index))
|
||||
@@ -839,7 +840,7 @@ void msh_auto_complete(char *prefix)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* FINSH_USING_SYMTAB */
|
||||
/* auto complete string */
|
||||
if (name_ptr != NULL)
|
||||
{
|
||||
@@ -866,7 +867,7 @@ static msh_cmd_opt_t *msh_get_cmd_opt(char *opt_str)
|
||||
{
|
||||
len = strlen(opt_str);
|
||||
}
|
||||
|
||||
#if defined(FINSH_USING_SYMTAB)
|
||||
for (index = _syscall_table_begin;
|
||||
index < _syscall_table_end;
|
||||
FINSH_NEXT_SYSCALL(index))
|
||||
@@ -877,7 +878,7 @@ static msh_cmd_opt_t *msh_get_cmd_opt(char *opt_str)
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* FINSH_USING_SYMTAB */
|
||||
return opt;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user