A small step for GnuPG but a huge leap for error codes.
[gnupg.git] / g10 / Makefile.am
1 # Copyright (C) 1998, 1999, 2000, 2001, 2002,
2 #               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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
19
20 ## Process this file with automake to produce Makefile.in
21
22 INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/intl
23 EXTRA_DIST = options.skel
24 # it seems that we can't use this with automake 1.5
25 #OMIT_DEPENDENCIES = zlib.h zconf.h
26 libexecdir = @libexecdir@/@PACKAGE@
27 # FIXME: Windows support currently not enabled
28 #if ! HAVE_DOSISH_SYSTEM
29 #AM_CFLAGS = -DGNUPG_LIBEXECDIR="\"$(libexecdir)\""
30 #endif
31 needed_libs = ../cipher/libcipher.a ../mpi/libmpi.a ../util/libutil.a
32
33 #noinst_PROGRAMS = gpgd
34 bin_PROGRAMS = gpg gpgv
35
36 common_source =  \
37               global.h gpg.h    \
38               build-packet.c    \
39               compress.c        \
40               filter.h          \
41               free-packet.c     \
42               getkey.c          \
43               keydb.c keydb.h    \
44               keyring.c keyring.h \
45               seskey.c          \
46               kbnode.c          \
47               main.h            \
48               mainproc.c        \
49               armor.c           \
50               mdfilter.c        \
51               textfilter.c      \
52               progress.c        \
53               misc.c            \
54               options.h         \
55               openfile.c        \
56               keyid.c           \
57               packet.h          \
58               parse-packet.c    \
59               comment.c         \
60               status.c          \
61               status.h          \
62               plaintext.c       \
63               sig-check.c       \
64               keylist.c         \
65               signal.c
66
67 gpg_SOURCES  = g10.c            \
68               $(common_source)  \
69               pkclist.c         \
70               skclist.c         \
71               pubkey-enc.c      \
72               passphrase.c      \
73               seckey-cert.c     \
74               encr-data.c       \
75               cipher.c          \
76               encode.c          \
77               sign.c            \
78               verify.c          \
79               revoke.c          \
80               decrypt.c         \
81               keyedit.c         \
82               dearmor.c         \
83               import.c          \
84               export.c          \
85               trustdb.c         \
86               trustdb.h         \
87               tdbdump.c         \
88               tdbio.c           \
89               tdbio.h           \
90               delkey.c          \
91               keygen.c          \
92               pipemode.c        \
93               helptext.c        \
94               keyserver.c       \
95               keyserver-internal.h \
96               photoid.c photoid.h \
97               call-agent.c call-agent.h \
98               exec.c exec.h
99
100 gpgv_SOURCES = gpgv.c           \
101               $(common_source)  \
102               verify.c          
103
104 #gpgd_SOURCES = gpgd.c \
105 #              ks-proto.h \
106 #              ks-proto.c \
107 #              ks-db.c \
108 #              ks-db.h \
109 #              $(common_source)
110
111 LDADD =  $(needed_libs) @INTLLIBS@ @CAPLIBS@ @ZLIBS@
112 gpg_LDADD = $(LDADD) @DLLIBS@ @EGDLIBS@ -lgpg-error
113
114 $(PROGRAMS): $(needed_libs)
115
116 install-data-local:
117         $(mkinstalldirs) $(DESTDIR)$(pkgdatadir)
118         $(INSTALL_DATA) $(srcdir)/options.skel \
119                                 $(DESTDIR)$(pkgdatadir)/options.skel
120         @set -e;\
121          if test -f $(DESTDIR)$(bindir)/gpgm ; then \
122            echo "removing obsolete gpgm binary" ;   \
123            rm $(DESTDIR)$(bindir)/gpgm ;            \
124          fi