Preparing 2.0.1
[gnupg.git] / tools / Makefile.am
1 # Makefile.am - Tools directory
2 #       Copyright (C) 2003 Free Software Foundation, Inc.
3
4 # This file is part of GnuPG.
5
6 # GnuPG is free software; you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation; either version 2 of the License, or
9 # (at your option) any later version.
10
11 # GnuPG is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 # GNU General Public License for more details.
15
16 # You should have received a copy of the GNU General Public License
17 # along with this program; if not, write to the Free Software
18 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
19 # USA.
20
21 EXTRA_DIST = \
22         Manifest watchgnupg.c \
23         addgnupghome gpgsm-gencert.sh \
24         lspgpot mail-signed-keys convert-from-106
25
26
27 AM_CPPFLAGS = -I$(top_srcdir)/gl -I$(top_srcdir)/intl -I$(top_srcdir)/common
28 include $(top_srcdir)/am/cmacros.am
29
30 AM_CFLAGS = $(LIBGCRYPT_CFLAGS) $(GPG_ERROR_CFLAGS) $(LIBASSUAN_CFLAGS)
31
32 sbin_SCRIPTS = addgnupghome
33
34 bin_SCRIPTS = gpgsm-gencert.sh
35 if HAVE_USTAR
36 # bin_SCRIPTS += gpg-zip
37 noinst_SCRIPTS = gpg-zip
38 endif
39
40 if BUILD_SYMCRYPTRUN
41   symcryptrun = symcryptrun
42 else
43   symcryptrun =
44 endif
45
46 bin_PROGRAMS = gpgconf gpg-connect-agent gpgkey2ssh ${symcryptrun} \
47                gpgparsemail
48 if !HAVE_W32_SYSTEM
49 bin_PROGRAMS += watchgnupg
50 endif
51
52 noinst_PROGRAMS = clean-sat mk-tdata make-dns-cert gpgsplit
53
54 common_libs = ../jnlib/libjnlib.a ../common/libcommon.a ../gl/libgnu.a
55 pwquery_libs = ../common/libsimple-pwquery.a
56
57 gpgsplit_LDADD = $(common_libs) $(LIBGCRYPT_LIBS) $(GPG_ERROR_LIBS) $(ZLIBS)
58
59 gpgconf_SOURCES = gpgconf.c gpgconf.h gpgconf-comp.c no-libgcrypt.c
60
61 # jnlib/common sucks in gpg-error, will they, nil they (some compilers
62 # do not eliminate the supposed-to-be-unused-inline-functions).
63 gpgconf_LDADD = $(common_libs) $(LIBINTL) $(GPG_ERROR_LIBS)
64
65 gpgparsemail_SOURCES = gpgparsemail.c rfc822parse.c rfc822parse.h
66 gpgparsemail_LDADD = 
67
68 symcryptrun_SOURCES = symcryptrun.c
69 symcryptrun_LDADD = $(LIBUTIL_LIBS) $(common_libs) $(pwquery_libs) \
70                     $(LIBGCRYPT_LIBS) $(GPG_ERROR_LIBS) $(LIBINTL)
71
72 watchgnupg_SOURCES = watchgnupg.c 
73 watchgnupg_LDADD = $(NETLIBS)
74
75 gpg_connect_agent_SOURCES = gpg-connect-agent.c no-libgcrypt.c
76 gpg_connect_agent_LDADD = $(common_libs) $(LIBASSUAN_LIBS) \
77                           $(GPG_ERROR_LIBS) $(LIBINTL) $(NETLIBS)
78
79 gpgkey2ssh_SOURCES = gpgkey2ssh.c
80 gpgkey2ssh_CFLAGS = $(LIBGCRYPT_CFLAGS) $(GPG_ERROR_CFLAGS)
81 # common sucks in jnlib, via use of BUG() in an inline function, which
82 # some compilers do not eliminate.
83 gpgkey2ssh_LDADD = $(common_libs) \
84                    $(LIBGCRYPT_LIBS) $(GPG_ERROR_LIBS) $(LIBINTL)
85
86
87 # Make sure that all libs are build before we use them.  This is
88 # important for things like make -j2.
89 $(PROGRAMS): $(common_libs) $(pwquery_libs)
90