From 83404b825bf2723fa1df54471e5232549c2d7ff0 Mon Sep 17 00:00:00 2001 From: Bernard Xiong Date: Sun, 22 Nov 2015 10:58:19 +0800 Subject: [PATCH] [libc] Does export time API if RTC component is not used. --- components/libc/armlibc/libc_syms.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/components/libc/armlibc/libc_syms.c b/components/libc/armlibc/libc_syms.c index 847c48544a..fc84aec77a 100644 --- a/components/libc/armlibc/libc_syms.c +++ b/components/libc/armlibc/libc_syms.c @@ -27,11 +27,13 @@ RTM_EXPORT(memchr); RTM_EXPORT(toupper); RTM_EXPORT(atoi); +#ifdef RT_USING_RTC RTM_EXPORT(localtime); RTM_EXPORT(time); +#endif /* import the full stdio for printf */ -#ifdef __MICROLIB +#if defined(RT_USING_MODULE) && defined(__MICROLIB) #error "[RT_USING_LIBC] Please use standard libc but not microlib." #endif