Threading primitives separated.
[strongswan.git] / src / libstrongswan / Makefile.am
1 lib_LTLIBRARIES = libstrongswan.la
2
3 libstrongswan_la_SOURCES = \
4 library.c library.h \
5 chunk.c chunk.h \
6 debug.c debug.h \
7 enum.c enum.h \
8 settings.h settings.c \
9 printf_hook.c printf_hook.h \
10 asn1/asn1.c asn1/asn1.h \
11 asn1/asn1_parser.c asn1/asn1_parser.h \
12 asn1/oid.c asn1/oid.h \
13 attributes/attributes.c attributes/attributes.h \
14 attributes/attribute_provider.h attributes/attribute_handler.h \
15 attributes/attribute_manager.c attributes/attribute_manager.h \
16 crypto/crypters/crypter.c crypto/crypters/crypter.h \
17 crypto/hashers/hasher.h crypto/hashers/hasher.c \
18 crypto/pkcs9.c crypto/pkcs9.h \
19 crypto/proposal/proposal_keywords.c crypto/proposal/proposal_keywords.h \
20 crypto/prfs/prf.c crypto/prfs/prf.h \
21 crypto/rngs/rng.c crypto/rngs/rng.h \
22 crypto/prf_plus.h crypto/prf_plus.c \
23 crypto/signers/signer.c crypto/signers/signer.h \
24 crypto/crypto_factory.c crypto/crypto_factory.h \
25 crypto/crypto_tester.c crypto/crypto_tester.h \
26 crypto/diffie_hellman.c crypto/diffie_hellman.h \
27 crypto/transform.c crypto/transform.h \
28 credentials/credential_factory.c credentials/credential_factory.h \
29 credentials/builder.c credentials/builder.h \
30 credentials/keys/key_encoding.c credentials/keys/key_encoding.h \
31 credentials/keys/private_key.c credentials/keys/private_key.h \
32 credentials/keys/public_key.c credentials/keys/public_key.h \
33 credentials/keys/shared_key.c credentials/keys/shared_key.h \
34 credentials/certificates/certificate.c credentials/certificates/certificate.h \
35 credentials/certificates/x509.h credentials/certificates/x509.c \
36 credentials/certificates/ac.h \
37 credentials/certificates/crl.h credentials/certificates/crl.c \
38 credentials/certificates/pkcs10.h \
39 credentials/certificates/ocsp_request.h \
40 credentials/certificates/ocsp_response.h credentials/certificates/ocsp_response.c \
41 credentials/certificates/pgp_certificate.h \
42 credentials/ietf_attributes/ietf_attributes.c credentials/ietf_attributes/ietf_attributes.h \
43 database/database.h database/database_factory.h database/database_factory.c \
44 fetcher/fetcher.h fetcher/fetcher_manager.h fetcher/fetcher_manager.c \
45 selectors/traffic_selector.c selectors/traffic_selector.h \
46 threading.h \
47 threading/mutex.h threading/mutex.c \
48 threading/condvar.h threading/condvar.c \
49 threading/rwlock.h threading/rwlock.c \
50 threading/lock_profiler.h \
51 utils.h utils.c \
52 utils/host.c utils/host.h \
53 utils/identification.c utils/identification.h \
54 utils/iterator.h \
55 utils/lexparser.c utils/lexparser.h \
56 utils/linked_list.c utils/linked_list.h \
57 utils/hashtable.c utils/hashtable.h \
58 utils/enumerator.c utils/enumerator.h \
59 utils/optionsfrom.c utils/optionsfrom.h \
60 utils/backtrace.c utils/backtrace.h \
61 plugins/plugin_loader.c plugins/plugin_loader.h plugins/plugin.h
62
63 libstrongswan_la_LIBADD = -lpthread $(DLLIB) $(BTLIB) $(SOCKLIB) $(RTLIB)
64
65 INCLUDES = -I$(top_srcdir)/src/libstrongswan
66 AM_CFLAGS = \
67 -DIPSEC_DIR=\"${ipsecdir}\" \
68 -DPLUGINDIR=\"${plugindir}\" \
69 -DSTRONGSWAN_CONF=\"${strongswan_conf}\"
70
71 if USE_LEAK_DETECTIVE
72   AM_CFLAGS += -DLEAK_DETECTIVE
73   libstrongswan_la_SOURCES += \
74     utils/leak_detective.c utils/leak_detective.h
75 endif
76
77 if USE_LOCK_PROFILER
78   AM_CFLAGS += -DLOCK_PROFILER
79 endif
80
81 if USE_INTEGRITY_TEST
82   AM_CFLAGS += -DINTEGRITY_TEST
83   libstrongswan_la_SOURCES += \
84     integrity_checker.c integrity_checker.h
85 endif
86
87 if USE_VSTR
88   libstrongswan_la_LIBADD += -lvstr
89 endif
90
91 EXTRA_DIST = \
92 asn1/oid.txt asn1/oid.pl \
93 crypto/proposal/proposal_keywords.txt
94
95 BUILT_SOURCES = \
96 $(srcdir)/asn1/oid.c $(srcdir)/asn1/oid.h \
97 $(srcdir)/crypto/proposal/proposal_keywords.c
98
99 MAINTAINERCLEANFILES = \
100 $(srcdir)/asn1/oid.c $(srcdir)/asn1/oid.h \
101 $(srcdir)/crypto/proposal/proposal_keywords.c
102
103 $(srcdir)/asn1/oid.c :  $(srcdir)/asn1/oid.pl $(srcdir)/asn1/oid.txt
104                 (cd $(srcdir)/asn1/ && $(PERL) oid.pl)
105
106 $(srcdir)/asn1/oid.h :  $(srcdir)/asn1/oid.pl $(srcdir)/asn1/oid.txt
107                 (cd $(srcdir)/asn1/ && $(PERL) oid.pl)
108
109 $(srcdir)/crypto/proposal/proposal_keywords.c:  $(srcdir)/crypto/proposal/proposal_keywords.txt \
110                                                                                                 $(srcdir)/crypto/proposal/proposal_keywords.h
111                 $(GPERF) -N proposal_get_token -m 10 -C -G -c -t -D < \
112                                                                                                 $(srcdir)/crypto/proposal/proposal_keywords.txt > $@
113
114
115 # build plugins with their own Makefile
116 #######################################
117
118 SUBDIRS = .
119
120 if USE_AES
121   SUBDIRS += plugins/aes
122 endif
123
124 if USE_DES
125   SUBDIRS += plugins/des
126 endif
127
128 if USE_BLOWFISH
129   SUBDIRS += plugins/blowfish
130 endif
131
132 if USE_MD4
133   SUBDIRS += plugins/md4
134 endif
135
136 if USE_MD5
137   SUBDIRS += plugins/md5
138 endif
139
140 if USE_SHA1
141   SUBDIRS += plugins/sha1
142 endif
143
144 if USE_SHA2
145   SUBDIRS += plugins/sha2
146 endif
147
148 if USE_FIPS_PRF
149   SUBDIRS += plugins/fips_prf
150 endif
151
152 if USE_GMP
153   SUBDIRS += plugins/gmp
154 endif
155
156 if USE_RANDOM
157   SUBDIRS += plugins/random
158 endif
159
160 if USE_HMAC
161   SUBDIRS += plugins/hmac
162 endif
163
164 if USE_XCBC
165   SUBDIRS += plugins/xcbc
166 endif
167
168 if USE_X509
169   SUBDIRS += plugins/x509
170 endif
171
172 if USE_PUBKEY
173   SUBDIRS += plugins/pubkey
174 endif
175
176 if USE_PKCS1
177   SUBDIRS += plugins/pkcs1
178 endif
179
180 if USE_PGP
181   SUBDIRS += plugins/pgp
182 endif
183
184 if USE_DNSKEY
185   SUBDIRS += plugins/dnskey
186 endif
187
188 if USE_PEM
189   SUBDIRS += plugins/pem
190 endif
191
192 if USE_CURL
193   SUBDIRS += plugins/curl
194 endif
195
196 if USE_LDAP
197   SUBDIRS += plugins/ldap
198 endif
199
200 if USE_MYSQL
201   SUBDIRS += plugins/mysql
202 endif
203
204 if USE_SQLITE
205   SUBDIRS += plugins/sqlite
206 endif
207
208 if USE_ATTR_SQL
209   SUBDIRS += plugins/attr_sql
210 endif
211
212 if USE_PADLOCK
213   SUBDIRS += plugins/padlock
214 endif
215
216 if USE_OPENSSL
217   SUBDIRS += plugins/openssl
218 endif
219
220 if USE_GCRYPT
221   SUBDIRS += plugins/gcrypt
222 endif
223
224 if USE_AGENT
225   SUBDIRS += plugins/agent
226 endif
227
228 if USE_TEST_VECTORS
229   SUBDIRS += plugins/test_vectors
230 endif