3 # Copyright (C) 2000-2008 Erik Andersen <andersen@uclibc.org>
5 # Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
10 CFLAGS-libutil
:= -DNOT_IN_libc
-DIS_IN_libutil
$(SSP_ALL_CFLAGS
)
12 libutil_DIR
:= $(top_srcdir
)libutil
13 libutil_OUT
:= $(top_builddir
)libutil
15 libutil_SRC
:= $(wildcard $(libutil_DIR
)/*.c
)
16 ifneq ($(ARCH_USE_MMU
),y
)
17 libutil_SRC
:= $(filter-out $(libutil_DIR
)/forkpty.c
,$(libutil_SRC
))
19 ifneq ($(UCLIBC_HAS_PTY
),y
)
20 libutil_SRC
:= $(filter-out $(libutil_DIR
)/openpty.c
$(libutil_DIR
)/forkpty.c \
23 ifeq ($(UCLIBC_HAS_UTMP
)$(UCLIBC_HAS_UTMPX
),)
24 libutil_SRC
:= $(filter-out \
25 $(libutil_DIR
)/logwtmp.c \
26 $(libutil_DIR
)/login.c \
27 $(libutil_DIR
)/logout.c \
31 libutil_OBJ
:= $(patsubst $(libutil_DIR
)/%.c
,$(libutil_OUT
)/%.o
,$(libutil_SRC
))
34 libutil-a-y
:= $(libutil_OBJ
:.o
=.os
)
36 libutil-a-y
:= $(libutil_OBJ
)
38 libutil-so-y
:= $(libutil_OBJ
:.o
=.os
)
40 objclean-y
+= CLEAN_libutil
42 $(libutil_OUT
)/libutil.oS
: $(libutil_SRC
)
47 $(do_rm
) $(addprefix $(libutil_OUT
)/*.
, o os oS a
)