From: Ken Raeburn Date: Sat, 30 Aug 2003 01:09:41 +0000 (+0000) Subject: Copy and build daemon.c in whatever directories need it, instead of building it X-Git-Tag: krb5-1.4-beta1~748 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=078fda0b90ecc040ea8d4ba2130eb46bc567f480;p=krb5.git Copy and build daemon.c in whatever directories need it, instead of building it into the krb5 library. * aclocal.m4 (KRB5_AC_NEED_DAEMON): New macro. * appl/bsd/configure.in, kadmin/configure.in, kdc/configure.in, krb524/configure.in, slave/configure.in: Use it. Don't directly check if prototype for daemon() is needed. * kadmin/server/Makefile.in (OBJS), kadmin/v5passwdd/Makefile.in (SERV_OBJS), kdc/Makefile.in (OBJS, fakeka), krb524/Makefile.in (SERVER_OBJS), slave/Makefile.in (SERVEROBJS): Use LIBOBJS. * config/post.in (daemon.c): New rule for copying daemon.c locally from lib/krb5/posix. ticket: 1791 git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15801 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/ChangeLog b/src/ChangeLog index d845289a5..43a57c215 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2003-08-29 Ken Raeburn + + * aclocal.m4 (KRB5_AC_NEED_DAEMON): New macro. + 2003-08-26 Ken Raeburn * aclocal.m4 (WITH_CCOPTS, WITH_CPPOPTS, WITH_LINKER, diff --git a/src/aclocal.m4 b/src/aclocal.m4 index afcd22285..2e28b69ef 100644 --- a/src/aclocal.m4 +++ b/src/aclocal.m4 @@ -615,6 +615,13 @@ AC_HELP_STRING([--with-netlib=LIBS], use user defined resolver library), [AC_LIBRARY_NET] )])dnl dnl +dnl +AC_DEFUN(KRB5_AC_NEED_DAEMON, [ +AC_REPLACE_FUNCS(daemon) +KRB5_NEED_PROTO([#ifdef HAVE_UNISTD_H +#include +#endif],daemon,1)])dnl +dnl dnl Check if stdarg or varargs is available *and compiles*; prefer stdarg. dnl (This was sent to djm for incorporation into autoconf 3/12/1996. KR) dnl diff --git a/src/appl/bsd/ChangeLog b/src/appl/bsd/ChangeLog index 75066eedb..253439c52 100644 --- a/src/appl/bsd/ChangeLog +++ b/src/appl/bsd/ChangeLog @@ -1,5 +1,8 @@ 2003-08-29 Ken Raeburn + * configure.in: Call KRB5_AC_NEED_DAEMON instead of checking + whether daemon() prototype is needed. + * krshd.c (ignore_signals): Split out from cleanup(). (doit): Call it when the shell process has completed, before calling syslog. diff --git a/src/appl/bsd/configure.in b/src/appl/bsd/configure.in index 7bfc68e3b..562061559 100644 --- a/src/appl/bsd/configure.in +++ b/src/appl/bsd/configure.in @@ -80,9 +80,7 @@ AC_CHECK_HEADERS(unistd.h stdlib.h string.h sys/filio.h sys/sockio.h sys/label.h AC_HEADER_STDARG AC_REPLACE_FUNCS(getdtablesize) dnl -KRB5_NEED_PROTO([#ifdef HAVE_UNISTD_H -#include -#endif],daemon,1) +KRB5_AC_NEED_DAEMON dnl KRB5_SIGTYPE CHECK_SIGNALS diff --git a/src/config/ChangeLog b/src/config/ChangeLog index 03c70e291..a47e8d2a2 100644 --- a/src/config/ChangeLog +++ b/src/config/ChangeLog @@ -1,3 +1,8 @@ +2003-08-29 Ken Raeburn + + * post.in (daemon.c): New rule for copying daemon.c locally from + master copy in lib/krb5/posix. + 2003-05-27 Ken Raeburn * win-pre.in (CPPFLAGS): Define KRB5_DEPRECATED=1. diff --git a/src/config/post.in b/src/config/post.in index 0a14ce852..d42c2d213 100644 --- a/src/config/post.in +++ b/src/config/post.in @@ -193,6 +193,12 @@ $(RECURSE_TARGETS): fi;\ exit $$status +# Some servers need "daemon", but we're not providing it directly +# through a library. We used to provide it through the krb5 library, +# and the source is still there. +daemon.c: $(SRCTOP)/lib/krb5/posix/daemon.c + $(CP) $(SRCTOP)/lib/krb5/posix/daemon.c daemon.c + ## ## end of post.in ############################################################ diff --git a/src/kadmin/ChangeLog b/src/kadmin/ChangeLog index b16d87642..bd82399af 100644 --- a/src/kadmin/ChangeLog +++ b/src/kadmin/ChangeLog @@ -1,3 +1,8 @@ +2003-08-29 Ken Raeburn + + * configure.in: Call KRB5_AC_NEED_DAEMON instead of checking + whether daemon() prototype is needed. + 2003-01-10 Ken Raeburn * configure.in: Use V5_AC_OUTPUT_MAKEFILE instead of diff --git a/src/kadmin/configure.in b/src/kadmin/configure.in index 48eb0c32a..914129182 100644 --- a/src/kadmin/configure.in +++ b/src/kadmin/configure.in @@ -5,10 +5,7 @@ AC_PROG_YACC AC_PROG_AWK AC_CHECK_HEADERS(unistd.h stdlib.h krb_db.h kdc.h regex.h alloca.h sys/time.h sys/select.h memory.h arpa/inet.h) AC_CHECK_FUNCS(ftime timezone getcwd strstr waitpid vsprintf) -AC_REPLACE_FUNCS([memmove strftime]) -KRB5_NEED_PROTO([#ifdef HAVE_UNISTD_H -#include -#endif],daemon,1) +KRB5_AC_NEED_DAEMON AC_HEADER_TIME CHECK_SIGNALS CHECK_WAIT_TYPE diff --git a/src/kadmin/server/ChangeLog b/src/kadmin/server/ChangeLog index 4a2e37d37..7c363fbcc 100644 --- a/src/kadmin/server/ChangeLog +++ b/src/kadmin/server/ChangeLog @@ -1,3 +1,7 @@ +2003-08-29 Ken Raeburn + + * Makefile.in (OBJS): Use @LIBOBJS@. + 2003-05-27 Tom Yu * schpw.c (process_chpw_request): Log chpw requests. diff --git a/src/kadmin/server/Makefile.in b/src/kadmin/server/Makefile.in index 8a1ee6e39..21e6aab6c 100644 --- a/src/kadmin/server/Makefile.in +++ b/src/kadmin/server/Makefile.in @@ -10,7 +10,7 @@ PROG_LIBPATH=-L$(TOPLIBD) PROG_RPATH=$(KRB5_LIBDIR) PROG = kadmind -OBJS = kadm_rpc_svc.o server_stubs.o ovsec_kadmd.o schpw.o misc.o server_glue_v1.o +OBJS = kadm_rpc_svc.o server_stubs.o ovsec_kadmd.o schpw.o misc.o server_glue_v1.o @LIBOBJS@ all:: $(PROG) diff --git a/src/kadmin/v5passwdd/ChangeLog b/src/kadmin/v5passwdd/ChangeLog index b301eab76..dc3a7b010 100644 --- a/src/kadmin/v5passwdd/ChangeLog +++ b/src/kadmin/v5passwdd/ChangeLog @@ -1,3 +1,7 @@ +2003-08-29 Ken Raeburn + + * Makefile.in (SERV_OBJS): Use @LIBOBJS@. + 2003-01-09 Ken Raeburn * adm_conn.c (kadm_contact_server): Use socklen_t when passing diff --git a/src/kadmin/v5passwdd/Makefile.in b/src/kadmin/v5passwdd/Makefile.in index 88a122107..c9c7672f8 100644 --- a/src/kadmin/v5passwdd/Makefile.in +++ b/src/kadmin/v5passwdd/Makefile.in @@ -8,7 +8,7 @@ PROG_RPATH=$(KRB5_LIBDIR) COMMON_SRCS = $(srcdir)/adm_rw.c COMMON_OBJS = adm_rw.o SERV_SRCS = $(srcdir)/main.c $(srcdir)/srv_net.c $(srcdir)/proto_serv.c -SERV_OBJS = main.o srv_net.o proto_serv.o +SERV_OBJS = main.o srv_net.o proto_serv.o @LIBOBJS@ CLI_SRCS = $(srcdir)/kpasswd.c $(srcdir)/adm_conn.c CLI_OBJS = kpasswd.o adm_conn.o diff --git a/src/kdc/ChangeLog b/src/kdc/ChangeLog index e4d7a9d9a..95ab68987 100644 --- a/src/kdc/ChangeLog +++ b/src/kdc/ChangeLog @@ -1,3 +1,9 @@ +2003-08-29 Ken Raeburn + + * configure.in: Call KRB5_AC_NEED_DAEMON instead of checking + whether daemon() prototype is needed. + * Makefile.in (OBJS, fakeka): Use @LIBOBJS@. + 2003-06-03 Tom Yu * extern.h (master_princ): Remove realm_mkvno, realm_tgskey, diff --git a/src/kdc/Makefile.in b/src/kdc/Makefile.in index 4608a7bfd..c57dd4f4d 100644 --- a/src/kdc/Makefile.in +++ b/src/kdc/Makefile.in @@ -46,7 +46,8 @@ OBJS= \ policy.o \ extern.o \ replay.o \ - kerberos_v4.o + kerberos_v4.o \ + @LIBOBJS@ RT_OBJS= rtest.o \ kdc_util.o \ @@ -73,8 +74,8 @@ krb5kdc: $(OBJS) $(KADMSRV_DEPLIBS) $(KRB4COMPAT_DEPLIBS) rtest: $(RT_OBJS) $(KDB5_DEPLIBS) $(KADM_COMM_DEPLIBS) $(KRB5_BASE_DEPLIBS) $(CC_LINK) -o rtest $(RT_OBJS) $(KDB5_LIBS) $(KADM_COMM_LIBS) $(KRB5_BASE_LIBS) -fakeka: fakeka.o $(KADMSRV_DEPLIBS) $(KRB4COMPAT_DEPLIBS) - $(CC_LINK) -o fakeka fakeka.o $(KADMSRV_LIBS) $(KRB4COMPAT_LIBS) +fakeka: fakeka.o $(KADMSRV_DEPLIBS) $(KRB4COMPAT_DEPLIBS) @LIBOBJS@ + $(CC_LINK) -o fakeka fakeka.o $(KADMSRV_LIBS) $(KRB4COMPAT_LIBS) @LIBOBJS@ check-unix:: rtest KRB5_CONFIG=$(SRCTOP)/config-files/krb5.conf ; export KRB5_CONFIG ;\ diff --git a/src/kdc/configure.in b/src/kdc/configure.in index 620510df3..9515483ac 100644 --- a/src/kdc/configure.in +++ b/src/kdc/configure.in @@ -11,9 +11,7 @@ KRB5_NEED_PROTO([#include #include ],swab,1) dnl -KRB5_NEED_PROTO([#ifdef HAVE_UNISTD_H -#include -#endif],daemon,1) +KRB5_AC_NEED_DAEMON dnl AC_PROG_AWK KRB5_AC_INET6 diff --git a/src/krb524/ChangeLog b/src/krb524/ChangeLog index b5e5b8377..6f7fe60d7 100644 --- a/src/krb524/ChangeLog +++ b/src/krb524/ChangeLog @@ -1,3 +1,9 @@ +2003-08-29 Ken Raeburn + + * configure.in: Call KRB5_AC_NEED_DAEMON instead of checking + whether daemon() prototype is needed. + * Makefile.in (SERVER_OBJS): Use @LIBOBJS@. + 2003-08-11 Tom Yu * cnv_tkt_skey.c (krb524_convert_tkt_skey): Call krb_create_ticket diff --git a/src/krb524/Makefile.in b/src/krb524/Makefile.in index 3de36c818..3d903cbb5 100644 --- a/src/krb524/Makefile.in +++ b/src/krb524/Makefile.in @@ -74,7 +74,7 @@ all-windows:: $(OUTPRE)k524init.exe $(K524LIB) krb524test: test.o $(KRB5_DEPLIB) $(KRB4COMPAT_DEPLIBS) $(CC_LINK) -o krb524test test.o $(KRB5_LIB) $(KRB4COMPAT_LIBS) -SERVER_OBJS= krb524d.o cnv_tkt_skey.o conv_princ.o +SERVER_OBJS= krb524d.o cnv_tkt_skey.o conv_princ.o @LIBOBJS@ CLIENT_OBJS= $(OUTPRE)k524init.$(OBJEXT) krb524d: $(SERVER_OBJS) $(KADMSRV_DEPLIBS) $(KRB5_DEPLIB) $(KRB4COMPAT_DEPLIBS) diff --git a/src/krb524/configure.in b/src/krb524/configure.in index 1ffdac7d7..917ce2a72 100644 --- a/src/krb524/configure.in +++ b/src/krb524/configure.in @@ -4,9 +4,7 @@ KRB5_BUILD_LIBRARY_STATIC KRB5_BUILD_LIBOBJS AC_PROG_AWK AC_CHECK_HEADERS(sys/select.h unistd.h) dnl -KRB5_NEED_PROTO([#ifdef HAVE_UNISTD_H -#include -#endif],daemon,1) +KRB5_AC_NEED_DAEMON AC_TYPE_SIGNAL KRB5_BUILD_PROGRAM diff --git a/src/slave/ChangeLog b/src/slave/ChangeLog index bbf890c27..7a07be47c 100644 --- a/src/slave/ChangeLog +++ b/src/slave/ChangeLog @@ -1,3 +1,9 @@ +2003-08-29 Ken Raeburn + + * configure.in: Call KRB5_AC_NEED_DAEMON instead of checking + whether daemon() prototype is needed. + * Makefile.in (SERVEROBJS): Use @LIBOBJS@. + 2002-08-23 Ken Raeburn * Makefile.in: Change $(S)=>/ and $(U)=>.. globally. diff --git a/src/slave/Makefile.in b/src/slave/Makefile.in index f4d1ad6d4..6c689cfbb 100644 --- a/src/slave/Makefile.in +++ b/src/slave/Makefile.in @@ -11,7 +11,7 @@ CLIENTSRCS= $(srcdir)/kprop.c CLIENTOBJS= kprop.o SERVERSRCS= $(srcdir)/kpropd.c -SERVEROBJS= kpropd.o +SERVEROBJS= kpropd.o @LIBOBJS@ SRCS= $(CLIENTSRCS) $(SERVERSRCS) diff --git a/src/slave/configure.in b/src/slave/configure.in index 5c1f2df12..1ce9f0317 100644 --- a/src/slave/configure.in +++ b/src/slave/configure.in @@ -3,7 +3,7 @@ CONFIG_RULES AC_TYPE_MODE_T AC_PROG_INSTALL AC_CHECK_LIB(util,main) -KRB5_NEED_PROTO([#include ],daemon,1) +KRB5_AC_NEED_DAEMON KRB5_GETSOCKNAME_ARGS KRB5_GETPEERNAME_ARGS KRB5_BUILD_PROGRAM