]> git.ipfire.org Git - people/ms/strongswan.git/blame - conf/Makefile.am
imv_policy_manager: Added capability to execute an allow or block shell command string
[people/ms/strongswan.git] / conf / Makefile.am
CommitLineData
1b98f858
TB
1# make this relative to the location of strongswan.conf
2strongswanconfdir = `dirname $(strongswan_conf)`
3strongswanddir = $(strongswanconfdir)/strongswan.d
4charonconfdir = $(strongswanddir)/charon
7f535b39
TB
5# copy these files also to /usr/share
6templatesdir = $(pkgdatadir)/templates/config
7optionstemplatedir = $(templatesdir)/strongswan.d
8pluginstemplatedir = $(templatesdir)/plugins
c75acc4c 9
1b98f858 10options = \
4d066ef7 11 options/aikgen.opt \
5ac75787 12 options/attest.opt \
da8b16a1 13 options/charon.opt \
4576f7f9 14 options/charon-logging.opt \
e2d9f27c 15 options/charon-systemd.opt \
bf3f4bf7 16 options/imcv.opt \
79b5a33c 17 options/imv_policy_manager.opt \
ff94fe15
TB
18 options/manager.opt \
19 options/medsrv.opt \
bf3f4bf7 20 options/pacman.opt \
3986c1e3 21 options/pki.opt \
ff94fe15 22 options/pool.opt \
3986c1e3 23 options/scepclient.opt \
ff94fe15 24 options/starter.opt \
38f27e17 25 options/swanctl.opt \
3986c1e3 26 options/tnc.opt
1b98f858
TB
27
28plugins = \
828815b0
TB
29 plugins/android_log.opt \
30 plugins/attr.opt \
31 plugins/attr-sql.opt \
c2aca9ee 32 plugins/bliss.opt \
828815b0
TB
33 plugins/certexpire.opt \
34 plugins/coupling.opt \
35 plugins/dhcp.opt \
36 plugins/dnscert.opt \
37 plugins/duplicheck.opt \
38 plugins/eap-aka.opt \
39 plugins/eap-aka-3ggp2.opt \
40 plugins/eap-dynamic.opt \
41 plugins/eap-gtc.opt \
42 plugins/eap-peap.opt \
43 plugins/eap-radius.opt \
44 plugins/eap-sim.opt \
45 plugins/eap-simaka-sql.opt \
46 plugins/eap-tls.opt \
47 plugins/eap-tnc.opt \
48 plugins/eap-ttls.opt \
49 plugins/error-notify.opt \
b2c1973f 50 plugins/ext-auth.opt \
ed14d3eb 51 plugins/forecast.opt \
828815b0
TB
52 plugins/gcrypt.opt \
53 plugins/ha.opt \
5ac75787 54 plugins/imc-attestation.opt \
bf3f4bf7
TB
55 plugins/imc-os.opt \
56 plugins/imc-scanner.opt \
5ac75787 57 plugins/imc-swid.opt \
bf3f4bf7 58 plugins/imc-test.opt \
5ac75787 59 plugins/imv-attestation.opt \
bf3f4bf7
TB
60 plugins/imv-os.opt \
61 plugins/imv-scanner.opt \
bfd8f8c5 62 plugins/imv-swid.opt \
bf3f4bf7 63 plugins/imv-test.opt \
828815b0
TB
64 plugins/ipseckey.opt \
65 plugins/led.opt \
828815b0
TB
66 plugins/kernel-libipsec.opt \
67 plugins/kernel-netlink.opt \
96e61305 68 plugins/kernel-pfkey.opt \
828815b0
TB
69 plugins/kernel-pfroute.opt \
70 plugins/load-tester.opt \
71 plugins/lookip.opt \
72 plugins/ntru.opt \
73 plugins/openssl.opt \
74 plugins/pkcs11.opt \
75 plugins/radattr.opt \
76 plugins/random.opt \
77 plugins/resolve.opt \
78 plugins/socket-default.opt \
79 plugins/sql.opt \
80 plugins/stroke.opt \
81 plugins/systime-fix.opt \
82 plugins/tnc-ifmap.opt \
4576f7f9
TB
83 plugins/tnc-imc.opt \
84 plugins/tnc-imv.opt \
828815b0 85 plugins/tnc-pdp.opt \
4576f7f9
TB
86 plugins/tnccs-11.opt \
87 plugins/tnccs-20.opt \
828815b0
TB
88 plugins/unbound.opt \
89 plugins/updown.opt \
7dbf9e15 90 plugins/vici.opt \
828815b0
TB
91 plugins/whitelist.opt \
92 plugins/xauth-eap.opt \
93 plugins/xauth-pam.opt
1b98f858
TB
94
95alloptions = $(options) $(plugins)
96
97confsnippets = $(alloptions:opt=conf)
98
99# we only install snippets for enabled plugins
100plugins_install_tmp = $(charon_plugins:%=plugins/%.tmp)
101plugins_install_src = $(charon_plugins:%=plugins/%.conf)
7573a7ed
TB
102# only install snippets for enabled components
103# has to be defined via autoconf as we can't do it with automake conditionals
104options_install_src = $(strongswan_options:%=options/%.conf)
6a2de77f 105
7f535b39
TB
106templates_DATA = strongswan.conf
107optionstemplate_DATA = $(options_install_src)
108pluginstemplate_DATA = $(plugins_install_src)
91cc523c
TB
109man_MANS = \
110 strongswan.conf.5
1b98f858 111
7f62b7d0 112BUILT_SOURCES = default.conf strongswan.conf.5.main $(confsnippets)
1b98f858 113EXTRA_DIST = format-options.py strongswan.conf default.opt \
7f62b7d0 114 default.conf strongswan.conf.5.main $(alloptions) $(confsnippets)
1b98f858 115
91cc523c
TB
116CLEANFILES=$(man_MANS)
117
1b98f858
TB
118.opt.conf:
119 $(AM_V_GEN) \
120 case "$<" in \
121 *plugins/*) \
122 sed \
123 -e "s:\@PLUGIN_NAME\@:`basename $< .opt`:" \
124 $(srcdir)/default.opt | cat - $< | \
125 $(PYTHON) $(srcdir)/format-options.py -f conf -r charon.plugins > $(srcdir)/$@ \
126 ;; \
127 *) \
128 $(PYTHON) $(srcdir)/format-options.py -f conf -r charon.plugins $< > $(srcdir)/$@ \
129 ;; \
130 esac
131
132# we need another implicit rule to generate files from the generic template only
133# if the rules above did not catch it. this requires an intermediate step that
134# generates a copy of the generic config template.
135$(plugins_install_tmp):
d56a23c5
TB
136 @mkdir -p $(builddir)/plugins
137 @cp $(srcdir)/default.conf $(builddir)/$@
1b98f858
TB
138
139.tmp.conf:
140 $(AM_V_GEN) \
141 sed \
142 -e "s:\@PLUGIN_NAME\@:`basename $< .tmp`:" \
d56a23c5 143 $(builddir)/$< > $(builddir)/$@
1b98f858 144
7f62b7d0
TB
145strongswan.conf.5.main: $(alloptions)
146 $(AM_V_GEN) \
bd1c9f1e 147 cd $(srcdir) && $(PYTHON) format-options.py -f man $(alloptions) > $@
7f62b7d0 148
bd1c9f1e 149strongswan.conf.5: strongswan.conf.5.head strongswan.conf.5.main strongswan.conf.5.tail
c4bb26b8 150 $(AM_V_GEN) \
bd1c9f1e 151 cat strongswan.conf.5.head $(srcdir)/strongswan.conf.5.main strongswan.conf.5.tail > $@
c4bb26b8 152
d56a23c5
TB
153clean-local:
154 rm -f plugins/*.conf plugins/*.tmp
155
1b98f858
TB
156maintainer-clean-local:
157 cd $(srcdir) && \
158 rm -f $(confsnippets) default.conf plugins/*.conf plugins/*.tmp
159
6a2de77f 160install-data-local: $(plugins_install_src)
0efea2fd
SL
161 test -e "$(DESTDIR)${strongswanconfdir}" || $(INSTALL) -d "$(DESTDIR)$(strongswanconfdir)" || true
162 test -e "$(DESTDIR)${strongswanddir}" || $(INSTALL) -d "$(DESTDIR)$(strongswanddir)" || true
163 test -e "$(DESTDIR)${charonconfdir}" || $(INSTALL) -d "$(DESTDIR)$(charonconfdir)" || true
efce4559 164 test -e "$(DESTDIR)$(strongswanconfdir)/strongswan.conf" || $(INSTALL) -m 644 $(srcdir)/strongswan.conf $(DESTDIR)$(strongswanconfdir)/strongswan.conf || true
6a2de77f
TB
165 for f in $(options_install_src); do \
166 name=`basename $$f`; \
5645ad29 167 test -f "$(DESTDIR)$(strongswanddir)/$$name" || $(INSTALL) -m 644 "$(srcdir)/$$f" "$(DESTDIR)$(strongswanddir)/$$name" || true; \
6a2de77f
TB
168 done
169 for f in $(plugins_install_src); do \
170 name=`basename $$f`; \
d56a23c5 171 if test -f "$$f"; then dir=; else dir="$(srcdir)/"; fi; \
5645ad29 172 test -f "$(DESTDIR)$(charonconfdir)/$$name" || $(INSTALL) -m 644 "$$dir$$f" "$(DESTDIR)$(charonconfdir)/$$name" || true; \
6a2de77f 173 done