From 322f9f401ce02473c627075f83314abd75ab7bac Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Tue, 7 Oct 2014 07:42:36 -0600 Subject: [PATCH] Simplify how C source files are selected in the build --- sched/clock/Make.defs | 6 +++--- sched/environ/Make.defs | 6 +++--- sched/environ/environ.h | 2 +- sched/errno/Make.defs | 4 ++-- sched/group/Make.defs | 18 +++++++++--------- sched/init/Make.defs | 2 +- sched/irq/Make.defs | 2 +- sched/mqueue/Make.defs | 10 +++++----- sched/paging/Make.defs | 2 +- sched/pthread/Make.defs | 24 ++++++++++++------------ sched/sched/Make.defs | 30 +++++++++++++++--------------- sched/semaphore/Make.defs | 8 ++++---- sched/signal/Make.defs | 16 ++++++++-------- sched/task/Make.defs | 22 +++++++++++----------- sched/timer/Make.defs | 6 +++--- sched/wdog/Make.defs | 4 ++-- 16 files changed, 81 insertions(+), 81 deletions(-) diff --git a/sched/clock/Make.defs b/sched/clock/Make.defs index 6e1bbcb9b0..19ab8bae07 100644 --- a/sched/clock/Make.defs +++ b/sched/clock/Make.defs @@ -33,9 +33,9 @@ # ############################################################################ -CLOCK_SRCS = clock_initialize.c clock_settime.c clock_gettime.c clock_getres.c -CLOCK_SRCS += clock_time2ticks.c clock_abstime2ticks.c clock_ticks2time.c -CLOCK_SRCS += clock_gettimeofday.c clock_systimer.c clock_systimespec.c +CSRCS += clock_initialize.c clock_settime.c clock_gettime.c clock_getres.c +CSRCS += clock_time2ticks.c clock_abstime2ticks.c clock_ticks2time.c +CSRCS += clock_gettimeofday.c clock_systimer.c clock_systimespec.c # Include clock build support diff --git a/sched/environ/Make.defs b/sched/environ/Make.defs index 362fd685d8..2ecb98abca 100644 --- a/sched/environ/Make.defs +++ b/sched/environ/Make.defs @@ -35,9 +35,9 @@ ifneq ($(CONFIG_DISABLE_ENVIRON),y) -ENV_SRCS = env_getenvironptr.c env_dup.c env_release.c env_findvar.c -ENV_SRCS += env_removevar.c env_clearenv.c env_getenv.c env_putenv.c -ENV_SRCS += env_setenv.c env_unsetenv.c +CSRCS += env_getenvironptr.c env_dup.c env_release.c env_findvar.c +CSRCS += env_removevar.c env_clearenv.c env_getenv.c env_putenv.c +CSRCS += env_setenv.c env_unsetenv.c # Include environ build support diff --git a/sched/environ/environ.h b/sched/environ/environ.h index 63cea1e925..98fc98728a 100644 --- a/sched/environ/environ.h +++ b/sched/environ/environ.h @@ -44,7 +44,7 @@ #include /**************************************************************************** - * Definitions + * Pre-processor Definitions ****************************************************************************/ #ifdef CONFIG_DISABLE_ENVIRON diff --git a/sched/errno/Make.defs b/sched/errno/Make.defs index b96d49bee1..d233b1147b 100644 --- a/sched/errno/Make.defs +++ b/sched/errno/Make.defs @@ -33,10 +33,10 @@ # ############################################################################ -ERRNO_SRCS = errno_getptr.c +CSRCS += errno_getptr.c ifeq ($(CONFIG_LIB_SYSCALL),y) -ERRNO_SRCS += errno_get.c errno_set.c +CSRCS += errno_get.c errno_set.c endif # Include errno build support diff --git a/sched/group/Make.defs b/sched/group/Make.defs index f9c08f5e13..e3b4cba93b 100644 --- a/sched/group/Make.defs +++ b/sched/group/Make.defs @@ -33,30 +33,30 @@ # ############################################################################ -GRP_SRCS = group_create.c group_join.c group_leave.c group_find.c -GRP_SRCS += group_setupstreams.c group_setupidlefiles.c group_setuptaskfiles.c -GRP_SRCS += group_foreachchild.c group_killchildren.c +CSRCS += group_create.c group_join.c group_leave.c group_find.c +CSRCS += group_setupstreams.c group_setupidlefiles.c group_setuptaskfiles.c +CSRCS += group_foreachchild.c group_killchildren.c ifeq ($(CONFIG_SCHED_HAVE_PARENT),y) -GRP_SRCS += task_reparent.c +CSRCS += task_reparent.c ifeq ($(CONFIG_SCHED_CHILD_STATUS),y) -GRP_SRCS += group_childstatus.c +CSRCS += group_childstatus.c endif endif ifeq ($(CONFIG_ARCH_ADDRENV),y) -GRP_SRCS += group_addrenv.c +CSRCS += group_addrenv.c endif ifneq ($(CONFIG_DISABLE_SIGNALS),y) -GRP_SRCS += group_signal.c +CSRCS += group_signal.c endif ifeq ($(CONFIG_BUILD_PROTECTED),y) -GRP_SRCS += group_malloc.c group_zalloc.c group_free.c +CSRCS += group_malloc.c group_zalloc.c group_free.c else ifeq ($(CONFIG_BUILD_KERNEL),y) -GRP_SRCS += group_malloc.c group_zalloc.c group_free.c +CSRCS += group_malloc.c group_zalloc.c group_free.c endif endif diff --git a/sched/init/Make.defs b/sched/init/Make.defs index d48d736170..eae5e2fa87 100644 --- a/sched/init/Make.defs +++ b/sched/init/Make.defs @@ -33,7 +33,7 @@ # ############################################################################ -INIT_SRCS = os_start.c os_bringup.c +CSRCS += os_start.c os_bringup.c # Include init build support diff --git a/sched/irq/Make.defs b/sched/irq/Make.defs index 717e336689..706569f66b 100644 --- a/sched/irq/Make.defs +++ b/sched/irq/Make.defs @@ -33,7 +33,7 @@ # ############################################################################ -IRQ_SRCS = irq_initialize.c irq_attach.c irq_dispatch.c irq_unexpectedisr.c +CSRCS += irq_initialize.c irq_attach.c irq_dispatch.c irq_unexpectedisr.c # Include irq build support diff --git a/sched/mqueue/Make.defs b/sched/mqueue/Make.defs index bed60fa06d..6d38476893 100644 --- a/sched/mqueue/Make.defs +++ b/sched/mqueue/Make.defs @@ -35,13 +35,13 @@ ifneq ($(CONFIG_DISABLE_MQUEUE),y) -MQUEUE_SRCS = mq_send.c mq_timedsend.c mq_sndinternal.c mq_receive.c -MQUEUE_SRCS += mq_timedreceive.c mq_rcvinternal.c mq_initialize.c -MQUEUE_SRCS += mq_descreate.c mq_desclose.c mq_msgfree.c mq_msgqalloc.c -MQUEUE_SRCS += mq_msgqfree.c mq_release.c mq_recover.c +CSRCS += mq_send.c mq_timedsend.c mq_sndinternal.c mq_receive.c +CSRCS += mq_timedreceive.c mq_rcvinternal.c mq_initialize.c +CSRCS += mq_descreate.c mq_desclose.c mq_msgfree.c mq_msgqalloc.c +CSRCS += mq_msgqfree.c mq_release.c mq_recover.c ifneq ($(CONFIG_DISABLE_SIGNALS),y) -MQUEUE_SRCS += mq_waitirq.c mq_notify.c +CSRCS += mq_waitirq.c mq_notify.c endif # Include mqueue build support diff --git a/sched/paging/Make.defs b/sched/paging/Make.defs index ec90642cc0..9b3b96b25d 100644 --- a/sched/paging/Make.defs +++ b/sched/paging/Make.defs @@ -35,7 +35,7 @@ ifneq ($(CONFIG_PAGING),y) -PG_SRCS = pg_miss.c pg_worker.c +CSRCS += pg_miss.c pg_worker.c # Include paging build support diff --git a/sched/pthread/Make.defs b/sched/pthread/Make.defs index cc27134f1b..89272b14b2 100644 --- a/sched/pthread/Make.defs +++ b/sched/pthread/Make.defs @@ -35,20 +35,20 @@ ifneq ($(CONFIG_DISABLE_PTHREAD),y) -PTHREAD_SRCS = pthread_create.c pthread_exit.c pthread_join.c pthread_detach.c -PTHREAD_SRCS += pthread_yield.c pthread_getschedparam.c pthread_setschedparam.c -PTHREAD_SRCS += pthread_mutexinit.c pthread_mutexdestroy.c -PTHREAD_SRCS += pthread_mutexlock.c pthread_mutextrylock.c pthread_mutexunlock.c -PTHREAD_SRCS += pthread_condinit.c pthread_conddestroy.c -PTHREAD_SRCS += pthread_condwait.c pthread_condsignal.c pthread_condbroadcast.c -PTHREAD_SRCS += pthread_barrierinit.c pthread_barrierdestroy.c pthread_barrierwait.c -PTHREAD_SRCS += pthread_cancel.c pthread_setcancelstate.c -PTHREAD_SRCS += pthread_keycreate.c pthread_setspecific.c pthread_getspecific.c pthread_keydelete.c -PTHREAD_SRCS += pthread_initialize.c pthread_completejoin.c pthread_findjoininfo.c -PTHREAD_SRCS += pthread_once.c pthread_release.c pthread_setschedprio.c +CSRCS += pthread_create.c pthread_exit.c pthread_join.c pthread_detach.c +CSRCS += pthread_yield.c pthread_getschedparam.c pthread_setschedparam.c +CSRCS += pthread_mutexinit.c pthread_mutexdestroy.c +CSRCS += pthread_mutexlock.c pthread_mutextrylock.c pthread_mutexunlock.c +CSRCS += pthread_condinit.c pthread_conddestroy.c +CSRCS += pthread_condwait.c pthread_condsignal.c pthread_condbroadcast.c +CSRCS += pthread_barrierinit.c pthread_barrierdestroy.c pthread_barrierwait.c +CSRCS += pthread_cancel.c pthread_setcancelstate.c +CSRCS += pthread_keycreate.c pthread_setspecific.c pthread_getspecific.c pthread_keydelete.c +CSRCS += pthread_initialize.c pthread_completejoin.c pthread_findjoininfo.c +CSRCS += pthread_once.c pthread_release.c pthread_setschedprio.c ifneq ($(CONFIG_DISABLE_SIGNALS),y) -PTHREAD_SRCS += pthread_condtimedwait.c pthread_kill.c pthread_sigmask.c +CSRCS += pthread_condtimedwait.c pthread_kill.c pthread_sigmask.c endif # Include pthread build support diff --git a/sched/sched/Make.defs b/sched/sched/Make.defs index 6df6d81b96..2ea80d6241 100644 --- a/sched/sched/Make.defs +++ b/sched/sched/Make.defs @@ -33,35 +33,35 @@ # ############################################################################ -SCHED_SRCS = sched_garbage.c sched_getfiles.c -SCHED_SRCS += sched_addreadytorun.c sched_removereadytorun.c sched_addprioritized.c -SCHED_SRCS += sched_mergepending.c sched_addblocked.c sched_removeblocked.c -SCHED_SRCS += sched_free.c sched_gettcb.c sched_verifytcb.c sched_releasetcb.c -SCHED_SRCS += sched_getsockets.c sched_getstreams.c -SCHED_SRCS += sched_setparam.c sched_setpriority.c sched_getparam.c -SCHED_SRCS += sched_setscheduler.c sched_getscheduler.c -SCHED_SRCS += sched_yield.c sched_rrgetinterval.c sched_foreach.c -SCHED_SRCS += sched_lock.c sched_unlock.c sched_lockcount.c sched_self.c +CSRCS += sched_garbage.c sched_getfiles.c +CSRCS += sched_addreadytorun.c sched_removereadytorun.c sched_addprioritized.c +CSRCS += sched_mergepending.c sched_addblocked.c sched_removeblocked.c +CSRCS += sched_free.c sched_gettcb.c sched_verifytcb.c sched_releasetcb.c +CSRCS += sched_getsockets.c sched_getstreams.c +CSRCS += sched_setparam.c sched_setpriority.c sched_getparam.c +CSRCS += sched_setscheduler.c sched_getscheduler.c +CSRCS += sched_yield.c sched_rrgetinterval.c sched_foreach.c +CSRCS += sched_lock.c sched_unlock.c sched_lockcount.c sched_self.c ifeq ($(CONFIG_PRIORITY_INHERITANCE),y) -SCHED_SRCS += sched_reprioritize.c +CSRCS += sched_reprioritize.c endif ifeq ($(CONFIG_SCHED_WAITPID),y) -SCHED_SRCS += sched_waitpid.c +CSRCS += sched_waitpid.c ifeq ($(CONFIG_SCHED_HAVE_PARENT),y) -SCHED_SRCS += sched_waitid.c sched_wait.c +CSRCS += sched_waitid.c sched_wait.c endif endif ifeq ($(CONFIG_SCHED_CPULOAD),y) -SCHED_SRCS += sched_cpuload.c +CSRCS += sched_cpuload.c endif ifeq ($(CONFIG_SCHED_TICKLESS),y) -SCHED_SRCS += sched_timerexpiration.c +CSRCS += sched_timerexpiration.c else -SCHED_SRCS += sched_processtimer.c +CSRCS += sched_processtimer.c endif # Include sched build support diff --git a/sched/semaphore/Make.defs b/sched/semaphore/Make.defs index 0f39b1f96b..97f7660ece 100644 --- a/sched/semaphore/Make.defs +++ b/sched/semaphore/Make.defs @@ -33,15 +33,15 @@ # ############################################################################ -SEM_SRCS = sem_destroy.c sem_wait.c sem_trywait.c sem_timedwait.c -SEM_SRCS += sem_post.c +CSRCS += sem_destroy.c sem_wait.c sem_trywait.c sem_timedwait.c +CSRCS += sem_post.c ifneq ($(CONFIG_DISABLE_SIGNALS),y) -SEM_SRCS += sem_waitirq.c +CSRCS += sem_waitirq.c endif ifeq ($(CONFIG_PRIORITY_INHERITANCE),y) -SEM_SRCS += sem_initialize.c sem_holder.c +CSRCS += sem_initialize.c sem_holder.c endif # Include semaphore build support diff --git a/sched/signal/Make.defs b/sched/signal/Make.defs index 77cb63608c..8521b644aa 100644 --- a/sched/signal/Make.defs +++ b/sched/signal/Make.defs @@ -35,14 +35,14 @@ ifneq ($(CONFIG_DISABLE_SIGNALS),y) -SIGNAL_SRCS = sig_initialize.c -SIGNAL_SRCS += sig_action.c sig_procmask.c sig_pending.c sig_suspend.c -SIGNAL_SRCS += sig_kill.c sig_queue.c sig_waitinfo.c sig_timedwait.c -SIGNAL_SRCS += sig_findaction.c sig_allocatependingsigaction.c -SIGNAL_SRCS += sig_releasependingsigaction.c sig_unmaskpendingsignal.c -SIGNAL_SRCS += sig_removependingsignal.c sig_releasependingsignal.c sig_lowest.c -SIGNAL_SRCS += sig_mqnotempty.c sig_cleanup.c sig_dispatch.c sig_deliver.c -SIGNAL_SRCS += sig_pause.c sig_nanosleep.c +CSRCS += sig_initialize.c +CSRCS += sig_action.c sig_procmask.c sig_pending.c sig_suspend.c +CSRCS += sig_kill.c sig_queue.c sig_waitinfo.c sig_timedwait.c +CSRCS += sig_findaction.c sig_allocatependingsigaction.c +CSRCS += sig_releasependingsigaction.c sig_unmaskpendingsignal.c +CSRCS += sig_removependingsignal.c sig_releasependingsignal.c sig_lowest.c +CSRCS += sig_mqnotempty.c sig_cleanup.c sig_dispatch.c sig_deliver.c +CSRCS += sig_pause.c sig_nanosleep.c # Include signal build support diff --git a/sched/task/Make.defs b/sched/task/Make.defs index 2c89cedbfc..32c21f3324 100644 --- a/sched/task/Make.defs +++ b/sched/task/Make.defs @@ -33,38 +33,38 @@ # ############################################################################ -TSK_SRCS = task_create.c task_init.c task_setup.c task_activate.c -TSK_SRCS += task_start.c task_delete.c task_exit.c task_exithook.c -TSK_SRCS += task_recover.c task_restart.c task_spawnparms.c -TSK_SRCS += task_terminate.c task_getgroup.c task_prctl.c task_getpid.c -TSK_SRCS += exit.c +CSRCS += task_create.c task_init.c task_setup.c task_activate.c +CSRCS += task_start.c task_delete.c task_exit.c task_exithook.c +CSRCS += task_recover.c task_restart.c task_spawnparms.c +CSRCS += task_terminate.c task_getgroup.c task_prctl.c task_getpid.c +CSRCS += exit.c ifeq ($(CONFIG_ARCH_HAVE_VFORK),y) ifeq ($(CONFIG_SCHED_WAITPID),y) -TSK_SRCS += task_vfork.c +CSRCS += task_vfork.c endif endif ifneq ($(CONFIG_BUILD_KERNEL),y) -TSK_SRCS += task_spawn.c +CSRCS += task_spawn.c endif ifneq ($(CONFIG_BINFMT_DISABLE),y) ifeq ($(CONFIG_LIBC_EXECFUNCS),y) -TSK_SRCS += task_execv.c task_posixspawn.c +CSRCS += task_execv.c task_posixspawn.c endif endif ifeq ($(CONFIG_SCHED_STARTHOOK),y) -TSK_SRCS += task_starthook.c +CSRCS += task_starthook.c endif ifeq ($(CONFIG_SCHED_ATEXIT),y) -TSK_SRCS += task_atexit.c +CSRCS += task_atexit.c endif ifeq ($(CONFIG_SCHED_ONEXIT),y) -TSK_SRCS += task_onexit.c +CSRCS += task_onexit.c endif # Include task build support diff --git a/sched/timer/Make.defs b/sched/timer/Make.defs index 09e964513c..5f491ac6cf 100644 --- a/sched/timer/Make.defs +++ b/sched/timer/Make.defs @@ -35,9 +35,9 @@ ifneq ($(CONFIG_DISABLE_POSIX_TIMERS),y) -TIMER_SRCS += timer_initialize.c timer_create.c timer_delete.c -TIMER_SRCS += timer_getoverrun.c timer_gettime.c timer_settime.c -TIMER_SRCS += timer_release.c +CSRCS += timer_initialize.c timer_create.c timer_delete.c +CSRCS += timer_getoverrun.c timer_gettime.c timer_settime.c +CSRCS += timer_release.c # Include timer build support diff --git a/sched/wdog/Make.defs b/sched/wdog/Make.defs index 29ac9a52c5..77fcb73890 100644 --- a/sched/wdog/Make.defs +++ b/sched/wdog/Make.defs @@ -33,8 +33,8 @@ # ############################################################################ -WDOG_SRCS = wd_initialize.c wd_create.c wd_start.c wd_cancel.c wd_delete.c -WDOG_SRCS += wd_gettime.c +CSRCS += wd_initialize.c wd_create.c wd_start.c wd_cancel.c wd_delete.c +CSRCS += wd_gettime.c # Include wdog build support