3 include $(top_srcdir)/Makefile.am.common
5 lib_LTLIBRARIES = libhx509.la
6 libhx509_la_LDFLAGS = -version-info 5:0:0
10 $(gen_files_ocsp:.x=.c) \
11 $(gen_files_pkcs10:.x=.c) \
16 asn1_OCSPBasicOCSPResponse.x \
18 asn1_OCSPCertStatus.x \
19 asn1_OCSPInnerRequest.x \
22 asn1_OCSPResponderID.x \
24 asn1_OCSPResponseBytes.x \
25 asn1_OCSPResponseData.x \
26 asn1_OCSPResponseStatus.x \
27 asn1_OCSPSignature.x \
28 asn1_OCSPSingleResponse.x \
29 asn1_OCSPTBSRequest.x \
32 asn1_id_pkix_ocsp_basic.x \
33 asn1_id_pkix_ocsp_nonce.x
36 asn1_CertificationRequestInfo.x \
37 asn1_CertificationRequest.x
40 asn1_CRMFRDNSequence.x \
41 asn1_CertReqMessages.x \
49 asn1_POPOSigningKey.x \
50 asn1_POPOSigningKeyInput.x \
51 asn1_ProofOfPossession.x \
52 asn1_SubsequentMessage.x
56 dist_libhx509_la_SOURCES = \
93 libhx509_la_LIBADD = \
96 $(top_builddir)/lib/asn1/libasn1.la \
97 $(top_builddir)/lib/wind/libwind.la \
101 if FRAMEWORK_SECURITY
102 libhx509_la_LDFLAGS += -framework Security -framework CoreFoundation
106 libhx509_la_LDFLAGS += $(LDFLAGS_VERSION_SCRIPT)$(srcdir)/version-script.map
108 $(libhx509_la_OBJECTS): $(srcdir)/version-script.map
110 libhx509_la_CPPFLAGS = -I$(srcdir)/ref $(INCLUDE_hcrypto)
111 nodist_libhx509_la_SOURCES = $(BUILT_SOURCES)
113 $(gen_files_ocsp) ocsp_asn1.h: ocsp_asn1_files
114 $(gen_files_pkcs10) pkcs10_asn1.h: pkcs10_asn1_files
115 $(gen_files_crmf) crmf_asn1.h: crmf_asn1_files
117 asn1_compile = ../asn1/asn1_compile$(EXEEXT)
119 ocsp_asn1_files: $(asn1_compile) $(srcdir)/ocsp.asn1
120 $(asn1_compile) --preserve-binary=OCSPTBSRequest --preserve-binary=OCSPResponseData $(srcdir)/ocsp.asn1 ocsp_asn1 || (rm -f ocsp_asn1_files ; exit 1)
122 pkcs10_asn1_files: $(asn1_compile) $(srcdir)/pkcs10.asn1
123 $(asn1_compile) --preserve-binary=CertificationRequestInfo $(srcdir)/pkcs10.asn1 pkcs10_asn1 || (rm -f pkcs10_asn1_files ; exit 1)
125 crmf_asn1_files: $(asn1_compile) $(srcdir)/crmf.asn1
126 $(asn1_compile) $(srcdir)/crmf.asn1 crmf_asn1 || (rm -f crmf_asn1_files ; exit 1)
128 $(libhx509_la_OBJECTS): $(srcdir)/hx509-protos.h $(srcdir)/hx509-private.h $(srcdir)/hx_locl.h
129 $(libhx509_la_OBJECTS): ocsp_asn1.h pkcs10_asn1.h
131 $(srcdir)/hx509-protos.h:
132 cd $(srcdir) && perl ../../cf/make-proto.pl -R '^(_|^C)' -E HX509_LIB -q -P comment -o hx509-protos.h $(dist_libhx509_la_SOURCES) || rm -f hx509-protos.h
134 $(srcdir)/hx509-private.h:
135 cd $(srcdir) && perl ../../cf/make-proto.pl -q -P comment -p hx509-private.h $(dist_libhx509_la_SOURCES) || rm -f hx509-private.h
137 dist_include_HEADERS = hx509.h hx509-protos.h
138 nodist_include_HEADERS = hx509_err.h
140 SLC = $(top_builddir)/lib/sl/slc
142 bin_PROGRAMS = hxtool
144 hxtool-commands.c hxtool-commands.h: hxtool-commands.in $(SLC)
145 $(SLC) $(srcdir)/hxtool-commands.in
147 dist_hxtool_SOURCES = hxtool.c
148 nodist_hxtool_SOURCES = hxtool-commands.c hxtool-commands.h
150 $(hxtool_OBJECTS): hxtool-commands.h
152 hxtool_CPPFLAGS = $(INCLUDE_hcrypto)
155 $(top_builddir)/lib/asn1/libasn1.la \
158 $(top_builddir)/lib/sl/libsl.la
160 CLEANFILES = $(BUILT_SOURCES) \
161 $(gen_files_ocsp) ocsp_asn1_files ocsp_asn1.h* \
162 $(gen_files_pkcs10) pkcs10_asn1_files pkcs10_asn1.h* \
163 $(gen_files_crmf) crmf_asn1_files crmf_asn1.h* \
165 hxtool-commands.c hxtool-commands.h *.tmp \
169 sd.data sd.data.out \
170 ev.data ev.data.out \
171 cert-null.pem cert-sub-ca2.pem \
172 cert-ee.pem cert-ca.pem \
173 cert-sub-ee.pem cert-sub-ca.pem \
174 cert-proxy.der cert-ca.der cert-ee.der pkcs10-request.der \
175 wca.pem wuser.pem wdc.pem wcrl.crl \
176 random-data statfile crl.crl \
177 test p11dbg.log pkcs11.cfg \
181 @echo "cleaning PKITS" ; rm -rf PKITS_data
187 check_SCRIPTS = $(SCRIPT_TESTS)
188 check_PROGRAMS = $(PROGRAM_TESTS) test_soft_pkcs11
192 test_soft_pkcs11_LDADD = libhx509.la
193 test_soft_pkcs11_CPPFLAGS = -I$(srcdir)/ref
195 TESTS = $(SCRIPT_TESTS) $(PROGRAM_TESTS)
217 do_subst = sed -e 's,[@]srcdir[@],$(srcdir),g' \
218 -e 's,[@]objdir[@],$(top_builddir)/lib/hx509,g' \
219 -e 's,[@]egrep[@],$(EGREP),g'
221 test_ca: test_ca.in Makefile
222 $(do_subst) < $(srcdir)/test_ca.in > test_ca.tmp
224 mv test_ca.tmp test_ca
226 test_cert: test_cert.in Makefile
227 $(do_subst) < $(srcdir)/test_cert.in > test_cert.tmp
228 chmod +x test_cert.tmp
229 mv test_cert.tmp test_cert
231 test_chain: test_chain.in Makefile
232 $(do_subst) < $(srcdir)/test_chain.in > test_chain.tmp
233 chmod +x test_chain.tmp
234 mv test_chain.tmp test_chain
236 test_cms: test_cms.in Makefile
237 $(do_subst) < $(srcdir)/test_cms.in > test_cms.tmp
238 chmod +x test_cms.tmp
239 mv test_cms.tmp test_cms
241 test_crypto: test_crypto.in Makefile
242 $(do_subst) < $(srcdir)/test_crypto.in > test_crypto.tmp
243 chmod +x test_crypto.tmp
244 mv test_crypto.tmp test_crypto
246 test_nist: test_nist.in Makefile
247 $(do_subst) < $(srcdir)/test_nist.in > test_nist.tmp
248 chmod +x test_nist.tmp
249 mv test_nist.tmp test_nist
251 test_nist2: test_nist2.in Makefile
252 $(do_subst) < $(srcdir)/test_nist2.in > test_nist2.tmp
253 chmod +x test_nist2.tmp
254 mv test_nist2.tmp test_nist2
256 test_pkcs11: test_pkcs11.in Makefile
257 $(do_subst) < $(srcdir)/test_pkcs11.in > test_pkcs11.tmp
258 chmod +x test_pkcs11.tmp
259 mv test_pkcs11.tmp test_pkcs11
261 test_java_pkcs11: test_java_pkcs11.in Makefile
262 $(do_subst) < $(srcdir)/test_java_pkcs11.in > test_java_pkcs11.tmp
263 chmod +x test_java_pkcs11.tmp
264 mv test_java_pkcs11.tmp test_java_pkcs11
266 test_nist_cert: test_nist_cert.in Makefile
267 $(do_subst) < $(srcdir)/test_nist_cert.in > test_nist_cert.tmp
268 chmod +x test_nist_cert.tmp
269 mv test_nist_cert.tmp test_nist_cert
271 test_nist_pkcs12: test_nist_pkcs12.in Makefile
272 $(do_subst) < $(srcdir)/test_nist_pkcs12.in > test_nist_pkcs12.tmp
273 chmod +x test_nist_pkcs12.tmp
274 mv test_nist_pkcs12.tmp test_nist_pkcs12
276 test_req: test_req.in Makefile
277 $(do_subst) < $(srcdir)/test_req.in > test_req.tmp
278 chmod +x test_req.tmp
279 mv test_req.tmp test_req
281 test_windows: test_windows.in Makefile
282 $(do_subst) < $(srcdir)/test_windows.in > test_windows.tmp
283 chmod +x test_windows.tmp
284 mv test_windows.tmp test_windows
286 test_query: test_query.in Makefile
287 $(do_subst) < $(srcdir)/test_query.in > test_query.tmp
288 chmod +x test_query.tmp
289 mv test_query.tmp test_query
306 test_nist_pkcs12.in \
308 test_java_pkcs11.in \
312 tst-crypto-available1 \
313 tst-crypto-available2 \
314 tst-crypto-available3 \
323 data/secp160r1TestCA.cert.pem \
324 data/secp160r1TestCA.key.pem \
325 data/secp160r1TestCA.pem \
326 data/secp160r2TestClient.cert.pem \
327 data/secp160r2TestClient.key.pem \
328 data/secp160r2TestClient.pem \
329 data/secp160r2TestServer.cert.pem \
330 data/secp160r2TestServer.key.pem \
331 data/secp160r2TestServer.pem \
332 data/bleichenbacher-bad.pem \
333 data/bleichenbacher-good.pem \
334 data/bleichenbacher-sf-pad-correct.pem \
347 data/no-proxy-test.crt \
348 data/no-proxy-test.key \
351 data/ocsp-resp1-2.der \
352 data/ocsp-resp1-3.der \
353 data/ocsp-resp1-ca.der \
354 data/ocsp-resp1-keyhash.der \
355 data/ocsp-resp1-ocsp-no-cert.der \
356 data/ocsp-resp1-ocsp.der \
357 data/ocsp-resp1.der \
358 data/ocsp-resp2.der \
359 data/ocsp-responder.crt \
360 data/ocsp-responder.key \
362 data/pkinit-proxy-chain.crt \
363 data/pkinit-proxy.crt \
364 data/pkinit-proxy.key \
370 data/proxy-level-test.crt \
371 data/proxy-level-test.key \
372 data/proxy-test.crt \
373 data/proxy-test.key \
374 data/proxy10-child-test.crt \
375 data/proxy10-child-test.key \
376 data/proxy10-child-child-test.crt \
377 data/proxy10-child-child-test.key \
378 data/proxy10-test.crt \
379 data/proxy10-test.key \
382 data/sf-class2-root.pem \
389 data/test-ds-only.crt \
390 data/test-ds-only.key \
391 data/test-enveloped-aes-128 \
392 data/test-enveloped-aes-256 \
393 data/test-enveloped-des \
394 data/test-enveloped-des-ede3 \
395 data/test-enveloped-rc2-128 \
396 data/test-enveloped-rc2-40 \
397 data/test-enveloped-rc2-64 \
398 data/test-ke-only.crt \
399 data/test-ke-only.key \
402 data/test-signed-data \
403 data/test-signed-data-noattr \
404 data/test-signed-data-noattr-nocerts \
405 data/test-signed-sha-1 \
406 data/test-signed-sha-256 \
407 data/test-signed-sha-512 \
408 data/test.combined.crt \
412 data/yutaka-pad-broken-ca.pem \
413 data/yutaka-pad-broken-cert.pem \
414 data/yutaka-pad-ok-ca.pem \
415 data/yutaka-pad-ok-cert.pem \