summaryrefslogtreecommitdiff
path: root/gpgscm/Makefile.am
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2017-11-28 16:17:23 +0100
committerWerner Koch <wk@gnupg.org>2017-11-28 16:17:23 +0100
commit930d27ba6b1205395add0c79139e62355a1d5b62 (patch)
treece4212ea280360d05120828f14648ace60baa0c4 /gpgscm/Makefile.am
parent4a2538e69dd35377bce0fb584f72322c69a111b3 (diff)
downloadlibgpg-error-930d27ba6b1205395add0c79139e62355a1d5b62.tar.gz
gpgscm: Some adjustments for use in gpgrt.
* gpgscm/Makefile.am: Remove cruft leftover from GnuPG. Link to the just build libgpg-error. * gpgscm/private.h: Include gpgrt.h and provide i18n macros. (xfree, xtrymalloc, xtrycalloc, xtryrealloc): New macros. (xmalloc, xstrdup): New inline functions. * gpgscm/main.c: Remove inclusion of gcrypt.h and gpg-error.h. Remove all other gnupg specific headers. (opts, parse_arguments): Temporary comment out. (main): Adjust for use with gpgrt. Temporary comment out some stuff. * gpgscm/ffi-private.h: Include local gpgrt.h instead of gpg-error.h. * gpgscm/ffi.h: Ditto. * gpgscm/ffi.c: Remove gpg-error.h and headers from GnuPG. (do_getenv): Use gpgrt_getenv. (do_setenv): Use gpgrt_setenv. (do_mkdtemp): Temporary return an error. (unlink_recursively): Use gpgrt_bsprintf. (do_getcwd): Use gpgrt_getcwd. (do_mkdir): Use gpgrt_mkdir. (do_get_isotime): Temporary return an error. (do_get_time): Directly use time(). -- Note that this does not yet compile because the spawn functions from GnuPG are missing. There are two other problems as well: - We don't have GnuPG's isotime fucntions. We need to see whether we want to support them in gpgrt. That might be useful in libksba. - gpgrt_mkdtemp does not work. We do not want to link to Libgcrypt, which is the way mkdtemp was written for GnuPG. We should get a more straight implementation. Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'gpgscm/Makefile.am')
-rw-r--r--gpgscm/Makefile.am17
1 files changed, 4 insertions, 13 deletions
diff --git a/gpgscm/Makefile.am b/gpgscm/Makefile.am
index 59e1924..43741f2 100644
--- a/gpgscm/Makefile.am
+++ b/gpgscm/Makefile.am
@@ -31,9 +31,6 @@ EXTRA_DIST = \
gnupg.scm \
time.scm
-AM_CPPFLAGS = -I$(top_srcdir)/common
-include $(top_srcdir)/am/cmacros.am
-
AM_CFLAGS =
CLEANFILES =
@@ -41,23 +38,17 @@ CLEANFILES =
bin_PROGRAMS = gpgscm
noinst_PROGRAMS = t-child
-common_libs = ../$(libcommon)
-commonpth_libs = ../$(libcommonpth)
-
-gpgscm_CFLAGS = -imacros scheme-config.h \
- $(LIBGCRYPT_CFLAGS) $(LIBASSUAN_CFLAGS) $(GPG_ERROR_CFLAGS)
+gpgscm_CFLAGS = -imacros scheme-config.h
gpgscm_SOURCES = main.c private.h ffi.c ffi.h ffi-private.h \
scheme-config.h scheme.c scheme.h scheme-private.h \
opdefines.h small-integers.h
-gpgscm_LDADD = $(LDADD) $(common_libs) \
- $(NETLIBS) $(LIBICONV) $(LIBREADLINE) $(LIBINTL) \
- $(LIBGCRYPT_LIBS) $(GPG_ERROR_LIBS)
+gpgscm_LDADD = $(LDADD) $(LIBREADLINE) ../src/libgpg-error.la $(LTLIBINTL)
t_child_SOURCES = t-child.c
# Make sure that all libs are build before we use them. This is
-# important for things like make -j2.
-$(PROGRAMS): $(common_libs)
+# important for parallel builds (i.e. make -j2).
+$(PROGRAMS): ../src/libgpg-error.la
check-local: gpgscm$(EXEEXT) t-child$(EXEEXT)
EXEEXT=$(EXEEXT) GPGSCM_PATH=$(srcdir) \