fixed daemon kill before threads are spawned
[strongswan.git] / src / charon / Makefile.am
1 ipsec_PROGRAMS = charon
2
3 charon_SOURCES = \
4 bus/bus.c bus/bus.h \
5 bus/listeners/file_logger.c bus/listeners/file_logger.h \
6 bus/listeners/sys_logger.c bus/listeners/sys_logger.h \
7 config/backends/backend.h config/backends/writeable_backend.h \
8 config/backend_manager.c config/backend_manager.h \
9 config/child_cfg.c config/child_cfg.h \
10 config/credentials/local_credential_store.c config/credentials/local_credential_store.h \
11 config/ike_cfg.c config/ike_cfg.h \
12 config/peer_cfg.c config/peer_cfg.h \
13 config/proposal.c config/proposal.h \
14 config/traffic_selector.c config/traffic_selector.h \
15 control/interfaces/interface.h \
16 control/interface_manager.c control/interface_manager.h \
17 daemon.c daemon.h \
18 encoding/generator.c encoding/generator.h \
19 encoding/message.c encoding/message.h \
20 encoding/parser.c encoding/parser.h \
21 encoding/payloads/auth_payload.c encoding/payloads/auth_payload.h \
22 encoding/payloads/cert_payload.c encoding/payloads/cert_payload.h \
23 encoding/payloads/certreq_payload.c encoding/payloads/certreq_payload.h \
24 encoding/payloads/configuration_attribute.c encoding/payloads/configuration_attribute.h \
25 encoding/payloads/cp_payload.c encoding/payloads/cp_payload.h \
26 encoding/payloads/delete_payload.c encoding/payloads/delete_payload.h \
27 encoding/payloads/eap_payload.c encoding/payloads/eap_payload.h \
28 encoding/payloads/encodings.c encoding/payloads/encodings.h \
29 encoding/payloads/encryption_payload.c encoding/payloads/encryption_payload.h \
30 encoding/payloads/id_payload.c encoding/payloads/id_payload.h \
31 encoding/payloads/ike_header.c encoding/payloads/ike_header.h \
32 encoding/payloads/ke_payload.c  encoding/payloads/ke_payload.h \
33 encoding/payloads/nonce_payload.c encoding/payloads/nonce_payload.h \
34 encoding/payloads/notify_payload.c encoding/payloads/notify_payload.h \
35 encoding/payloads/payload.c encoding/payloads/payload.h \
36 encoding/payloads/proposal_substructure.c encoding/payloads/proposal_substructure.h \
37 encoding/payloads/sa_payload.c encoding/payloads/sa_payload.h \
38 encoding/payloads/traffic_selector_substructure.c encoding/payloads/traffic_selector_substructure.h \
39 encoding/payloads/transform_attribute.c encoding/payloads/transform_attribute.h \
40 encoding/payloads/transform_substructure.c encoding/payloads/transform_substructure.h \
41 encoding/payloads/ts_payload.c encoding/payloads/ts_payload.h \
42 encoding/payloads/unknown_payload.c encoding/payloads/unknown_payload.h \
43 encoding/payloads/vendor_id_payload.c encoding/payloads/vendor_id_payload.h \
44 kernel/kernel_interface.c kernel/kernel_interface.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.c 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/process_message_job.c processing/jobs/process_message_job.h \
55 processing/jobs/rekey_child_sa_job.c processing/jobs/rekey_child_sa_job.h \
56 processing/jobs/rekey_ike_sa_job.c processing/jobs/rekey_ike_sa_job.h \
57 processing/jobs/retransmit_job.c processing/jobs/retransmit_job.h \
58 processing/jobs/send_dpd_job.c processing/jobs/send_dpd_job.h \
59 processing/jobs/send_keepalive_job.c processing/jobs/send_keepalive_job.h \
60 processing/jobs/roam_job.c processing/jobs/roam_job.h \
61 processing/scheduler.c processing/scheduler.h \
62 processing/processor.c processing/processor.h  \
63 sa/authenticators/authenticator.c sa/authenticators/authenticator.h \
64 sa/authenticators/eap_authenticator.c sa/authenticators/eap_authenticator.h \
65 sa/authenticators/eap/eap_method.c sa/authenticators/eap/eap_method.h \
66 sa/authenticators/psk_authenticator.c sa/authenticators/psk_authenticator.h \
67 sa/authenticators/rsa_authenticator.c sa/authenticators/rsa_authenticator.h \
68 sa/child_sa.c sa/child_sa.h \
69 sa/ike_sa.c sa/ike_sa.h \
70 sa/ike_sa_id.c sa/ike_sa_id.h \
71 sa/ike_sa_manager.c sa/ike_sa_manager.h \
72 sa/task_manager.c sa/task_manager.h \
73 sa/tasks/child_create.c sa/tasks/child_create.h \
74 sa/tasks/child_delete.c sa/tasks/child_delete.h \
75 sa/tasks/child_rekey.c sa/tasks/child_rekey.h \
76 sa/tasks/ike_auth.c sa/tasks/ike_auth.h \
77 sa/tasks/ike_cert.c sa/tasks/ike_cert.h \
78 sa/tasks/ike_config.c sa/tasks/ike_config.h \
79 sa/tasks/ike_delete.c sa/tasks/ike_delete.h \
80 sa/tasks/ike_dpd.c sa/tasks/ike_dpd.h \
81 sa/tasks/ike_init.c sa/tasks/ike_init.h \
82 sa/tasks/ike_natd.c sa/tasks/ike_natd.h \
83 sa/tasks/ike_mobike.c sa/tasks/ike_mobike.h \
84 sa/tasks/ike_rekey.c sa/tasks/ike_rekey.h \
85 sa/tasks/ike_reauth.c sa/tasks/ike_reauth.h \
86 sa/tasks/task.c sa/tasks/task.h
87
88 if USE_P2P
89   charon_SOURCES += encoding/payloads/endpoint_notify.c encoding/payloads/endpoint_notify.h \
90     processing/jobs/initiate_mediation_job.c processing/jobs/initiate_mediation_job.h \
91     processing/jobs/mediation_job.c processing/jobs/mediation_job.h \
92     sa/connect_manager.c sa/connect_manager.h \
93     sa/mediation_manager.c sa/mediation_manager.h \
94     sa/tasks/ike_p2p.c sa/tasks/ike_p2p.h
95 endif
96
97 INCLUDES = -I${linuxdir} -I$(top_srcdir)/src/libstrongswan -I$(top_srcdir)/src/charon -I$(top_srcdir)/src/stroke
98 AM_CFLAGS = -rdynamic -DIPSEC_CONFDIR=\"${confdir}\" -DIPSEC_DIR=\"${ipsecdir}\" -DIPSEC_PIDDIR=\"${piddir}\" \
99         -DIPSEC_EAPDIR=\"${eapdir}\" -DIPSEC_BACKENDDIR=\"${backenddir}\" -DIPSEC_INTERFACEDIR=\"${interfacedir}\"
100 charon_LDADD = $(top_builddir)/src/libstrongswan/libstrongswan.la -lgmp -lpthread -lm -ldl
101
102 if USE_LIBCURL
103   charon_LDADD += -lcurl
104 endif
105
106
107 # build EAP plugins, EAP-Identity is always built
108 #################################################
109 eap_LTLIBRARIES =
110
111 eap_LTLIBRARIES += libeapidentity.la
112 libeapidentity_la_SOURCES = sa/authenticators/eap/eap_identity.h sa/authenticators/eap/eap_identity.c
113 libeapidentity_la_LDFLAGS = -module
114
115 if BUILD_EAP_SIM
116   eap_LTLIBRARIES += libeapsim.la
117   libeapsim_la_SOURCES = sa/authenticators/eap/eap_sim.h sa/authenticators/eap/eap_sim.c
118   libeapsim_la_LDFLAGS = -module
119 endif
120
121 # build backends, local backend is always built
122 ###############################################
123 backend_LTLIBRARIES =
124
125 backend_LTLIBRARIES += liblocal.la
126 liblocal_la_SOURCES = config/backends/local_backend.h config/backends/local_backend.c
127 liblocal_la_LDFLAGS = -module
128
129 if USE_LIBSQLITE
130   backend_LTLIBRARIES += libsqlite.la
131   libsqlite_la_SOURCES = config/backends/sqlite_backend.h config/backends/sqlite_backend.c
132   libsqlite_la_LIBADD = -lsqlite3
133   libsqlite_la_LDFLAGS = -module
134 endif
135
136 # build control interfaces, stroke interface is always built
137 ############################################################
138 interface_LTLIBRARIES =
139
140 interface_LTLIBRARIES += libstroke.la
141 libstroke_la_SOURCES = control/interfaces/stroke_interface.h control/interfaces/stroke_interface.c
142 libstroke_la_LDFLAGS = -module
143
144 if USE_LIBDBUS
145   interface_LTLIBRARIES += libdbus.la
146   libdbus_la_SOURCES = control/interfaces/dbus_interface.h control/interfaces/dbus_interface.c
147   libdbus_la_LDFLAGS = -module
148   libdbus_la_LIBADD = ${dbus_LIBS}
149   INCLUDES += ${dbus_CFLAGS}
150 endif
151
152 if USE_LIBXML
153   interface_LTLIBRARIES += libxml.la
154   libxml_la_SOURCES = control/interfaces/xml_interface.h control/interfaces/xml_interface.c
155   libxml_la_LDFLAGS = -module
156   libxml_la_LIBADD = ${xml_LIBS}
157   INCLUDES += ${xml_CFLAGS}
158 endif
159