Pth tweaks and improved estream.c
[gnupg.git] / g10 / Makefile.am
index 3137bb8..cc0192c 100644 (file)
@@ -1,5 +1,5 @@
 # Copyright (C) 1998, 1999, 2000, 2001, 2002,
-#               2003  Free Software Foundation, Inc.
+#               2003, 2006  Free Software Foundation, Inc.
 #
 # This file is part of GnuPG.
 #
 # 
 # You should have received a copy of the GNU General Public License
 # along with this program; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
+# USA.
 
 ## Process this file with automake to produce Makefile.in
 
-localedir = $(datadir)/locale
-INCLUDES = -I$(top_srcdir)/common -I$(top_srcdir)/include -I$(top_srcdir)/intl -DLOCALEDIR=\"$(localedir)\"
-
 EXTRA_DIST = options.skel
-# it seems that we can't use this with automake 1.5
-#OMIT_DEPENDENCIES = zlib.h zconf.h
-libexecdir = @libexecdir@/@PACKAGE@
-if ! HAVE_DOSISH_SYSTEM
-AM_CFLAGS = -DGNUPG_LIBEXECDIR="\"$(libexecdir)\""
-endif
-needed_libs = ../common/libcommon.a ../jnlib/libjnlib.a
 
-#noinst_PROGRAMS = gpgd
-bin_PROGRAMS = gpg gpgv
+AM_CPPFLAGS = -I$(top_srcdir)/gl -I$(top_srcdir)/common \
+              -I$(top_srcdir)/include -I$(top_srcdir)/intl 
+
+include $(top_srcdir)/am/cmacros.am
+
+AM_CFLAGS = $(LIBGCRYPT_CFLAGS) $(GPG_ERROR_CFLAGS)
+
+needed_libs = ../gl/libgnu.a ../common/libcommon.a ../jnlib/libjnlib.a
+
+bin_PROGRAMS = gpg2 gpgv2
 
 common_source =  \
-             global.h gpg.h    \
+             gpg.h             \
              build-packet.c    \
              compress.c        \
+             compress-bz2.c    \
              filter.h          \
              free-packet.c     \
              getkey.c          \
@@ -57,7 +57,6 @@ common_source =  \
              keyid.c           \
              packet.h          \
              parse-packet.c    \
-             comment.c         \
              status.c          \
              status.h          \
              plaintext.c       \
@@ -65,7 +64,7 @@ common_source =  \
              keylist.c         \
              pkglue.c pkglue.h 
 
-gpg_SOURCES  = g10.c           \
+gpg2_SOURCES  = gpg.c          \
              $(common_source)  \
              pkclist.c         \
              skclist.c         \
@@ -90,15 +89,15 @@ gpg_SOURCES  = g10.c                \
              tdbio.h           \
              delkey.c          \
              keygen.c          \
-             pipemode.c        \
              helptext.c        \
              keyserver.c       \
              keyserver-internal.h \
              photoid.c photoid.h \
              call-agent.c call-agent.h \
+             card-util.c \
              exec.c exec.h
 
-gpgv_SOURCES = gpgv.c           \
+gpgv2_SOURCES = gpgv.c           \
              $(common_source)  \
              verify.c          
 
@@ -109,18 +108,16 @@ gpgv_SOURCES = gpgv.c           \
 #             ks-db.h \
 #             $(common_source)
 
-LDADD =  $(needed_libs) @INTLLIBS@ @CAPLIBS@ @ZLIBS@ 
-gpg_LDADD = $(LIBGCRYPT_LIBS) $(LDADD) -lassuan -lgpg-error
-gpgv_LDADD = $(LIBGCRYPT_LIBS) $(LDADD) -lassuan -lgpg-error
+LDADD =  $(needed_libs) ../common/libgpgrl.a \
+         $(ZLIBS) $(DNSLIBS) $(LIBREADLINE) \
+         $(LIBINTL) $(CAPLIBS) $(NETLIBS)
+gpg2_LDADD = $(LIBGCRYPT_LIBS) $(LDADD) $(LIBASSUAN_LIBS) $(GPG_ERROR_LIBS)
+gpgv2_LDADD = $(LIBGCRYPT_LIBS) $(LDADD) $(LIBASSUAN_LIBS) $(GPG_ERROR_LIBS)
 
-$(PROGRAMS): $(needed_libs)
+$(PROGRAMS): $(needed_libs) ../common/libgpgrl.a
 
 install-data-local:
        $(mkinstalldirs) $(DESTDIR)$(pkgdatadir)
        $(INSTALL_DATA) $(srcdir)/options.skel \
-                               $(DESTDIR)$(pkgdatadir)/options.skel
-       @set -e;\
-        if test -f $(DESTDIR)$(bindir)/gpgm ; then \
-          echo "removing obsolete gpgm binary" ;   \
-          rm $(DESTDIR)$(bindir)/gpgm ;            \
-        fi
+                               $(DESTDIR)$(pkgdatadir)/gpg-conf.skel
+