summaryrefslogtreecommitdiff
path: root/libextra/Makefile.am
blob: 7a85d67d3d07b728f9542653576cf007bc1cb240 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
DIST_SUBDIRS = openpgp opencdk

INCLUDES = -I$(top_srcdir)/crypto -I$(top_srcdir)/gl -I$(top_srcdir)/lib -I../includes -I$(top_srcdir)/includes -I$(top_srcdir)/lib/minitasn1 $(LIBOPENCDK_CFLAGS) $(LIBGCRYPT_CFLAGS) $(LIBTASN1_CFLAGS) -I$(srcdir)/opencdk -I$(srcdir)/openpgp

bin_SCRIPTS = libgnutls-extra-config

m4datadir = $(datadir)/aclocal
dist_m4data_DATA = libgnutls-extra.m4

# Pkg-config script.
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = gnutls-extra.pc
DISTCLEANFILES = $(pkgconfig_DATA)

EXTRA_DIST = gnutls-extra-api.texi

lib_LTLIBRARIES = libgnutls-extra.la

# OpenSSL

if ENABLE_OPENSSL
lib_LTLIBRARIES += libgnutls-openssl.la

libgnutls_openssl_la_LDFLAGS = -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE)

libgnutls_openssl_la_SOURCES = gnutls_openssl.c openssl_compat.h	\
	openssl_compat.c

libgnutls_openssl_la_LIBADD = ../lib/libgnutls.la ../crypto/libgc.la

if ENABLE_MINITASN1
libgnutls_openssl_la_LIBADD += ../lib/minitasn1/libminitasn1.la
else
libgnutls_openssl_la_LDFLAGS += $(LIBTASN1_LIBS) 
endif
endif

# OpenPGP

if ENABLE_OPENPGP
PGP_COBJECTS = gnutls_openpgp.c openpgp/xml.c \
	openpgp/pgpverify.c openpgp/pgp.c \
	openpgp/extras.c openpgp/compat.c openpgp/privkey.c

if ENABLE_INCLUDED_OPENCDK
SUBDIRS = openpgp opencdk

OPENCDK_COBJECTS = opencdk/new-packet.c opencdk/read-packet.c opencdk/write-packet.c \
	opencdk/main.c 	opencdk/verify.c opencdk/armor.c \
	opencdk/sig-check.c opencdk/sign.c opencdk/keydb.c \
        opencdk/keylist.c opencdk/seskey.c opencdk/pubkey.c opencdk/misc.c \
	opencdk/encrypt.c opencdk/trustdb.c opencdk/kbnode.c \
	opencdk/compress.c opencdk/plaintext.c opencdk/cipher.c \
	opencdk/sym-cipher.c opencdk/stream.c opencdk/keyserver.c \
	opencdk/keygen.c opencdk/md.c
else
SUBDIRS = openpgp
OPENCDK_COBJECTS = 
endif

endif

# LZO

LZO_OBJECTS = 
if ENABLE_INCLUDED_LZO
LZO_OBJECTS += lzoconf.h minilzo.h minilzo.c
endif

COBJECTS_EXTRA = gnutls_extra.c

libgnutls_extra_la_LDFLAGS = -export-symbols-regex '^gnutls.*' \
	-version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \
	$(LIBOPENCDK_LIBS) $(LZO_LIBS)

libgnutls_extra_la_SOURCES = $(COBJECTS_EXTRA) $(LZO_OBJECTS) \
	$(PGP_COBJECTS) $(OPENCDK_COBJECTS) gnutls_extra.h

libgnutls_extra_la_LIBADD = ../lib/libgnutls.la ../gl/libgnu.la


gnutls-extra-api.texi: $(COBJECTS_EXTRA)
	@echo "" > gnutls-extra-api.texi
	@for i in $(COBJECTS_EXTRA); do \
		echo -n "Creating documentation for file $$i... " && \
		../doc/scripts/gdoc -texinfo $$i >> gnutls-extra-api.texi && \
		echo "ok"; \
	done

dist-hook: gnutls-extra-api.texi