Commit | Line | Data |
---|---|---|
6b6ad670 MW |
1 | ### -*-makefile-*- |
2 | ### | |
3 | ### Makefile for TrIPE startup scripts | |
4 | ### | |
5 | ### (c) 2001 Straylight/Edgeware | |
6 | ### | |
78698994 | 7 | |
6b6ad670 MW |
8 | ###----- Licensing notice --------------------------------------------------- |
9 | ### | |
10 | ### This file is part of Trivial IP Encryption (TrIPE). | |
11 | ### | |
11ad66c2 MW |
12 | ### TrIPE is free software: you can redistribute it and/or modify it under |
13 | ### the terms of the GNU General Public License as published by the Free | |
14 | ### Software Foundation; either version 3 of the License, or (at your | |
15 | ### option) any later version. | |
6b6ad670 | 16 | ### |
11ad66c2 MW |
17 | ### TrIPE is distributed in the hope that it will be useful, but WITHOUT |
18 | ### ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
19 | ### FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | |
20 | ### for more details. | |
6b6ad670 MW |
21 | ### |
22 | ### You should have received a copy of the GNU General Public License | |
11ad66c2 | 23 | ### along with TrIPE. If not, see <https://www.gnu.org/licenses/>. |
6b6ad670 MW |
24 | |
25 | include $(top_srcdir)/vars.am | |
26 | ||
27 | noinst_SCRIPTS = | |
28 | ||
29 | ###-------------------------------------------------------------------------- | |
30 | ### Things to install. | |
31 | ||
32 | ## Initialization script. | |
33 | ## Nowhere sensible to put it; leave it uninstalled. | |
34 | noinst_SCRIPTS += tripe-init | |
35 | EXTRA_DIST += tripe-init.in | |
36 | CLEANFILES += tripe-init | |
37 | ||
38 | tripe-init: tripe-init.in Makefile | |
2171b19e | 39 | $(SUBST) $(srcdir)/tripe-init.in >$@.new $(SUBSTITUTIONS) && \ |
6b6ad670 MW |
40 | chmod +x $@.new && mv $@.new $@ |
41 | ||
42 | ## Configuration file for the script. | |
43 | EXTRA_DIST += tripe.conf | |
288fc12b MW |
44 | install-data-local:: tripe.conf |
45 | initconfig=$(initconfig) && dir=$${initconfig%/*} && \ | |
46 | $(MKDIR_P) $(DESTDIR)$$dir | |
47 | test -f $(DESTDIR)$(initconfig) || \ | |
76a24ae6 | 48 | $(INSTALL_DATA) $(srcdir)/tripe.conf \ |
288fc12b MW |
49 | $(DESTDIR)$(initconfig) |
50 | uninstall-local:: | |
51 | rm -f $(DESTDIR)$(initconfig) | |
6b6ad670 MW |
52 | |
53 | ## Necessary directories. | |
288fc12b | 54 | install-data-hook:: |
78698994 | 55 | for i in "$(configdir)" "$(socketdir)"; do \ |
c7211b0d | 56 | case "$$i" in /*) $(MKDIR_P) $(DESTDIR)$$i ;; esac; \ |
78698994 MW |
57 | done |
58 | ||
6b6ad670 | 59 | ###----- That's all, folks -------------------------------------------------- |