corrected copyright notices
[gnutls.git] / src / Makefile.am
blob5aebf206559a8ac04f3aa9e87ec70d78fcd97c4b
1 ## Process this file with automake to produce Makefile.in
2 # Copyright (C) 2000-2012 Free Software Foundation, Inc.
4 # This file is part of GnuTLS.
6 # This file is free software; you can redistribute it and/or modify it
7 # under the terms of the GNU General Public License as published by
8 # the Free Software Foundation; either version 3 of the License, or
9 # (at your option) any later version.
11 # This file is distributed in the hope that it will be useful, but
12 # WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14 # General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with this file; if not, write to the Free Software Foundation,
18 # Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
20 SUBDIRS =
22 if ENABLE_CRYWRAP
23 SUBDIRS += crywrap
24 endif
26 if NEED_LIBOPTS
27 SUBDIRS += libopts
28 endif
30 EXTRA_DIST = args-std.def
32 AM_CFLAGS = $(WARN_CFLAGS) $(WERROR_CFLAGS)
33 AM_CPPFLAGS = \
34         -I$(srcdir)/../gl                       \
35         -I$(builddir)/../gl                     \
36         -I$(builddir)/../lib/includes           \
37         -I$(srcdir)/../lib/includes             \
38         -I$(srcdir)/../libdane/includes         \
39         -I$(srcdir)/../extra/includes   \
40         $(LIBOPTS_CFLAGS)
42 bin_PROGRAMS = gnutls-serv gnutls-cli psktool gnutls-cli-debug certtool
43 if ENABLE_SRP
44 bin_PROGRAMS += srptool
45 endif
46 if ENABLE_OCSP
47 bin_PROGRAMS += ocsptool
48 endif
50 bin_PROGRAMS += danetool
52 if ENABLE_TROUSERS
53 bin_PROGRAMS += tpmtool
54 endif
56 if ENABLE_PKCS11
57 bin_PROGRAMS += p11tool
58 endif
60 noinst_LTLIBRARIES =
62 gnutls_serv_SOURCES =           \
63   list.h serv.c                 \
64   udp-serv.c udp-serv.h         \
65   socket.c socket.h             \
66   common.h common.c             \
67   certtool-common.h 
68 gnutls_serv_LDADD = ../lib/libgnutls.la
69 gnutls_serv_LDADD += libcmd-serv.la ../gl/libgnu.la
70 gnutls_serv_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
71 gnutls_serv_LDADD += $(LIBSOCKET) $(GETADDRINFO_LIB)
72 noinst_LTLIBRARIES += libcmd-serv.la
73 libcmd_serv_la_CFLAGS =
74 libcmd_serv_la_SOURCES = serv-args.def serv-args.c serv-args.h
76 if ENABLE_SRP
77 srptool_SOURCES = srptool.c
78 srptool_LDADD = ../lib/libgnutls.la libcmd-srp.la ../gl/libgnu.la 
79 srptool_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
80 noinst_LTLIBRARIES += libcmd-srp.la
81 libcmd_srp_la_CFLAGS =
82 libcmd_srp_la_SOURCES = srptool-args.def srptool-args.c srptool-args.h
83 endif
85 if ENABLE_OCSP
86 ocsptool_SOURCES = ocsptool.c ocsptool-common.h ocsptool-common.c \
87         socket.c socket.h
88 ocsptool_LDADD = ../lib/libgnutls.la libcmd-ocsp.la ../gl/libgnu.la 
89 ocsptool_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL) $(GETADDRINFO_LIB)
90 noinst_LTLIBRARIES += libcmd-ocsp.la
91 libcmd_ocsp_la_CFLAGS =
92 libcmd_ocsp_la_SOURCES = ocsptool-args.def ocsptool-args.h ocsptool-args.c
93 endif
95 psktool_SOURCES = psk.c
96 psktool_LDADD = ../lib/libgnutls.la libcmd-psk.la ../gl/libgnu.la 
97 psktool_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
98 noinst_LTLIBRARIES += libcmd-psk.la
99 libcmd_psk_la_CFLAGS = 
100 libcmd_psk_la_SOURCES = psk-args.def psk-args.c psk-args.h
102 BENCHMARK_SRCS = benchmark-cipher.c benchmark.c benchmark.h benchmark-tls.c
104 gnutls_cli_SOURCES = cli.c common.h common.c \
105         socket.c socket.h ocsptool-common.c \
106         $(BENCHMARK_SRCS)
107 gnutls_cli_LDADD = ../lib/libgnutls.la
108 if ENABLE_DANE
109 gnutls_cli_LDADD += ../libdane/libgnutls-dane.la
110 endif
111 gnutls_cli_LDADD += libcmd-cli.la ../gl/libgnu.la $(LIBOPTS_LDADD) $(LTLIBINTL)
112 gnutls_cli_LDADD += $(LIBSOCKET) $(GETADDRINFO_LIB) $(LIB_CLOCK_GETTIME) \
113          $(SERVENT_LIB)
114 noinst_LTLIBRARIES += libcmd-cli.la
115 libcmd_cli_la_CFLAGS = 
116 libcmd_cli_la_SOURCES = cli-args.def cli-args.c cli-args.h
118 gnutls_cli_debug_SOURCES = cli-debug.c tests.h tests.c \
119                 socket.c socket.h common.h common.c
120 gnutls_cli_debug_LDADD = ../lib/libgnutls.la libcmd-cli-debug.la 
121 gnutls_cli_debug_LDADD += ../gl/libgnu.la
122 gnutls_cli_debug_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
123 gnutls_cli_debug_LDADD += $(LIBSOCKET) $(GETADDRINFO_LIB)
124 noinst_LTLIBRARIES += libcmd-cli-debug.la
125 libcmd_cli_debug_la_CFLAGS =
126 libcmd_cli_debug_la_SOURCES = cli-debug-args.def cli-debug-args.c cli-debug-args.h
128 #certtool
130 certtool_SOURCES = certtool.c dh.c certtool-common.c certtool-extras.c common.c
131 certtool_LDADD = ../lib/libgnutls.la 
132 certtool_LDADD += libcmd-certtool.la ../gl/libgnu.la
134 noinst_LTLIBRARIES += libcmd-certtool.la
135 libcmd_certtool_la_CFLAGS =
136 libcmd_certtool_la_SOURCES = certtool-args.c certtool-args.def certtool-args.h  \
137         certtool-cfg.h certtool-cfg.c
138 libcmd_certtool_la_LIBADD = ../gl/libgnu.la ../lib/libgnutls.la
139 libcmd_certtool_la_LIBADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
140 libcmd_certtool_la_LIBADD += $(LTLIBREADLINE)
141 libcmd_certtool_la_LIBADD += $(INET_PTON_LIB)
143 danetool_SOURCES = danetool.c certtool-common.c certtool-extras.c common.c
144 danetool_LDADD = ../lib/libgnutls.la 
145 danetool_LDADD += libcmd-danetool.la ../gl/libgnu.la
146 if ENABLE_DANE
147 danetool_LDADD += ../libdane/libgnutls-dane.la
148 endif
150 noinst_LTLIBRARIES += libcmd-danetool.la
151 libcmd_danetool_la_CFLAGS =
152 libcmd_danetool_la_SOURCES = danetool-args.c danetool-args.def danetool-args.h \
153         certtool-cfg.h certtool-cfg.c
154 libcmd_danetool_la_LIBADD = ../gl/libgnu.la ../lib/libgnutls.la
155 libcmd_danetool_la_LIBADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
156 libcmd_danetool_la_LIBADD += $(LTLIBREADLINE)
157 libcmd_danetool_la_LIBADD += $(INET_PTON_LIB)
159 # p11 tool
160 if ENABLE_PKCS11
162 p11tool_SOURCES = p11tool-args.def p11tool.c pkcs11.c certtool-common.c \
163         certtool-extras.c p11tool.h common.c
164 p11tool_LDADD = ../lib/libgnutls.la
165 p11tool_LDADD += libcmd-p11tool.la ../gl/libgnu.la
166 p11tool_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
168 noinst_LTLIBRARIES += libcmd-p11tool.la
169 libcmd_p11tool_la_CFLAGS =
170 libcmd_p11tool_la_SOURCES = p11tool-args.def p11tool-args.c p11tool-args.h \
171         certtool-cfg.h certtool-cfg.c
172 libcmd_p11tool_la_LIBADD = ../gl/libgnu.la ../lib/libgnutls.la
173 libcmd_p11tool_la_LIBADD += $(LTLIBREADLINE) $(INET_PTON_LIB)
175 endif # ENABLE_PKCS11
177 if ENABLE_TROUSERS
179 tpmtool_SOURCES = tpmtool-args.def tpmtool.c certtool-common.c certtool-extras.c common.c
180 tpmtool_LDADD = ../lib/libgnutls.la
181 tpmtool_LDADD += libcmd-tpmtool.la ../gl/libgnu.la
182 tpmtool_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
184 noinst_LTLIBRARIES += libcmd-tpmtool.la
185 libcmd_tpmtool_la_CFLAGS =
186 libcmd_tpmtool_la_SOURCES = tpmtool-args.def tpmtool-args.c tpmtool-args.h \
187         certtool-cfg.h certtool-cfg.c
188 libcmd_tpmtool_la_LIBADD = ../gl/libgnu.la ../lib/libgnutls.la
189 libcmd_tpmtool_la_LIBADD += $(LTLIBREADLINE) $(INET_PTON_LIB)
191 endif # ENABLE_TROUSERS
193 BUILT_SOURCES = ocsptool-args.c p11tool-args.c psk-args.c cli-debug-args.c \
194                 cli-args.c serv-args.c srptool-args.c certtool-args.c
196 danetool-args.c: $(srcdir)/args-std.def $(srcdir)/danetool-args.def
197         -autogen danetool-args.def
198 ocsptool-args.c: $(srcdir)/args-std.def $(srcdir)/ocsptool-args.def
199         -autogen ocsptool-args.def
200 tpmtool-args.c: $(srcdir)/args-std.def $(srcdir)/tpmtool-args.def
201         -autogen tpmtool-args.def
202 p11tool-args.c: $(srcdir)/args-std.def $(srcdir)/p11tool-args.def
203         -autogen p11tool-args.def
204 psk-args.c: $(srcdir)/args-std.def $(srcdir)/psk-args.def
205         -autogen psk-args.def
206 cli-debug-args.c: $(srcdir)/args-std.def $(srcdir)/cli-debug-args.def
207         -autogen cli-debug-args.def
208 cli-args.c: $(srcdir)/args-std.def $(srcdir)/cli-args.def
209         -autogen cli-args.def
210 serv-args.c: $(srcdir)/args-std.def $(srcdir)/serv-args.def
211         -autogen serv-args.def
212 srptool-args.c: $(srcdir)/args-std.def $(srcdir)/srptool-args.def
213         -autogen srptool-args.def
214 certtool-args.c: $(srcdir)/args-std.def $(srcdir)/certtool-args.def
215         -autogen certtool-args.def