noinst_LIBRARIES=libpkcs7.a
EXTRA_PROGRAMS=sign verify
INCLUDES=-I$(top_srcdir)/crypto

libpkcs7_a_SOURCES=pk7_doit.c pk7_lib.c pkcs7err.c

sign_SOURCES=sign.c
sign_LDFLAGS=-L$(top_builddir)/crypto
sign_LDADD=-lcrypto
sign_DEPENDENCIES=$(top_builddir)/crypto/libcrypto.a

verify_SOURCES=verify.c
verify_LDFLAGS=-L$(top_builddir)/crypto
verify_LDADD=-lcrypto
verify_DEPENDENCIES=$(top_builddir)/crypto/libcrypto.a

EXTRA_DIST=Makefile.ssl README doc mf.p7 p7.tst pk7_dgst.c pk7_enc.c \
	pkcs7.err pkcs7.h server.pem

errors pkcs7err.c pkcs7.h: pkcs7.err
	perl $(top_srcdir)/util/err-ins.pl pkcs7.err pkcs7.h
	perl $(top_srcdir)/crypto/err/err_genc.pl pkcs7.h pkcs7err.c

$(top_builddir)/crypto/libcrypto.a:
	cd $(top_builddir)/crypto; $(MAKE) $(MFLAGS) libcrypto.a
