diff --git a/components/libc/Kconfig b/components/libc/Kconfig index eac0fa1d595322e5a7c136caa3bd2a54d4e783dc..86e42b53a1ae09f6556788be7be08a6e9d725029 100644 --- a/components/libc/Kconfig +++ b/components/libc/Kconfig @@ -52,6 +52,10 @@ if RT_USING_LIBC && RT_USING_DFS config RT_USING_POSIX_AIO bool "Enable AIO" default n + + config RT_USING_POSIX_CLOCKTIME + bool "Enable POSIX clock_time APIs" + default n endif endif diff --git a/components/libc/time/SConscript b/components/libc/time/SConscript index a3b74c615834bc5d6f0263555cbdc7c4d55ce605..7548076ab249ef69d26ccc8352c8509d56b373f3 100644 --- a/components/libc/time/SConscript +++ b/components/libc/time/SConscript @@ -6,10 +6,7 @@ cwd = GetCurrentDir() src = Glob('*.c') + Glob('*.cpp') CPPPATH = [cwd] -#group = DefineGroup('pthreads', src, -# depend = ['RT_USING_PTHREADS'], CPPPATH = CPPPATH) - group = DefineGroup('pthreads', src, - depend = [''], CPPPATH = CPPPATH) + depend = ['RT_USING_POSIX_CLOCKTIME'], CPPPATH = CPPPATH) Return('group') diff --git a/components/lwp/Kconfig b/components/lwp/Kconfig index 1532a2202eb048e798454cd335a8a06de6bf7a7f..47713245c952f01fbcf7e71410cd32e185a8ec8f 100644 --- a/components/lwp/Kconfig +++ b/components/lwp/Kconfig @@ -2,6 +2,7 @@ config RT_USING_LWP bool "Using light-weight process" select RT_USING_DFS select RT_USING_LIBC + select RT_USING_POSIX_CLOCKTIME depends on ARCH_ARM_CORTEX_M || ARCH_ARM_ARM9 || ARCH_ARM_CORTEX_A default n help