summaryrefslogtreecommitdiff
path: root/libc/pwd_grp
diff options
context:
space:
mode:
Diffstat (limited to 'libc/pwd_grp')
-rw-r--r--libc/pwd_grp/Makefile.in51
1 files changed, 17 insertions, 34 deletions
diff --git a/libc/pwd_grp/Makefile.in b/libc/pwd_grp/Makefile.in
index 3475d2331..253040e05 100644
--- a/libc/pwd_grp/Makefile.in
+++ b/libc/pwd_grp/Makefile.in
@@ -1,49 +1,32 @@
# Makefile for uClibc
#
# Copyright (C) 2000 by Lineo, inc.
-# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+# Copyright (C) 2000-2006 Erik Andersen <andersen@uclibc.org>
#
# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
#
-MSRC:=pwd_grp.c
-MOBJ:= fgetpwent_r.o fgetgrent_r.o fgetpwent.o fgetgrent.o \
- getpwnam_r.o getgrnam_r.o getpwuid_r.o getgrgid_r.o \
- getpwuid.o getgrgid.o getpwnam.o getgrnam.o getpw.o \
- getpwent_r.o getgrent_r.o getpwent.o getgrent.o \
- initgroups.o putpwent.o putgrent.o \
- __parsepwent.o __parsegrent.o __pgsreader.o
+PWDGRP_DIR := $(top_srcdir)libc/pwd_grp
+PWDGRP_OUT := $(top_builddir)libc/pwd_grp
-ifeq ($(HAS_SHADOW),y)
-MOBJ+= fgetspent_r.o fgetspent.o sgetspent_r.o getspnam_r.o \
- getspnam.o getspent_r.o getspent.o sgetspent.o \
- putspent.o __parsespent.o # getspuid_r.o getspuid.o
-endif
-
-PWDGRP_DIR:=$(top_srcdir)libc/pwd_grp
-PWDGRP_OUT:=$(top_builddir)libc/pwd_grp
-
-PWDGRP_MSRC:=$(PWDGRP_DIR)/$(MSRC)
-PWDGRP_MOBJ:=$(patsubst %.o,$(PWDGRP_OUT)/%.o,$(MOBJ))
+CSRC := $(notdir $(wildcard $(PWDGRP_DIR)/*.c))
+CSRC := $(filter-out pwd_grp.c pwd_grp_internal.c,$(CSRC))
-PWDGRP_DEF:=$(patsubst %,-DL_%,$(subst .o,,$(notdir $(PWDGRP_MOBJ))))
-
-$(PWDGRP_MOBJ): $(PWDGRP_MSRC)
- $(compile.m)
-
-$(PWDGRP_MOBJ:.o=.os): $(PWDGRP_MSRC)
- $(compile.m)
+ifneq ($(HAS_SHADOW),y)
+SHADOW_CSRC := \
+ fgetspent_r.c fgetspent.c getspent_r.c getspent.c \
+ getspnam_r.c getspnam.c lckpwdf.c putspent.c \
+ sgetspent_r.c sgetspent.c __parsespent.c
+# getspuid_r.c getspuid.c
+CSRC := $(filter-out $(SHADOW_CSRC),$(CSRC))
+endif
-libc-a-y+=$(PWDGRP_MOBJ)
-libc-a-$(HAS_SHADOW)+=$(PWDGRP_OUT)/lckpwdf.o
-libc-so-y+=$(PWDGRP_MOBJ:.o=.os)
-libc-so-$(HAS_SHADOW)+=$(PWDGRP_OUT)/lckpwdf.os
+PWDGRP_SRC := $(patsubst %.c,$(PWDGRP_DIR)/%.c,$(CSRC))
+PWDGRP_OBJ := $(patsubst %.c,$(PWDGRP_OUT)/%.o,$(CSRC))
-CFLAGS-multi-y+=$(PWDGRP_DEF)
-libc-multi-y+=$(PWDGRP_MSRC)
-libc-multi-$(HAS_SHADOW)+=$(PWDGRP_DIR)/lckpwdf.c
+libc-y += $(PWDGRP_OBJ)
-objclean-y+=pwdgrp_objclean
+objclean-y += pwdgrp_objclean
pwdgrp_objclean:
$(RM) $(PWDGRP_OUT)/*.{o,os}