3 ### Build script for zoneconf
5 ### (c) 2011 Mark Wooding
8 ###----- Licensing notice ---------------------------------------------------
10 ### This program is free software; you can redistribute it and/or modify
11 ### it under the terms of the GNU General Public License as published by
12 ### the Free Software Foundation; either version 2 of the License, or
13 ### (at your option) any later version.
15 ### This program is distributed in the hope that it will be useful,
16 ### but WITHOUT ANY WARRANTY; without even the implied warranty of
17 ### MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 ### GNU General Public License for more details.
20 ### You should have received a copy of the GNU General Public License
21 ### along with this program; if not, write to the Free Software Foundation,
22 ### Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
32 pkgconfdir = $(sysconfdir)/$(PACKAGE)
34 ###--------------------------------------------------------------------------
35 ### Standard configuration substitutions.
37 confsubst = $(top_srcdir)/config/confsubst
38 EXTRA_DIST += config/confsubst
41 prefix=$(prefix) exec_prefix=$(exec_prefix) \
42 bindir=$(bindir) sbindir=$(sbindir) \
43 bindprogsdir=$(bindprogsdir) \
44 pkgconfdir=$(pkgconfdir) \
45 pkgstatedir=$(localstatedir)/lib/$(PACKAGE) \
46 PACKAGE=$(PACKAGE) VERSION=$(VERSION) \
49 V_SUBST = $(V_SUBST_$(V))
50 V_SUBST_ = $(V_SUBST_$(AM_DEFAULT_VERBOSITY))
51 V_SUBST_0 = @echo " SUBST $@";
52 SUBST = $(V_SUBST)$(confsubst)
54 ###--------------------------------------------------------------------------
55 ### Executable scripts.
58 sbin_SCRIPTS += zoneconf
59 EXTRA_DIST += zoneconf.in
60 CLEANFILES += zoneconf
62 zoneconf: zoneconf.in Makefile
63 $(SUBST) $(srcdir)/zoneconf.in $(SUBSTITUTIONS) >zoneconf.new && \
64 chmod +x zoneconf.new && mv zoneconf.new zoneconf
67 sbin_SCRIPTS += zoneconf-install-userv
68 EXTRA_DIST += zoneconf-install-userv
70 noinst_DATA += userv.rc
71 EXTRA_DIST += userv.rc.in
73 userv.rc: userv.rc.in Makefile
74 $(SUBST) $(srcdir)/userv.rc.in $(SUBSTITUTIONS) >userv.rc.new && \
75 mv userv.rc.new userv.rc
78 sbin_SCRIPTS += zoneconf-install-ssh
79 EXTRA_DIST += zoneconf-install-ssh
81 ###--------------------------------------------------------------------------
84 EXTRA_DIST += config/auto-version
87 echo $(VERSION) >$(distdir)/RELEASE
89 ###----- That's all, folks --------------------------------------------------