1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-02 22:46:30 +02:00

Updated from latest NewPG project

This commit is contained in:
Werner Koch 2003-01-09 13:15:07 +00:00
parent c13b76ca6a
commit 29ef9bd0fb
13 changed files with 266 additions and 129 deletions

View file

@ -1,3 +1,19 @@
2002-12-04 Werner Koch <wk@gnupg.org>
* inittests (gpgsm.conf): Fake system time.
2002-10-31 Neal H. Walfield <neal@g10code.de>
* Makefile.am (inittests.stamp): Do not set LD_LIBRARY_PATH here.
(TESTS_ENVIRONMENT): Do it here. And also frob $(LIBGCRYPT_LIBS)
and $(PTH_LIBS).
2002-10-31 Neal H. Walfield <neal@g10code.de>
* asschk.c (die): New macro.
(read_assuan): If in verbose mode, dump the string that was read.
(write_assuan): Be more verbose on failure.
2002-09-04 Neal H. Walfield <neal@g10code.de>
* Makefile.am (inittests.stamp): Do not set LD_LIBRARY_PATH, but

View file

@ -22,7 +22,27 @@
GPGSM = ../sm/gpgsm
# We can't unset a variable here so we unset GPG_AGENT_INFO in runtest
TESTS_ENVIRONMENT = GNUPGHOME=`pwd` LC_ALL=C GPGSM=$(GPGSM) $(srcdir)/runtest
TESTS_ENVIRONMENT = GNUPGHOME=`pwd` LC_ALL=C GPGSM=$(GPGSM) \
LD_LIBRARY_PATH=$$(seen=0; \
for i in $(LDFLAGS) $(LIBGCRYPT_LIBS) $(PTH_LIBS); \
do \
if echo "$$i" | egrep '^-L' >/dev/null 2>&1; \
then \
if test $$seen = 0; \
then \
seen=1; \
else \
printf ":"; \
fi; \
printf "%s" "$${i}" | sed 's/^-L//'; \
fi; \
done; \
if test $$seen != 0 \
&& test x$${LD_LIBRARY_PATH} != x; \
then \
printf ":"; \
fi; \
printf "%s" "$${LD_LIBRARY_PATH}") $(srcdir)/runtest
testscripts = sm-sign+verify sm-verify
@ -53,26 +73,6 @@ clean-local:
srcdir=$(srcdir) $(TESTS_ENVIRONMENT) $(srcdir)/inittests --clean
inittests.stamp: inittests
LD_LIBRARY_PATH=$$(seen=0; \
for i in $(LDFLAGS); \
do \
if echo "$$i" | egrep '^-L' >/dev/null 2>&1; \
then \
if test $$seen = 0; \
then \
seen=1; \
else \
printf ":"; \
fi; \
printf "%s" "$${i}" | sed 's/^-L//'; \
fi; \
done; \
if test $$seen != 0 \
&& test x$${LD_LIBRARY_PATH} != x; \
then \
printf ":"; \
fi; \
printf "%s" "$${LD_LIBRARY_PATH}") \
srcdir=$(srcdir) $(TESTS_ENVIRONMENT) $(srcdir)/inittests
srcdir=$(srcdir) $(TESTS_ENVIRONMENT) $(srcdir)/inittests
echo timestamp >./inittests.stamp

View file

@ -188,6 +188,8 @@ die (const char *format, ...)
exit (1);
}
#define die(format, args...) (die) ("%s: " format, __FUNCTION__ , ##args)
static void
err (const char *format, ...)
{
@ -282,6 +284,16 @@ read_assuan (int fd)
}
else
n = read (fd, buf, nleft);
if (opt_verbose)
{
int i;
printf ("%s: read \"", __FUNCTION__);
for (i = 0; i < n; i ++)
putc (buf[i], stdout);
printf ("\"\n");
}
if (n < 0)
{
if (errno == EINTR)
@ -359,7 +371,8 @@ write_assuan (int fd, const char *line)
buffer[n++] = '\n';
if (writen (fd, buffer, n))
die ("sending line to %d failed: %s", fd, strerror (errno));
die ("sending line (\"%s\") to %d failed: %s", buffer, fd,
strerror (errno));
}

View file

@ -73,10 +73,13 @@ for i in ${private_keys}; do
done
# Create the configuration scripts
# Note, die to an expired test certificate, we need to use
# the faked system time option.
cat > gpgsm.conf <<EOF
no-secmem-warning
disable-crl-checks
agent-program ../agent/gpg-agent
faked-system-time 1038835799
EOF
cat > gpg-agent.conf <<EOF