From b513d37cf2fc33c2dd20021316533feaac0bef23 Mon Sep 17 00:00:00 2001 From: Meco Man <920369182@qq.com> Date: Sun, 17 Oct 2021 17:19:12 -0400 Subject: [PATCH] [libc][posix] create 'posix' folder and move related files into it --- components/libc/posix/SConscript | 15 +++++++++++++++ components/libc/{ => posix}/aio/SConscript | 0 components/libc/{ => posix}/aio/posix_aio.c | 0 components/libc/{ => posix}/aio/posix_aio.h | 0 components/libc/{ => posix}/mmap/SConscript | 0 components/libc/{ => posix}/mmap/posix_mmap.c | 0 components/libc/{ => posix}/pthreads/SConscript | 0 components/libc/{ => posix}/pthreads/mqueue.c | 0 components/libc/{ => posix}/pthreads/mqueue.h | 0 .../libc/{ => posix}/pthreads/posix_types.h | 0 components/libc/{ => posix}/pthreads/pthread.c | 0 components/libc/{ => posix}/pthreads/pthread.h | 0 .../libc/{ => posix}/pthreads/pthread_attr.c | 0 .../libc/{ => posix}/pthreads/pthread_barrier.c | 0 .../libc/{ => posix}/pthreads/pthread_cond.c | 0 .../libc/{ => posix}/pthreads/pthread_internal.h | 0 .../libc/{ => posix}/pthreads/pthread_mutex.c | 0 .../libc/{ => posix}/pthreads/pthread_rwlock.c | 0 .../libc/{ => posix}/pthreads/pthread_spin.c | 0 .../libc/{ => posix}/pthreads/pthread_tls.c | 0 components/libc/{ => posix}/pthreads/sched.c | 0 components/libc/{ => posix}/pthreads/sched.h | 0 components/libc/{ => posix}/pthreads/semaphore.c | 0 components/libc/{ => posix}/pthreads/semaphore.h | 0 components/libc/{ => posix}/signal/SConscript | 0 components/libc/{ => posix}/signal/posix_signal.c | 0 components/libc/{ => posix}/signal/posix_signal.h | 0 components/libc/{ => posix}/termios/SConscript | 0 .../libc/{ => posix}/termios/posix_termios.c | 0 .../libc/{ => posix}/termios/posix_termios.h | 0 30 files changed, 15 insertions(+) create mode 100644 components/libc/posix/SConscript rename components/libc/{ => posix}/aio/SConscript (100%) rename components/libc/{ => posix}/aio/posix_aio.c (100%) rename components/libc/{ => posix}/aio/posix_aio.h (100%) rename components/libc/{ => posix}/mmap/SConscript (100%) rename components/libc/{ => posix}/mmap/posix_mmap.c (100%) rename components/libc/{ => posix}/pthreads/SConscript (100%) rename components/libc/{ => posix}/pthreads/mqueue.c (100%) rename components/libc/{ => posix}/pthreads/mqueue.h (100%) rename components/libc/{ => posix}/pthreads/posix_types.h (100%) rename components/libc/{ => posix}/pthreads/pthread.c (100%) rename components/libc/{ => posix}/pthreads/pthread.h (100%) rename components/libc/{ => posix}/pthreads/pthread_attr.c (100%) rename components/libc/{ => posix}/pthreads/pthread_barrier.c (100%) rename components/libc/{ => posix}/pthreads/pthread_cond.c (100%) rename components/libc/{ => posix}/pthreads/pthread_internal.h (100%) rename components/libc/{ => posix}/pthreads/pthread_mutex.c (100%) rename components/libc/{ => posix}/pthreads/pthread_rwlock.c (100%) rename components/libc/{ => posix}/pthreads/pthread_spin.c (100%) rename components/libc/{ => posix}/pthreads/pthread_tls.c (100%) rename components/libc/{ => posix}/pthreads/sched.c (100%) rename components/libc/{ => posix}/pthreads/sched.h (100%) rename components/libc/{ => posix}/pthreads/semaphore.c (100%) rename components/libc/{ => posix}/pthreads/semaphore.h (100%) rename components/libc/{ => posix}/signal/SConscript (100%) rename components/libc/{ => posix}/signal/posix_signal.c (100%) rename components/libc/{ => posix}/signal/posix_signal.h (100%) rename components/libc/{ => posix}/termios/SConscript (100%) rename components/libc/{ => posix}/termios/posix_termios.c (100%) rename components/libc/{ => posix}/termios/posix_termios.h (100%) diff --git a/components/libc/posix/SConscript b/components/libc/posix/SConscript new file mode 100644 index 0000000000..4c815c49b8 --- /dev/null +++ b/components/libc/posix/SConscript @@ -0,0 +1,15 @@ +# RT-Thread building script for bridge + +import os +from building import * + +cwd = GetCurrentDir() +objs = [] +list = os.listdir(cwd) + +for d in list: + path = os.path.join(cwd, d) + if os.path.isfile(os.path.join(path, 'SConscript')): + objs = objs + SConscript(os.path.join(d, 'SConscript')) + +Return('objs') diff --git a/components/libc/aio/SConscript b/components/libc/posix/aio/SConscript similarity index 100% rename from components/libc/aio/SConscript rename to components/libc/posix/aio/SConscript diff --git a/components/libc/aio/posix_aio.c b/components/libc/posix/aio/posix_aio.c similarity index 100% rename from components/libc/aio/posix_aio.c rename to components/libc/posix/aio/posix_aio.c diff --git a/components/libc/aio/posix_aio.h b/components/libc/posix/aio/posix_aio.h similarity index 100% rename from components/libc/aio/posix_aio.h rename to components/libc/posix/aio/posix_aio.h diff --git a/components/libc/mmap/SConscript b/components/libc/posix/mmap/SConscript similarity index 100% rename from components/libc/mmap/SConscript rename to components/libc/posix/mmap/SConscript diff --git a/components/libc/mmap/posix_mmap.c b/components/libc/posix/mmap/posix_mmap.c similarity index 100% rename from components/libc/mmap/posix_mmap.c rename to components/libc/posix/mmap/posix_mmap.c diff --git a/components/libc/pthreads/SConscript b/components/libc/posix/pthreads/SConscript similarity index 100% rename from components/libc/pthreads/SConscript rename to components/libc/posix/pthreads/SConscript diff --git a/components/libc/pthreads/mqueue.c b/components/libc/posix/pthreads/mqueue.c similarity index 100% rename from components/libc/pthreads/mqueue.c rename to components/libc/posix/pthreads/mqueue.c diff --git a/components/libc/pthreads/mqueue.h b/components/libc/posix/pthreads/mqueue.h similarity index 100% rename from components/libc/pthreads/mqueue.h rename to components/libc/posix/pthreads/mqueue.h diff --git a/components/libc/pthreads/posix_types.h b/components/libc/posix/pthreads/posix_types.h similarity index 100% rename from components/libc/pthreads/posix_types.h rename to components/libc/posix/pthreads/posix_types.h diff --git a/components/libc/pthreads/pthread.c b/components/libc/posix/pthreads/pthread.c similarity index 100% rename from components/libc/pthreads/pthread.c rename to components/libc/posix/pthreads/pthread.c diff --git a/components/libc/pthreads/pthread.h b/components/libc/posix/pthreads/pthread.h similarity index 100% rename from components/libc/pthreads/pthread.h rename to components/libc/posix/pthreads/pthread.h diff --git a/components/libc/pthreads/pthread_attr.c b/components/libc/posix/pthreads/pthread_attr.c similarity index 100% rename from components/libc/pthreads/pthread_attr.c rename to components/libc/posix/pthreads/pthread_attr.c diff --git a/components/libc/pthreads/pthread_barrier.c b/components/libc/posix/pthreads/pthread_barrier.c similarity index 100% rename from components/libc/pthreads/pthread_barrier.c rename to components/libc/posix/pthreads/pthread_barrier.c diff --git a/components/libc/pthreads/pthread_cond.c b/components/libc/posix/pthreads/pthread_cond.c similarity index 100% rename from components/libc/pthreads/pthread_cond.c rename to components/libc/posix/pthreads/pthread_cond.c diff --git a/components/libc/pthreads/pthread_internal.h b/components/libc/posix/pthreads/pthread_internal.h similarity index 100% rename from components/libc/pthreads/pthread_internal.h rename to components/libc/posix/pthreads/pthread_internal.h diff --git a/components/libc/pthreads/pthread_mutex.c b/components/libc/posix/pthreads/pthread_mutex.c similarity index 100% rename from components/libc/pthreads/pthread_mutex.c rename to components/libc/posix/pthreads/pthread_mutex.c diff --git a/components/libc/pthreads/pthread_rwlock.c b/components/libc/posix/pthreads/pthread_rwlock.c similarity index 100% rename from components/libc/pthreads/pthread_rwlock.c rename to components/libc/posix/pthreads/pthread_rwlock.c diff --git a/components/libc/pthreads/pthread_spin.c b/components/libc/posix/pthreads/pthread_spin.c similarity index 100% rename from components/libc/pthreads/pthread_spin.c rename to components/libc/posix/pthreads/pthread_spin.c diff --git a/components/libc/pthreads/pthread_tls.c b/components/libc/posix/pthreads/pthread_tls.c similarity index 100% rename from components/libc/pthreads/pthread_tls.c rename to components/libc/posix/pthreads/pthread_tls.c diff --git a/components/libc/pthreads/sched.c b/components/libc/posix/pthreads/sched.c similarity index 100% rename from components/libc/pthreads/sched.c rename to components/libc/posix/pthreads/sched.c diff --git a/components/libc/pthreads/sched.h b/components/libc/posix/pthreads/sched.h similarity index 100% rename from components/libc/pthreads/sched.h rename to components/libc/posix/pthreads/sched.h diff --git a/components/libc/pthreads/semaphore.c b/components/libc/posix/pthreads/semaphore.c similarity index 100% rename from components/libc/pthreads/semaphore.c rename to components/libc/posix/pthreads/semaphore.c diff --git a/components/libc/pthreads/semaphore.h b/components/libc/posix/pthreads/semaphore.h similarity index 100% rename from components/libc/pthreads/semaphore.h rename to components/libc/posix/pthreads/semaphore.h diff --git a/components/libc/signal/SConscript b/components/libc/posix/signal/SConscript similarity index 100% rename from components/libc/signal/SConscript rename to components/libc/posix/signal/SConscript diff --git a/components/libc/signal/posix_signal.c b/components/libc/posix/signal/posix_signal.c similarity index 100% rename from components/libc/signal/posix_signal.c rename to components/libc/posix/signal/posix_signal.c diff --git a/components/libc/signal/posix_signal.h b/components/libc/posix/signal/posix_signal.h similarity index 100% rename from components/libc/signal/posix_signal.h rename to components/libc/posix/signal/posix_signal.h diff --git a/components/libc/termios/SConscript b/components/libc/posix/termios/SConscript similarity index 100% rename from components/libc/termios/SConscript rename to components/libc/posix/termios/SConscript diff --git a/components/libc/termios/posix_termios.c b/components/libc/posix/termios/posix_termios.c similarity index 100% rename from components/libc/termios/posix_termios.c rename to components/libc/posix/termios/posix_termios.c diff --git a/components/libc/termios/posix_termios.h b/components/libc/posix/termios/posix_termios.h similarity index 100% rename from components/libc/termios/posix_termios.h rename to components/libc/posix/termios/posix_termios.h