chiark / gitweb /
initial checkin: still somewhat sketchy
[distorted-keys] / Makefile.am
CommitLineData
53263601
MW
1### -*-makefile-*-
2###
3### Build script for distorted.org.uk key management
4###
5### (c) 2011 Mark Wooding
6###
7
8###----- Licensing notice ---------------------------------------------------
9###
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.
14###
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.
19###
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.
23
24bin_SCRIPTS =
25dist_pkglib_SCRIPTS =
26pkglib_DATA =
27noinst_SCRIPTS =
28
29EXTRA_DIST =
30CLEANFILES =
31DISTCLEANFILES =
32
33###--------------------------------------------------------------------------
34### Substitution of configuration data.
35
36confsubst = $(top_srcdir)/config/confsubst
37EXTRA_DIST += config/confsubst
38
39SUBSTVARS = \
40 PACKAGE="$(PACKAGE)" VERSION="$(VERSION)" \
41 PYTHON="$(PYTHON)" \
42 bindir="$(bindir)" \
43 pkgconfdir="$(sysconfdir)/$(PACKAGE)" \
44 pkglibdir="$(pkglibdir)"
45
46SUBST = $(AM_V_GEN)$(confsubst)
47
48###--------------------------------------------------------------------------
49### Utility programs.
50
51## Shamir secret-sharing.
52bin_SCRIPTS += shamir
53EXTRA_DIST += shamir.in
54CLEANFILES += shamir
55shamir: shamir.in Makefile
56 $(SUBST) $(srcdir)/shamir.in $(SUBSTVARS) >shamir.new && \
57 chmod +x shamir.new && mv shamir.new shamir
58
59###--------------------------------------------------------------------------
60### Main driver program and commands.
61
62## Main driver.
63bin_SCRIPTS += keys
64EXTRA_DIST += keys.in
65CLEANFILES += keys
66keys: keys.in Makefile
67 $(SUBST) $(srcdir)/keys.in $(SUBSTVARS) >keys.new && \
68 chmod +x keys.new && mv keys.new keys
69
70## Utilities library.
71pkglib_DATA += keyfunc.sh
72EXTRA_DIST += keyfunc.sh.in
73CLEANFILES += keyfunc.sh
74keyfunc.sh: keyfunc.sh.in Makefile
75 $(SUBST) $(srcdir)/keyfunc.sh.in $(SUBSTVARS) >keyfunc.sh.new && \
76 mv keyfunc.sh.new keyfunc.sh
77
78## Commands.
79dist_pkglib_SCRIPTS += keeper-cards
80dist_pkglib_SCRIPTS += new-keeper
81dist_pkglib_SCRIPTS += new-recov
82dist_pkglib_SCRIPTS += reveal
83
84###----- That's all, folks --------------------------------------------------