Makefile 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. #
  2. # To run the demos when linked with a shared library (default) ensure that
  3. # libcrypto is on the library path. For example:
  4. #
  5. # LD_LIBRARY_PATH=../.. ./EVP_PKEY_EC_keygen
  6. TESTS = EVP_PKEY_EC_keygen \
  7. EVP_PKEY_RSA_keygen \
  8. EVP_PKEY_DSA_keygen \
  9. EVP_PKEY_DSA_paramgen \
  10. EVP_PKEY_DSA_paramvalidate \
  11. EVP_PKEY_DSA_paramfromdata
  12. CFLAGS = -I../../include -g -Wall
  13. LDFLAGS = -L../..
  14. LDLIBS = -lcrypto
  15. all: $(TESTS)
  16. EVP_PKEY_DSA_keygen.o: EVP_PKEY_DSA_keygen.c dsa.inc
  17. EVP_PKEY_DSA_paramgen.o: EVP_PKEY_DSA_paramgen.c dsa.inc
  18. EVP_PKEY_DSA_paramvalidate.o: EVP_PKEY_DSA_paramvalidate.c dsa.inc
  19. EVP_PKEY_DSA_paramfromdata.o: EVP_PKEY_DSA_paramfromdata.c dsa.inc
  20. EVP_PKEY_EC_keygen: EVP_PKEY_EC_keygen.o
  21. EVP_PKEY_RSA_keygen: EVP_PKEY_RSA_keygen.o
  22. EVP_PKEY_DSA_keygen: EVP_PKEY_DSA_keygen.o
  23. EVP_PKEY_DSA_paramgen: EVP_PKEY_DSA_paramgen.o
  24. EVP_PKEY_DSA_paramvalidate: EVP_PKEY_DSA_paramvalidate.o
  25. EVP_PKEY_DSA_paramfromdata: EVP_PKEY_DSA_paramfromdata.o
  26. $(TESTS):
  27. $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $< $(LDLIBS)
  28. clean:
  29. $(RM) *.o $(TESTS)
  30. .PHONY: test
  31. test: all
  32. @echo "\nPKEY tests:"
  33. @set -e; for tst in $(TESTS); do \
  34. echo "\n"$$tst; \
  35. LD_LIBRARY_PATH=../.. ./$$tst; \
  36. done