1997-09-04 06:04:33 +00:00
|
|
|
#
|
2000-01-09 08:31:47 +00:00
|
|
|
# $Id: Makefile.in,v 1.73 1999/11/30 19:22:59 bg Exp $
|
1997-09-04 06:04:33 +00:00
|
|
|
#
|
|
|
|
|
|
|
|
SHELL = /bin/sh
|
|
|
|
|
|
|
|
srcdir = @srcdir@
|
|
|
|
VPATH = @srcdir@
|
|
|
|
|
|
|
|
CC = @CC@
|
1999-09-19 14:19:32 +00:00
|
|
|
LINK = @LINK@
|
1997-09-04 06:04:33 +00:00
|
|
|
CPP = @CPP@
|
|
|
|
AR = ar
|
|
|
|
RANLIB = @RANLIB@
|
|
|
|
DEFS = @DEFS@
|
1999-09-19 14:19:32 +00:00
|
|
|
CFLAGS = @CFLAGS@ $(WFLAGS)
|
|
|
|
WFLAGS = @WFLAGS@
|
|
|
|
AWK = @AWK@
|
1997-09-04 06:04:33 +00:00
|
|
|
|
|
|
|
INSTALL = @INSTALL@
|
|
|
|
INSTALL_DATA = @INSTALL_DATA@
|
|
|
|
MKINSTALLDIRS = @top_srcdir@/mkinstalldirs
|
|
|
|
|
|
|
|
prefix = @prefix@
|
|
|
|
exec_prefix = @exec_prefix@
|
|
|
|
libdir = @libdir@
|
1999-09-19 14:19:32 +00:00
|
|
|
EXECSUFFIX = @EXECSUFFIX@
|
1997-09-04 06:04:33 +00:00
|
|
|
PICFLAGS = # @PICFLAGS@
|
|
|
|
|
|
|
|
LIBNAME = $(LIBPREFIX)roken
|
|
|
|
#LIBEXT = @LIBEXT@ Always build archive library and don't install!
|
|
|
|
LIBEXT = a
|
|
|
|
LIBPREFIX = @LIBPREFIX@
|
|
|
|
SHLIBEXT = @SHLIBEXT@
|
|
|
|
LDSHARED = @LDSHARED@
|
|
|
|
LIB = $(LIBNAME).$(LIBEXT)
|
|
|
|
|
|
|
|
SOURCES = \
|
1999-09-19 14:19:32 +00:00
|
|
|
base64.c \
|
|
|
|
chown.c \
|
|
|
|
concat.c \
|
2000-01-09 08:31:47 +00:00
|
|
|
copyhostent.c \
|
1999-09-19 14:19:32 +00:00
|
|
|
daemon.c \
|
|
|
|
emalloc.c \
|
|
|
|
erealloc.c \
|
|
|
|
estrdup.c \
|
|
|
|
eread.c \
|
|
|
|
err.c \
|
|
|
|
errx.c \
|
|
|
|
ewrite.c \
|
|
|
|
fchown.c \
|
|
|
|
flock.c \
|
|
|
|
fnmatch.c \
|
2000-01-09 08:31:47 +00:00
|
|
|
freehostent.c \
|
1999-09-19 14:19:32 +00:00
|
|
|
get_window_size.c \
|
|
|
|
getarg.c \
|
|
|
|
getcwd.c \
|
|
|
|
get_default_username.c \
|
|
|
|
getdtablesize.c \
|
|
|
|
gethostname.c \
|
2000-01-09 08:31:47 +00:00
|
|
|
getipnodebyaddr.c \
|
|
|
|
getipnodebyname.c \
|
1999-09-19 14:19:32 +00:00
|
|
|
getopt.c \
|
|
|
|
getusershell.c \
|
|
|
|
glob.c \
|
|
|
|
hstrerror.c \
|
|
|
|
inaddr2str.c \
|
|
|
|
inet_aton.c \
|
2000-01-09 08:31:47 +00:00
|
|
|
inet_ntop.c \
|
1999-09-19 14:19:32 +00:00
|
|
|
initgroups.c \
|
|
|
|
iruserok.c \
|
|
|
|
issuid.c \
|
|
|
|
k_getpwnam.c \
|
|
|
|
k_getpwuid.c \
|
|
|
|
lstat.c \
|
|
|
|
memmove.c \
|
|
|
|
mini_inetd.c \
|
|
|
|
mkstemp.c \
|
|
|
|
net_read.c \
|
|
|
|
net_write.c \
|
|
|
|
parse_time.c \
|
|
|
|
parse_units.c \
|
|
|
|
print_version.c \
|
|
|
|
putenv.c \
|
|
|
|
resolve.c \
|
|
|
|
rcmd.c \
|
|
|
|
roken_gethostby.c \
|
|
|
|
readv.c \
|
|
|
|
setegid.c \
|
|
|
|
setenv.c \
|
|
|
|
seteuid.c \
|
|
|
|
signal.c \
|
|
|
|
simple_exec.c \
|
|
|
|
snprintf.c \
|
2000-01-09 08:31:47 +00:00
|
|
|
socket.c \
|
1999-09-19 14:19:32 +00:00
|
|
|
strcasecmp.c \
|
|
|
|
strdup.c \
|
|
|
|
strerror.c \
|
|
|
|
strftime.c \
|
2000-01-09 08:31:47 +00:00
|
|
|
strlcat.c \
|
|
|
|
strlcpy.c \
|
1999-09-19 14:19:32 +00:00
|
|
|
strlwr.c \
|
|
|
|
strncasecmp.c \
|
|
|
|
strndup.c \
|
|
|
|
strnlen.c \
|
|
|
|
strsep.c \
|
|
|
|
strtok_r.c \
|
|
|
|
strupr.c \
|
|
|
|
tm2time.c \
|
|
|
|
unsetenv.c \
|
|
|
|
verify.c \
|
|
|
|
verr.c \
|
|
|
|
verrx.c \
|
|
|
|
vsyslog.c \
|
|
|
|
vwarn.c \
|
|
|
|
vwarnx.c \
|
|
|
|
warn.c \
|
|
|
|
warnerr.c \
|
|
|
|
warnx.c
|
|
|
|
|
|
|
|
EXTRA_SOURCES = \
|
|
|
|
make-print-version.c
|
|
|
|
|
|
|
|
OBJECTS = \
|
|
|
|
base64.o \
|
|
|
|
concat.o \
|
|
|
|
emalloc.o \
|
|
|
|
eread.o \
|
|
|
|
erealloc.o \
|
|
|
|
estrdup.o \
|
|
|
|
ewrite.o \
|
|
|
|
get_default_username.o \
|
|
|
|
get_window_size.o \
|
|
|
|
getarg.o \
|
|
|
|
inaddr2str.o \
|
|
|
|
issuid.o \
|
|
|
|
k_getpwnam.o \
|
|
|
|
k_getpwuid.o \
|
|
|
|
mini_inetd.o \
|
|
|
|
net_read.o \
|
|
|
|
net_write.o \
|
|
|
|
parse_time.o \
|
|
|
|
parse_units.o \
|
|
|
|
print_version.o \
|
|
|
|
resolve.o \
|
|
|
|
roken_gethostby.o \
|
|
|
|
signal.o \
|
|
|
|
simple_exec.o \
|
|
|
|
snprintf.o \
|
2000-01-09 08:31:47 +00:00
|
|
|
socket.o \
|
1999-09-19 14:19:32 +00:00
|
|
|
tm2time.o \
|
|
|
|
verify.o \
|
|
|
|
warnerr.o \
|
|
|
|
@LIBOBJS@
|
|
|
|
|
|
|
|
all: $(LIB) install-roken-h
|
1997-09-04 06:04:33 +00:00
|
|
|
|
|
|
|
Wall:
|
|
|
|
make CFLAGS="-g -Wall -Wno-comment -Wmissing-prototypes -Wmissing-declarations -D__USE_FIXED_PROTOTYPES__"
|
|
|
|
|
|
|
|
.c.o:
|
1999-09-19 14:19:32 +00:00
|
|
|
$(CC) -c $(DEFS) -I. -I../../include -I$(srcdir) $(CFLAGS) $(CPPFLAGS) $(PICFLAGS) $<
|
1997-09-04 06:04:33 +00:00
|
|
|
|
|
|
|
install: all
|
|
|
|
|
|
|
|
uninstall:
|
|
|
|
|
1999-09-19 14:19:32 +00:00
|
|
|
TAGS: $(SOURCES) $(EXTRA_SOURCES)
|
|
|
|
etags $(SOURCES) $(EXTRA_SOURCES)
|
1997-09-04 06:04:33 +00:00
|
|
|
|
|
|
|
check:
|
|
|
|
|
|
|
|
clean:
|
1999-09-19 14:19:32 +00:00
|
|
|
rm -f $(LIB) *.o *.a roken.h make-roken$(EXECSUFFIX) make-roken.c \
|
|
|
|
make-print-version$(EXECSUFFIX) print_version.h
|
1997-09-04 06:04:33 +00:00
|
|
|
|
|
|
|
mostlyclean: clean
|
|
|
|
|
|
|
|
distclean: clean
|
|
|
|
rm -f Makefile *.tab.c *~
|
|
|
|
|
|
|
|
realclean: distclean
|
|
|
|
rm -f TAGS
|
|
|
|
|
|
|
|
$(LIBNAME).a: $(OBJECTS)
|
|
|
|
rm -f $@
|
|
|
|
$(AR) cr $@ $(OBJECTS)
|
|
|
|
-$(RANLIB) $@
|
|
|
|
|
|
|
|
$(LIBNAME).$(SHLIBEXT): $(OBJECTS)
|
|
|
|
rm -f $@
|
|
|
|
$(LDSHARED) -o $@ $(OBJECTS)
|
|
|
|
|
1999-09-19 14:19:32 +00:00
|
|
|
roken.h: make-roken$(EXECSUFFIX)
|
|
|
|
@./make-roken > tmp.h ;\
|
|
|
|
if [ -f roken.h ] && cmp -s tmp.h roken.h ; then rm -f tmp.h ; \
|
|
|
|
else rm -f roken.h; mv tmp.h roken.h; fi
|
|
|
|
|
|
|
|
make-roken$(EXECSUFFIX): make-roken.o
|
|
|
|
$(LINK) $(CFLAGS) -o $@ make-roken.o
|
|
|
|
|
|
|
|
make-roken.c: roken.h.in roken.awk
|
|
|
|
$(AWK) -f $(srcdir)/roken.awk $(srcdir)/roken.h.in > make-roken.c
|
|
|
|
|
|
|
|
print_version.o: print_version.h
|
|
|
|
|
|
|
|
print_version.h: make-print-version$(EXECSUFFIX)
|
|
|
|
@./make-print-version$(EXECSUFFIX) print_version.h
|
|
|
|
|
|
|
|
make-print-version$(EXECSUFFIX): make-print-version.o
|
|
|
|
$(LINK) $(CFLAGS) -o $@ make-print-version.o
|
|
|
|
|
|
|
|
install-roken-h: roken.h
|
|
|
|
@if [ -f ../../include/roken.h ] && cmp -s ../../include/roken.h roken.h ; \
|
|
|
|
then :; else \
|
|
|
|
echo " $(INSTALL) roken.h ../../include/roken.h"; \
|
|
|
|
$(INSTALL) roken.h ../../include/roken.h; fi
|
|
|
|
|
|
|
|
$(OBJECTS): ../../include/config.h roken.h
|
|
|
|
|
|
|
|
.PHONY: all Wall install uninstall check clean mostlyclean distclean realclean install-roken-h
|