summaryrefslogtreecommitdiff
path: root/src/components.c
diff options
context:
space:
mode:
authoryangjie <[email protected]>2019-09-11 12:01:24 +0800
committeryangjie <[email protected]>2019-09-11 12:01:24 +0800
commite7cb38c9c30c288a9d26038712420254783be575 (patch)
tree0ca71724cb54fd79d7891d9e0ddf97fd67aff7dc /src/components.c
parent2ed84b61b057482d8554a9b181ddb398b5d4ff96 (diff)
[src]解除组件初始化与使用user main的依赖
Diffstat (limited to 'src/components.c')
-rw-r--r--src/components.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/components.c b/src/components.c
index b9fc4c178c..df3e0f0fb3 100644
--- a/src/components.c
+++ b/src/components.c
@@ -126,6 +126,7 @@ void rt_components_init(void)
}
#endif
}
+#endif /* RT_USING_COMPONENTS_INIT */
#ifdef RT_USING_USER_MAIN
@@ -173,10 +174,11 @@ void main_thread_entry(void *parameter)
{
extern int main(void);
extern int $Super$$main(void);
-
+
+#ifdef RT_USING_COMPONENTS_INIT
/* RT-Thread components initialization */
rt_components_init();
-
+#endif
#ifdef RT_USING_SMP
rt_hw_secondary_cpu_up();
#endif
@@ -254,4 +256,3 @@ int rtthread_startup(void)
return 0;
}
#endif
-#endif