xref: /freebsd/contrib/ntp/sntp/Makefile.am (revision 6356dba0b403daa023dec24559ab1f8e602e4f14)
1# Makefile.am, by Harlan Stenn, from:
2# Makefile for sntp
3# N.M. Maclaren, October 2000.
4
5AUTOMAKE_OPTIONS = foreign
6ACLOCAL_AMFLAGS= -I libopts/m4
7
8AM_CPPFLAGS=	$(LIBOPTS_CFLAGS)
9LDADD=	$(LIBOPTS_LDADD)
10
11NULL=
12
13bindir=	${exec_prefix}/${BINSUBDIR}
14bin_PROGRAMS=	sntp
15#run_ag=         cd $(srcdir) && autogen --writable -L $(top_srcdir)/include
16run_ag=         cd $(srcdir) && autogen --writable
17
18SUBDIRS=
19if NEED_LIBOPTS
20SUBDIRS+= libopts
21endif
22SUBDIRS+= .
23
24sntp_SOURCES = \
25	header.h \
26	internet.c \
27	internet.h \
28	kludges.h \
29	main.c \
30	sntp-opts.c \
31	sntp-opts.h \
32	socket.c \
33	timing.c \
34	unix.c \
35	$(NULL)
36
37dist_man_MANS=	sntp.1
38
39EXTRA_DIST=	bincheck.mf	\
40		COPYRIGHT	\
41		sntp-opts.def sntp.1 sntp-opts.texi sntp-opts.menu	\
42		autogen-version.def version.def
43BUILT_SOURCES=	check-autogen-version.def check-version.def	\
44		sntp-opts.c sntp-opts.h sntp.1 sntp-opts.texi sntp-opts.menu
45man_MANS=	sntp.1
46
47
48FRC:
49check-autogen-version.def: FRC
50	@cd $(srcdir)							\
51	&& test -r ../include/autogen-version.def			\
52	&& ( if cmp -s ../include/autogen-version.def autogen-version.def; \
53	   then : ;							\
54	   else cp ../include/autogen-version.def autogen-version.def;	 \
55		echo "Installing new sntp/autogen-version.def file";	\
56	   fi )
57
58check-version.def: FRC
59	@cd $(srcdir)					\
60	&& test -r ../include/version.def		\
61	&& ( if cmp -s ../include/version.def version.def;	\
62	   then : ;						\
63	   else cp ../include/version.def version.def;		\
64		echo "Installing new sntp/version.def file";	\
65	   fi )
66
67$(srcdir)/sntp-opts.h: $(srcdir)/sntp-opts.c
68$(srcdir)/sntp-opts.c: $(srcdir)/sntp-opts.def $(srcdir)/version.def
69	$(run_ag) sntp-opts.def
70
71$(srcdir)/sntp.1: $(srcdir)/sntp-opts.def $(srcdir)/version.def
72	$(run_ag) -Tagman1.tpl -bsntp sntp-opts.def
73
74$(srcdir)/sntp-opts.texi $(srcdir)/sntp-opts.menu: $(srcdir)/sntp-opts.def $(srcdir)/version.def
75	$(run_ag) -Taginfo.tpl -DLEVEL=section sntp-opts.def
76
77include bincheck.mf
78