3 ### Build script for rsync-backup
5 ### (c) 2012 Mark Wooding
8 ###----- Licensing notice ---------------------------------------------------
10 ### This file is part of the `rsync-backup' program.
12 ### rsync-backup is free software; you can redistribute it and/or modify
13 ### it under the terms of the GNU General Public License as published by
14 ### the Free Software Foundation; either version 2 of the License, or
15 ### (at your option) any later version.
17 ### rsync-backup is distributed in the hope that it will be useful,
18 ### but WITHOUT ANY WARRANTY; without even the implied warranty of
19 ### MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 ### GNU General Public License for more details.
22 ### You should have received a copy of the GNU General Public License
23 ### along with rsync-backup; if not, write to the Free Software Foundation,
24 ### Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
38 AM_CFLAGS = $(mLib_CFLAGS)
40 ###--------------------------------------------------------------------------
41 ### Substitution of configuration data.
43 confsubst = $(top_srcdir)/config/confsubst
44 EXTRA_DIST += config/confsubst
47 PACKAGE="$(PACKAGE)" VERSION="$(VERSION)" \
48 BASH="$(BASH)" PYTHON="$(PYTHON)" \
49 sysconfdir="$(sysconfdir)" \
50 mntbkpdir="$(mntbkpdir)" \
51 fshashdir="$(fshashdir)" \
52 pkglocalstatedir="$(localstatedir)/lib/bkp" \
55 V_SUBST = $(V_SUBST_$V)
56 V_SUBST_= $(V_SUBST_$(AM_DEFAULT_VERBOSITY))
57 V_SUBST_0 = @printf " SUBST %s\n" $@;
59 SUBST = $(V_SUBST)$(confsubst)
61 ###--------------------------------------------------------------------------
62 ### Programs and scripts.
64 EXTRA_PROGRAMS += rfreezefs
65 rfreezefs_SOURCES = rfreezefs.c
66 rfreezefs_LDADD = $(mLib_LIBS)
67 EXTRA_DIST += rfreezefs.8
69 sbin_PROGRAMS += rfreezefs
70 man_MANS += rfreezefs.8
73 sbin_SCRIPTS += rsync-backup
74 dist_man_MANS += rsync-backup.8
75 CLEANFILES += rsync-backup
76 EXTRA_DIST += rsync-backup.in
77 rsync-backup: rsync-backup.in Makefile
78 $(SUBST) >rsync-backup.new \
79 $(srcdir)/rsync-backup.in $(SUBSTVARS) && \
80 chmod +x rsync-backup.new && \
81 mv rsync-backup.new rsync-backup
83 sbin_SCRIPTS += update-bkp-index
84 dist_man_MANS += update-bkp-index.8
85 CLEANFILES += update-bkp-index
86 EXTRA_DIST += update-bkp-index.in
87 update-bkp-index: update-bkp-index.in Makefile
88 $(SUBST) >update-bkp-index.new \
89 $(srcdir)/update-bkp-index.in $(SUBSTVARS) && \
90 chmod +x update-bkp-index.new && \
91 mv update-bkp-index.new update-bkp-index
94 dist_man_MANS += fshash.1
96 EXTRA_DIST += fshash.in
97 fshash: fshash.in Makefile
98 $(SUBST) >fshash.new \
99 $(srcdir)/fshash.in $(SUBSTVARS) && \
100 chmod +x fshash.new && \
103 ###--------------------------------------------------------------------------
104 ### Contributed scripts.
106 ## Some simple scripts showing how one might create and manage backup
107 ## volumes. Assume the distorted.org.uk key management machinery.
108 dist_noinst_SCRIPTS += create-backup-volume
109 dist_noinst_SCRIPTS += mount-backup-volume
110 dist_noinst_SCRIPTS += umount-backup-volume
112 ###--------------------------------------------------------------------------
113 ### Release machinery.
115 EXTRA_DIST += config/auto-version
118 echo $(VERSION) >$(distdir)/RELEASE
120 ###--------------------------------------------------------------------------
121 ### Debian packaging.
123 EXTRA_DIST += debian/copyright debian/changelog
124 EXTRA_DIST += debian/control debian/rules
125 EXTRA_DIST += debian/compat
127 ###----- That's all, folks --------------------------------------------------