aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2004-02-18 18:05:38 +0000
committerWerner Koch <[email protected]>2004-02-18 18:05:38 +0000
commitfd8f4ac9f070e748a7a35deb178c40d37e1046f1 (patch)
treec24ea1b1875a2e83c4ebd2f4342e832958737531
parent* gpgsm/t-import.c (check_result): gpgsm does now return info in (diff)
downloadgpgme-fd8f4ac9f070e748a7a35deb178c40d37e1046f1.tar.gz
gpgme-fd8f4ac9f070e748a7a35deb178c40d37e1046f1.zip
* configure.ac: Make the check for funopen fail with just a
warning. * assuan-handler.c (assuan_get_data_fp): Fail with ENOSYS if we can't implement this.
-rw-r--r--ChangeLog5
-rw-r--r--assuan/ChangeLog5
-rw-r--r--assuan/assuan-handler.c5
-rw-r--r--configure.ac23
4 files changed, 29 insertions, 9 deletions
diff --git a/ChangeLog b/ChangeLog
index 30f87496..021a2dfc 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2004-02-18 Werner Koch <[email protected]>
+
+ * configure.ac: Make the check for funopen fail with just a
+ warning.
+
2004-02-11 Werner Koch <[email protected]>
* autogen.sh (check_version): Removed bashism and simplified.
diff --git a/assuan/ChangeLog b/assuan/ChangeLog
index 8a25927e..fc1a18cb 100644
--- a/assuan/ChangeLog
+++ b/assuan/ChangeLog
@@ -1,3 +1,8 @@
+2004-02-18 Werner Koch <[email protected]>
+
+ * assuan-handler.c (assuan_get_data_fp): Fail with ENOSYS if we
+ can't implement this.
+
2004-02-13 Werner Koch <[email protected]>
* assuan-domain-connect.c: Removed the unneeded alloca.h
diff --git a/assuan/assuan-handler.c b/assuan/assuan-handler.c
index f8b85dbb..da519d54 100644
--- a/assuan/assuan-handler.c
+++ b/assuan/assuan-handler.c
@@ -605,6 +605,7 @@ assuan_get_active_fds (ASSUAN_CONTEXT ctx, int what,
FILE *
assuan_get_data_fp (ASSUAN_CONTEXT ctx)
{
+#if defined (HAVE_FOPENCOOKIE) || defined (HAVE_FUNOPEN)
if (ctx->outbound.data.fp)
return ctx->outbound.data.fp;
@@ -614,6 +615,10 @@ assuan_get_data_fp (ASSUAN_CONTEXT ctx)
0, _assuan_cookie_write_flush);
ctx->outbound.data.error = 0;
return ctx->outbound.data.fp;
+#else
+ errno = ENOSYS;
+ return NULL;
+#endif
}
diff --git a/configure.ac b/configure.ac
index 1755a30f..163fa4ac 100644
--- a/configure.ac
+++ b/configure.ac
@@ -277,23 +277,28 @@ AM_CONDITIONAL(RUN_GPGSM_TESTS,
# FIXME: Only build if supported.
AM_CONDITIONAL(BUILD_ASSUAN, test "$GPGSM" != "no")
-if test "$GPGSM" != "no"; then
- AC_CHECK_FUNCS(funopen)
- if test $ac_cv_func_funopen != yes; then
+
+# The assuan code uses funopen but it will also build without it. So
+# test for it. Frankly, this is not required in gpgme, but thats the
+# way we handle it in libassuan.
+AC_CHECK_FUNCS(funopen)
+if test $ac_cv_func_funopen != yes; then
# No funopen but we can implement that in terms of fopencookie.
AC_CHECK_FUNCS(fopencookie)
if test $ac_cv_func_fopencookie = yes; then
AC_LIBOBJ([funopen])
else
- AC_MSG_ERROR([No implementation of fopencookie or funopen available])
+ AC_MSG_WARN([
+***
+*** No implementation of fopencookie or funopen available
+***])
fi
- fi
-
- AC_REPLACE_FUNCS(isascii)
- AC_REPLACE_FUNCS(putc_unlocked)
- AC_REPLACE_FUNCS(memrchr)
fi
+AC_REPLACE_FUNCS(isascii)
+AC_REPLACE_FUNCS(putc_unlocked)
+AC_REPLACE_FUNCS(memrchr)
+
AM_CONDITIONAL(BUILD_COMPLUS, test "$component_system" = "COM+")