doc/
[gpgme.git] / gpgme / Makefile.am
1 # Copyright (C) 2000 Werner Koch (dd9jn)
2 # Copyright (C) 2001, 2002, 2003 g10 Code GmbH
3
4 # This file is part of GPGME.
5
6 # GPGME 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 # GPGME 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 EXTRA_DIST = gpgme-config.in gpgme.m4 mkstatus libgpgme.vers
23 BUILT_SOURCES = status-table.h
24 MOSTLYCLEANFILES = status-table.h
25 bin_SCRIPTS = gpgme-config
26 m4datadir = $(datadir)/aclocal
27 m4data_DATA = gpgme.m4
28 include_HEADERS = gpgme.h
29 lib_LTLIBRARIES = libgpgme.la
30
31 if HAVE_LD_VERSION_SCRIPT
32 libgpgme_version_script_cmd = -Wl,--version-script=$(srcdir)/libgpgme.vers
33 else
34 libgpgme_version_script_cmd =
35 endif
36
37 libgpgme_la_LDFLAGS = $(libgpgme_version_script_cmd) -version-info \
38       @LIBGPGME_LT_CURRENT@:@LIBGPGME_LT_REVISION@:@LIBGPGME_LT_AGE@
39
40 if BUILD_ASSUAN
41 AM_CPPFLAGS = -I$(top_srcdir)/assuan
42 assuan_libobjs = ../assuan/libassuan.la
43 else
44 assuan_libobjs =
45 endif
46
47 if HAVE_PTHREAD
48 ath_components_pthread = ath-pthread.c
49 else
50 ath_components_pthread =
51 endif
52 if HAVE_PTH
53 ath_components_pth = ath-pth.c
54 else
55 ath_components_pth =
56 endif
57 ath_components = ath.h ath.c ${ath_components_pthread} ${ath_components_pth}
58
59 if HAVE_DOSISH_SYSTEM
60 system_components = w32-util.c w32-sema.c w32-io.c
61 else
62 system_components = ${ath_components} posix-util.c posix-sema.c posix-io.c
63 endif
64
65 if HAVE_GPGSM
66 gpgsm_components = engine-gpgsm.c
67 else
68 gpgsm_components =
69 endif
70
71 libgpgme_la_SOURCES =                                                   \
72         gpgme.h util.h conversion.c context.h ops.h                     \
73         data.h data.c data-fd.c data-stream.c data-mem.c data-user.c    \
74         data-compat.c                                                   \
75         signers.c                                                       \
76         wait.c wait-global.c wait-private.c wait-user.c wait.h          \
77         op-support.c                                                    \
78         encrypt.c encrypt-sign.c decrypt.c decrypt-verify.c verify.c    \
79         sign.c passphrase.c progress.c                                  \
80         key.c keylist.c trust-item.c trustlist.c                        \
81         import.c export.c genkey.c delete.c edit.c                      \
82         engine.h engine-backend.h engine.c rungpg.c status-table.h      \
83         ${gpgsm_components} sema.h io.h ${system_components}            \
84         debug.c debug.h gpgme.c version.c error.c
85
86 libgpgme_la_DEPENDENCIES = ${assuan_libobjs} @LTLIBOBJS@ \
87         $(srcdir)/libgpgme.vers
88
89 libgpgme_la_LIBADD = ${assuan_libobjs} @LTLIBOBJS@
90
91 status-table.h : gpgme.h
92         $(srcdir)/mkstatus < $(srcdir)/gpgme.h > status-table.h