moved resolve plugin from libcharon to libhydra
[strongswan.git] / src / libcharon / Makefile.am
1 lib_LTLIBRARIES = libcharon.la
2
3 libcharon_la_SOURCES = \
4 bus/bus.c bus/bus.h \
5 bus/listeners/listener.h \
6 bus/listeners/file_logger.c bus/listeners/file_logger.h \
7 bus/listeners/sys_logger.c bus/listeners/sys_logger.h \
8 config/backend_manager.c config/backend_manager.h config/backend.h \
9 config/child_cfg.c config/child_cfg.h \
10 config/ike_cfg.c config/ike_cfg.h \
11 config/peer_cfg.c config/peer_cfg.h \
12 config/proposal.c config/proposal.h \
13 config/auth_cfg.c config/auth_cfg.h \
14 control/controller.c control/controller.h \
15 daemon.c daemon.h \
16 encoding/generator.c encoding/generator.h \
17 encoding/message.c encoding/message.h \
18 encoding/parser.c encoding/parser.h \
19 encoding/payloads/auth_payload.c encoding/payloads/auth_payload.h \
20 encoding/payloads/cert_payload.c encoding/payloads/cert_payload.h \
21 encoding/payloads/certreq_payload.c encoding/payloads/certreq_payload.h \
22 encoding/payloads/configuration_attribute.c encoding/payloads/configuration_attribute.h \
23 encoding/payloads/cp_payload.c encoding/payloads/cp_payload.h \
24 encoding/payloads/delete_payload.c encoding/payloads/delete_payload.h \
25 encoding/payloads/eap_payload.c encoding/payloads/eap_payload.h \
26 encoding/payloads/encodings.c encoding/payloads/encodings.h \
27 encoding/payloads/encryption_payload.c encoding/payloads/encryption_payload.h \
28 encoding/payloads/id_payload.c encoding/payloads/id_payload.h \
29 encoding/payloads/ike_header.c encoding/payloads/ike_header.h \
30 encoding/payloads/ke_payload.c  encoding/payloads/ke_payload.h \
31 encoding/payloads/nonce_payload.c encoding/payloads/nonce_payload.h \
32 encoding/payloads/notify_payload.c encoding/payloads/notify_payload.h \
33 encoding/payloads/payload.c encoding/payloads/payload.h \
34 encoding/payloads/proposal_substructure.c encoding/payloads/proposal_substructure.h \
35 encoding/payloads/sa_payload.c encoding/payloads/sa_payload.h \
36 encoding/payloads/traffic_selector_substructure.c encoding/payloads/traffic_selector_substructure.h \
37 encoding/payloads/transform_attribute.c encoding/payloads/transform_attribute.h \
38 encoding/payloads/transform_substructure.c encoding/payloads/transform_substructure.h \
39 encoding/payloads/ts_payload.c encoding/payloads/ts_payload.h \
40 encoding/payloads/unknown_payload.c encoding/payloads/unknown_payload.h \
41 encoding/payloads/vendor_id_payload.c encoding/payloads/vendor_id_payload.h \
42 kernel/kernel_interface.c kernel/kernel_interface.h \
43 kernel/kernel_ipsec.c kernel/kernel_ipsec.h \
44 kernel/kernel_net.h \
45 network/packet.c network/packet.h \
46 network/receiver.c network/receiver.h \
47 network/sender.c network/sender.h \
48 network/socket_manager.c network/socket_manager.h network/socket.h \
49 processing/jobs/job.h \
50 processing/jobs/acquire_job.c processing/jobs/acquire_job.h \
51 processing/jobs/callback_job.c processing/jobs/callback_job.h \
52 processing/jobs/delete_child_sa_job.c processing/jobs/delete_child_sa_job.h \
53 processing/jobs/delete_ike_sa_job.c processing/jobs/delete_ike_sa_job.h \
54 processing/jobs/migrate_job.c processing/jobs/migrate_job.h \
55 processing/jobs/process_message_job.c processing/jobs/process_message_job.h \
56 processing/jobs/rekey_child_sa_job.c processing/jobs/rekey_child_sa_job.h \
57 processing/jobs/rekey_ike_sa_job.c processing/jobs/rekey_ike_sa_job.h \
58 processing/jobs/retransmit_job.c processing/jobs/retransmit_job.h \
59 processing/jobs/send_dpd_job.c processing/jobs/send_dpd_job.h \
60 processing/jobs/send_keepalive_job.c processing/jobs/send_keepalive_job.h \
61 processing/jobs/roam_job.c processing/jobs/roam_job.h \
62 processing/jobs/update_sa_job.c processing/jobs/update_sa_job.h \
63 processing/jobs/inactivity_job.c processing/jobs/inactivity_job.h \
64 processing/scheduler.c processing/scheduler.h \
65 processing/processor.c processing/processor.h  \
66 sa/authenticators/authenticator.c sa/authenticators/authenticator.h \
67 sa/authenticators/eap_authenticator.c sa/authenticators/eap_authenticator.h \
68 sa/authenticators/eap/eap_method.c sa/authenticators/eap/eap_method.h \
69 sa/authenticators/eap/eap_manager.c sa/authenticators/eap/eap_manager.h \
70 sa/authenticators/eap/sim_manager.c sa/authenticators/eap/sim_manager.h \
71 sa/authenticators/psk_authenticator.c sa/authenticators/psk_authenticator.h \
72 sa/authenticators/pubkey_authenticator.c sa/authenticators/pubkey_authenticator.h \
73 sa/child_sa.c sa/child_sa.h \
74 sa/ike_sa.c sa/ike_sa.h \
75 sa/ike_sa_id.c sa/ike_sa_id.h \
76 sa/ike_sa_manager.c sa/ike_sa_manager.h \
77 sa/task_manager.c sa/task_manager.h \
78 sa/keymat.c sa/keymat.h \
79 sa/trap_manager.c sa/trap_manager.h \
80 sa/tasks/child_create.c sa/tasks/child_create.h \
81 sa/tasks/child_delete.c sa/tasks/child_delete.h \
82 sa/tasks/child_rekey.c sa/tasks/child_rekey.h \
83 sa/tasks/ike_auth.c sa/tasks/ike_auth.h \
84 sa/tasks/ike_cert_pre.c sa/tasks/ike_cert_pre.h \
85 sa/tasks/ike_cert_post.c sa/tasks/ike_cert_post.h \
86 sa/tasks/ike_config.c sa/tasks/ike_config.h \
87 sa/tasks/ike_delete.c sa/tasks/ike_delete.h \
88 sa/tasks/ike_dpd.c sa/tasks/ike_dpd.h \
89 sa/tasks/ike_init.c sa/tasks/ike_init.h \
90 sa/tasks/ike_natd.c sa/tasks/ike_natd.h \
91 sa/tasks/ike_mobike.c sa/tasks/ike_mobike.h \
92 sa/tasks/ike_rekey.c sa/tasks/ike_rekey.h \
93 sa/tasks/ike_reauth.c sa/tasks/ike_reauth.h \
94 sa/tasks/ike_auth_lifetime.c sa/tasks/ike_auth_lifetime.h \
95 sa/tasks/ike_vendor.c sa/tasks/ike_vendor.h \
96 sa/tasks/task.c sa/tasks/task.h \
97 credentials/credential_manager.c credentials/credential_manager.h \
98 credentials/sets/auth_cfg_wrapper.c credentials/sets/auth_cfg_wrapper.h \
99 credentials/sets/ocsp_response_wrapper.c credentials/sets/ocsp_response_wrapper.h \
100 credentials/sets/cert_cache.c credentials/sets/cert_cache.h \
101 credentials/credential_set.h
102
103 daemon.lo :             $(top_builddir)/config.status
104
105 INCLUDES = \
106         -I${linux_headers} \
107         -I$(top_srcdir)/src/libstrongswan \
108         -I$(top_srcdir)/src/libhydra \
109         -I$(top_srcdir)/src/libcharon
110
111 AM_CFLAGS = \
112         -DIPSEC_DIR=\"${ipsecdir}\" \
113         -DIPSEC_PIDDIR=\"${piddir}\"
114
115 libcharon_la_LIBADD = -lm $(PTHREADLIB) $(DLLIB) $(SOCKLIB)
116
117 EXTRA_DIST = Android.mk
118
119 # compile options
120 #################
121
122 if USE_ME
123   libcharon_la_SOURCES += encoding/payloads/endpoint_notify.c encoding/payloads/endpoint_notify.h \
124     processing/jobs/initiate_mediation_job.c processing/jobs/initiate_mediation_job.h \
125     processing/jobs/mediation_job.c processing/jobs/mediation_job.h \
126     sa/connect_manager.c sa/connect_manager.h \
127     sa/mediation_manager.c sa/mediation_manager.h \
128     sa/tasks/ike_me.c sa/tasks/ike_me.h
129 endif
130
131 if USE_CAPABILITIES
132   libcharon_la_LIBADD += -lcap
133 endif
134
135 # build optional plugins
136 ########################
137
138 if MONOLITHIC
139 SUBDIRS =
140 else
141 SUBDIRS = .
142 endif
143
144 PLUGINS = ${libstrongswan_plugins} ${libhydra_plugins}
145
146 if USE_LOAD_TESTER
147   SUBDIRS += plugins/load_tester
148   PLUGINS += load-tester
149 if MONOLITHIC
150   libcharon_la_LIBADD += plugins/load_tester/libstrongswan-load-tester.la
151 endif
152 endif
153
154 if USE_KERNEL_PFKEY
155   SUBDIRS += plugins/kernel_pfkey
156   PLUGINS += kernel-pfkey
157 if MONOLITHIC
158   libcharon_la_LIBADD += plugins/kernel_pfkey/libstrongswan-kernel-pfkey.la
159 endif
160 endif
161
162 if USE_KERNEL_PFROUTE
163   SUBDIRS += plugins/kernel_pfroute
164   PLUGINS += kernel-pfroute
165 if MONOLITHIC
166   libcharon_la_LIBADD += plugins/kernel_pfroute/libstrongswan-kernel-pfroute.la
167 endif
168 endif
169
170 if USE_KERNEL_KLIPS
171   SUBDIRS += plugins/kernel_klips
172   PLUGINS += kernel-klips
173 if MONOLITHIC
174   libcharon_la_LIBADD += plugins/kernel_klips/libstrongswan-kernel-klips.la
175 endif
176 endif
177
178 if USE_KERNEL_NETLINK
179   SUBDIRS += plugins/kernel_netlink
180   PLUGINS += kernel-netlink
181 if MONOLITHIC
182   libcharon_la_LIBADD += plugins/kernel_netlink/libstrongswan-kernel-netlink.la
183 endif
184 endif
185
186 if USE_SOCKET_DEFAULT
187   SUBDIRS += plugins/socket_default
188   PLUGINS += socket-default
189 if MONOLITHIC
190   libcharon_la_LIBADD += plugins/socket_default/libstrongswan-socket-default.la
191 endif
192 endif
193
194 if USE_SOCKET_RAW
195   SUBDIRS += plugins/socket_raw
196   PLUGINS += socket-raw
197 if MONOLITHIC
198   libcharon_la_LIBADD += plugins/socket_raw/libstrongswan-socket-raw.la
199 endif
200 endif
201
202 if USE_SOCKET_DYNAMIC
203   SUBDIRS += plugins/socket_dynamic
204   PLUGINS += socket-dynamic
205 if MONOLITHIC
206   libcharon_la_LIBADD += plugins/socket_dynamic/libstrongswan-socket-dynamic.la
207 endif
208 endif
209
210 if USE_FARP
211   SUBDIRS += plugins/farp
212   PLUGINS += farp
213 if MONOLITHIC
214   libcharon_la_LIBADD += plugins/farp/libstrongswan-farp.la
215 endif
216 endif
217
218 if USE_STROKE
219   SUBDIRS += plugins/stroke
220   PLUGINS += stroke
221 if MONOLITHIC
222   libcharon_la_LIBADD += plugins/stroke/libstrongswan-stroke.la
223 endif
224 endif
225
226 if USE_SMP
227   SUBDIRS += plugins/smp
228   PLUGINS += smp
229 if MONOLITHIC
230   libcharon_la_LIBADD += plugins/smp/libstrongswan-smp.la
231 endif
232 endif
233
234 if USE_SQL
235   SUBDIRS += plugins/sql
236   PLUGINS += sql
237 if MONOLITHIC
238   libcharon_la_LIBADD += plugins/sql/libstrongswan-sql.la
239 endif
240 endif
241
242 if USE_UPDOWN
243   SUBDIRS += plugins/updown
244   PLUGINS += updown
245 if MONOLITHIC
246   libcharon_la_LIBADD += plugins/updown/libstrongswan-updown.la
247 endif
248 endif
249
250 if USE_EAP_IDENTITY
251   SUBDIRS += plugins/eap_identity
252   PLUGINS += eap-identity
253 if MONOLITHIC
254   libcharon_la_LIBADD += plugins/eap_identity/libstrongswan-eap-identity.la
255 endif
256 endif
257
258 if USE_EAP_SIM
259   SUBDIRS += plugins/eap_sim
260   PLUGINS += eap-sim
261 if MONOLITHIC
262   libcharon_la_LIBADD += plugins/eap_sim/libstrongswan-eap-sim.la
263 endif
264 endif
265
266 if USE_EAP_SIM_FILE
267   SUBDIRS += plugins/eap_sim_file
268   PLUGINS += eap-sim-file
269 if MONOLITHIC
270   libcharon_la_LIBADD += plugins/eap_sim_file/libstrongswan-eap-sim-file.la
271 endif
272 endif
273
274 if USE_EAP_SIMAKA_PSEUDONYM
275   SUBDIRS += plugins/eap_simaka_pseudonym
276   PLUGINS += eap-simaka-pseudonym
277 if MONOLITHIC
278   libcharon_la_LIBADD += plugins/eap_simaka_pseudonym/libstrongswan-eap-simaka-pseudonym.la
279 endif
280 endif
281
282 if USE_EAP_SIMAKA_REAUTH
283   SUBDIRS += plugins/eap_simaka_reauth
284   PLUGINS += eap-simaka-reauth
285 if MONOLITHIC
286   libcharon_la_LIBADD += plugins/eap_simaka_reauth/libstrongswan-eap-simaka-reauth.la
287 endif
288 endif
289
290 if USE_EAP_AKA
291   SUBDIRS += plugins/eap_aka
292   PLUGINS += eap-aka
293 if MONOLITHIC
294   libcharon_la_LIBADD += plugins/eap_aka/libstrongswan-eap-aka.la
295 endif
296 endif
297
298 if USE_EAP_AKA_3GPP2
299   SUBDIRS += plugins/eap_aka_3gpp2
300   PLUGINS += eap-aka-3gpp2
301 if MONOLITHIC
302   libcharon_la_LIBADD += plugins/eap_aka_3gpp2/libstrongswan-eap-aka-3gpp2.la
303 endif
304 endif
305
306 if USE_SIMAKA
307 if MONOLITHIC
308   # otherwise this library is linked to both the eap_aka and the eap_sim plugin
309   libcharon_la_LIBADD += $(top_builddir)/src/libsimaka/libsimaka.la
310 endif
311 endif
312
313 if USE_EAP_MD5
314   SUBDIRS += plugins/eap_md5
315   PLUGINS += eap-md5
316 if MONOLITHIC
317   libcharon_la_LIBADD += plugins/eap_md5/libstrongswan-eap-md5.la
318 endif
319 endif
320
321 if USE_EAP_GTC
322   SUBDIRS += plugins/eap_gtc
323   PLUGINS += eap-gtc
324 if MONOLITHIC
325   libcharon_la_LIBADD += plugins/eap_gtc/libstrongswan-eap-gtc.la
326 endif
327 endif
328
329 if USE_EAP_MSCHAPV2
330   SUBDIRS += plugins/eap_mschapv2
331   PLUGINS += eap-mschapv2
332 if MONOLITHIC
333   libcharon_la_LIBADD += plugins/eap_mschapv2/libstrongswan-eap-mschapv2.la
334 endif
335 endif
336
337 if USE_EAP_RADIUS
338   SUBDIRS += plugins/eap_radius
339   PLUGINS += eap-radius
340 if MONOLITHIC
341   libcharon_la_LIBADD += plugins/eap_radius/libstrongswan-eap-radius.la
342 endif
343 endif
344
345 if USE_MEDSRV
346   SUBDIRS += plugins/medsrv
347   PLUGINS += medsrv
348 if MONOLITHIC
349   libcharon_la_LIBADD += plugins/medsrv/libstrongswan-medsrv.la
350 endif
351 endif
352
353 if USE_MEDCLI
354   SUBDIRS += plugins/medcli
355   PLUGINS += medcli
356 if MONOLITHIC
357   libcharon_la_LIBADD += plugins/medcli/libstrongswan-medcli.la
358 endif
359 endif
360
361 if USE_NM
362   SUBDIRS += plugins/nm
363   PLUGINS += nm
364 if MONOLITHIC
365   libcharon_la_LIBADD += plugins/nm/libstrongswan-nm.la
366 endif
367 endif
368
369 if USE_DHCP
370   SUBDIRS += plugins/dhcp
371   PLUGINS += dhcp
372 if MONOLITHIC
373   libcharon_la_LIBADD += plugins/dhcp/libstrongswan-dhcp.la
374 endif
375 endif
376
377 if USE_ANDROID
378   SUBDIRS += plugins/android
379   PLUGINS += android
380 if MONOLITHIC
381   libcharon_la_LIBADD += plugins/android/libstrongswan-android.la
382 endif
383 endif
384
385 if USE_HA
386   SUBDIRS += plugins/ha
387   PLUGINS += ha
388 if MONOLITHIC
389   libcharon_la_LIBADD += plugins/ha/libstrongswan-ha.la
390 endif
391 endif
392
393 if USE_UCI
394   SUBDIRS += plugins/uci
395   PLUGINS += uci
396 if MONOLITHIC
397   libcharon_la_LIBADD += plugins/uci/libstrongswan-uci.la
398 endif
399 endif
400
401 if USE_UNIT_TESTS
402   SUBDIRS += plugins/unit_tester
403   PLUGINS += unit-tester
404 if MONOLITHIC
405   libcharon_la_LIBADD += plugins/unit_tester/libstrongswan-unit-tester.la
406 endif
407 endif
408
409 AM_CFLAGS += -DPLUGINS=\""${PLUGINS}\""
410