50f1c3452d4dbc8eac7f2e37d72aa3f9744716c8
[openssl.git] / demos / signature / Makefile
1 #
2 # To run the demos when linked with a shared library (default):
3 #
4 #    LD_LIBRARY_PATH=../.. ./EVP_EC_Signature_demo
5 #    LD_LIBRARY_PATH=../.. ./EVP_DSA_Signature_demo
6 #    LD_LIBRARY_PATH=../.. ./EVP_ED_Signature_demo
7 #    LD_LIBRARY_PATH=../.. ./rsa_pss_direct
8 #    LD_LIBRARY_PATH=../.. ./rsa_pss_hash
9
10 CFLAGS = -I../../include -g -Wall
11 LDFLAGS = -L../..
12 LDLIBS = -lcrypto
13
14 TESTS=EVP_EC_Signature_demo EVP_DSA_Signature_demo EVP_ED_Signature_demo rsa_pss_direct rsa_pss_hash
15
16 all: $(TESTS)
17
18 %.o: %.c
19         $(CC) $(CFLAGS) -c $<
20
21 EVP_EC_Signature_demo: EVP_EC_Signature_demo.o
22 EVP_DSA_Signature_demo: EVP_DSA_Signature_demo.o
23 EVP_ED_Signature_demo: EVP_ED_Signature_demo.o
24 rsa_pss_direct: rsa_pss_direct.o
25 rsa_pss_hash: rsa_pss_hash.o
26
27 clean:
28         $(RM) *.o $(TESTS)
29
30 .PHONY: test
31 test: all
32         @echo "\nSignature tests:"
33         @set -e; for tst in $(TESTS); do \
34                 echo "\n"$$tst; \
35                 LD_LIBRARY_PATH=../.. ./$$tst; \
36         done