]> git.ipfire.org Git - thirdparty/openssl.git/blame - demos/encrypt/Makefile
demos: tidy up makefiles, fix warnings
[thirdparty/openssl.git] / demos / encrypt / Makefile
CommitLineData
35530b11 1#
86db9588
JM
2# To run the demos when linked with a shared library (default) ensure
3# that libcrypto is on the library path. For example:
35530b11
SL
4#
5# LD_LIBRARY_PATH=../.. ./rsa_encrypt
6
86db9588 7TESTS = rsa_encrypt
35530b11 8
86db9588
JM
9CFLAGS = -I../../include -g -Wall
10LDFLAGS = -L../..
11LDLIBS = -lcrypto
66f4782f 12
13all: $(TESTS)
35530b11 14
67bfdfa1 15rsa_encrypt: rsa_encrypt.o
35530b11 16
86db9588
JM
17$(TESTS):
18 $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $< $(LDLIBS)
19
35530b11 20clean:
66f4782f 21 $(RM) *.o $(TESTS)
22
23.PHONY: test
24test: all
25 @echo "\nEncrypt tests:"
26 @set -e; for tst in $(TESTS); do \
27 echo "\n"$$tst; \
28 LD_LIBRARY_PATH=../.. ./$$tst; \
29 done