summaryrefslogtreecommitdiff
path: root/librt/Makefile.in
blob: f3cc0655b22c6e60fdc140c031eb60f9e944c7b6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
# Makefile for uClibc
#
# Copyright (C) 2000-2008 Erik Andersen <andersen@uclibc.org>
#
# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
#

subdirs += librt

CFLAGS-librt := -DNOT_IN_libc -DIS_IN_librt $(SSP_ALL_CFLAGS)

librt_DIR := $(top_srcdir)librt
librt_OUT := $(top_builddir)librt

librt_SRC := $(notdir $(wildcard $(librt_DIR)/*.c))
librt_filter_SRC :=
ifeq ($(UCLIBC_HAS_THREADS_NATIVE),y)
librt_filter_SRC += mq_notify.c timer_create.c timer_delete.c \
	timer_getoverr.c timer_gettime.c timer_settime.c
endif

librt_filter_SRC += $(if $(UCLIBC_HAS_ADVANCED_REALTIME),, \
	spawn.c \
	spawn_faction_addclose.c \
	spawn_faction_adddup2.c \
	spawn_faction_addopen.c \
	spawn_faction_init.c)

librt_filter_SRC += $(if $(UCLIBC_HAS_STUBS),,rt_stubs.c)
librt_filter_SRC += $(if $(HAS_NO_THREADS),dso_handle.c)

librt_SRC := $(filter-out $(librt_filter_SRC),$(librt_SRC))
librt_OBJ := $(patsubst %.c,$(librt_OUT)/%.o,$(librt_SRC))

ifeq ($(DOPIC),y)
librt-a-y += $(librt_OBJ:.o=.os)
else
librt-a-y += $(librt_OBJ)
endif
librt-so-y += $(librt_OBJ:.o=.os)

librt-dep-y := $(libc.depend)

objclean-y += CLEAN_librt

CLEAN_librt:
	$(do_rm) $(addprefix $(librt_OUT)/*., o os oS a)