1 ## Process this file with automake to produce Makefile.in
3 man8_MANS = statd.man sm-notify.man
7 sbin_PROGRAMS = statd sm-notify
8 dist_sbin_SCRIPTS = start-statd
9 statd_SOURCES = callback.c notlist.c misc.c monitor.c hostname.c \
10 simu.c stat.c statd.c svc_run.c rmtcall.c \
11 notlist.h statd.h system.h version.h
12 sm_notify_SOURCES = sm-notify.c
14 BUILT_SOURCES = $(GENFILES)
15 statd_LDADD = ../../support/nsm/libnsm.a \
16 ../../support/nfs/libnfs.a \
17 ../../support/misc/libmisc.a \
18 $(LIBWRAP) $(LIBNSL) $(LIBCAP)
19 sm_notify_LDADD = ../../support/nsm/libnsm.a \
20 ../../support/nfs/libnfs.a \
23 EXTRA_DIST = sim_sm_inter.x $(man8_MANS) COPYRIGHT simulate.c
26 RPCGEN = $(top_builddir)/tools/rpcgen/rpcgen
28 make -C ../../tools/rpcgen all
30 RPCGEN = @RPCGEN_PATH@
33 $(GENFILES_CLNT): %_clnt.c: %.x $(RPCGEN)
34 test -f $@ && rm -rf $@ || true
37 $(GENFILES_SVC): %_svc.c: %.x $(RPCGEN)
38 test -f $@ && rm -rf $@ || true
41 $(GENFILES_XDR): %_xdr.c: %.x $(RPCGEN)
42 test -f $@ && rm -rf $@ || true
45 $(GENFILES_H): %.h: %.x $(RPCGEN)
46 test -f $@ && rm -rf $@ || true
49 MAINTAINERCLEANFILES = Makefile.in
51 CLEANFILES = $(GENFILES)
53 #######################################################################
54 # The following allows the current practice of having
55 # daemons renamed during the install to include RPCPREFIX
57 # This could all be done much easier with program_transform_name
58 # ( program_transform_name = s/^/$(RPCPREFIX)$(KPREFIX)/ )
59 # but that also renames the man pages, which the current
60 # practice does not do.
62 (cd $(DESTDIR)$(sbindir) && \
63 for p in $(sbin_PROGRAMS); do \
64 [ $$p = sm-notify ] || mv -f $$p$(EXEEXT) $(RPCPREFIX)$(KPREFIX)$$p$(EXEEXT) ;\
67 (cd $(DESTDIR)$(sbindir) && \
68 for p in $(sbin_PROGRAMS); do \
69 [ $$p = sm-notify ] || rm -f $(RPCPREFIX)$(KPREFIX)$$p$(EXEEXT) ;\
73 # XXX This makes some assumptions about what automake does.
74 # XXX But there is no install-man-hook or install-man-local.
75 install-man: install-man8 install-man-links
76 uninstall-man: uninstall-man8 uninstall-man-links
79 (cd $(DESTDIR)$(man8dir) && \
80 for m in $(man8_MANS) $(dist_man8_MANS) $(nodist_man8_MANS); do \
81 inst=`echo $$m | sed -e 's/man$$/8/'`; \
82 rm -f $(RPCPREFIX)$$inst ; \
83 $(LN_S) $$inst $(RPCPREFIX)$$inst ; \
87 (cd $(DESTDIR)$(man8dir) && \
88 for m in $(man8_MANS) $(dist_man8_MANS) $(nodist_man8_MANS); do \
89 inst=`echo $$m | sed -e 's/man$$/8/'`; \
90 rm -f $(RPCPREFIX)$$inst ; \