Simplify how C source files are selected in the build
This commit is contained in:
parent
d7843c8e24
commit
322f9f401c
@ -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
|
||||
|
||||
|
@ -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
|
||||
|
||||
|
@ -44,7 +44,7 @@
|
||||
#include <nuttx/sched.h>
|
||||
|
||||
/****************************************************************************
|
||||
* Definitions
|
||||
* Pre-processor Definitions
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_DISABLE_ENVIRON
|
||||
|
@ -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
|
||||
|
@ -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
|
||||
|
||||
|
@ -33,7 +33,7 @@
|
||||
#
|
||||
############################################################################
|
||||
|
||||
INIT_SRCS = os_start.c os_bringup.c
|
||||
CSRCS += os_start.c os_bringup.c
|
||||
|
||||
# Include init build support
|
||||
|
||||
|
@ -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
|
||||
|
||||
|
@ -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
|
||||
|
@ -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
|
||||
|
||||
|
@ -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
|
||||
|
@ -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
|
||||
|
@ -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
|
||||
|
@ -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
|
||||
|
||||
|
@ -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
|
||||
|
@ -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
|
||||
|
||||
|
@ -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
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user