From: Paul Eggert <eggert@cs.ucla.edu>
To: Colin Baxter <m43cap@yandex.com>
Cc: Ted Zlatanov <tzz@lifelogs.com>, emacs-devel@gnu.org
Subject: Re: emacs make error on linux
Date: Wed, 3 Aug 2016 04:50:24 -0700 [thread overview]
Message-ID: <a38a2652-6560-50fd-b164-caed535f8a57@cs.ucla.edu> (raw)
In-Reply-To: <874m723zy5.fsf@yandex.com>
[-- Attachment #1: Type: text/plain, Size: 579 bytes --]
Colin Baxter wrote:
>
> On make I get this error:
>
> gnutls.c: In function ‘Fgnutls_boot’:
> gnutls.c:1605:60: error: ‘GNUTLS_NONBLOCK’ undeclared (first use in this function)
Thanks for reporting that. Although I installed the attached patch to work
around the compile-time problem, I worry that Emacs's run-time behavior will not
be correct for asynchronous connections, so I'll CC: this to Ted Zlatanov, our
GnuTLS expert.
Which version of GnuTLS are you using? That is, what is the output of this shell
command?
pkg-config --modversion gnutls
[-- Attachment #2: 0001-Port-to-systems-lacking-GNUTLS_NONBLOCK.txt --]
[-- Type: text/plain, Size: 1271 bytes --]
From 2c011946d7eb99c62beb6d1a87cfff52dbb0d45d Mon Sep 17 00:00:00 2001
From: Paul Eggert <eggert@cs.ucla.edu>
Date: Wed, 3 Aug 2016 07:45:47 -0400
Subject: [PATCH] Port to systems lacking GNUTLS_NONBLOCK
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Problem reported by Colin Baxter in:
http://lists.gnu.org/archive/html/emacs-devel/2016-08/msg00096.html
* src/gnutls.c (Fgnutls_boot): Don’t assume GNUTLS_NONBLOCK is defined.
---
src/gnutls.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/src/gnutls.c b/src/gnutls.c
index e3e9311..bc35dfb 100644
--- a/src/gnutls.c
+++ b/src/gnutls.c
@@ -1602,8 +1602,12 @@ one trustfile (usually a CA bundle). */)
/* Call gnutls_init here: */
GNUTLS_LOG (1, max_log_level, "gnutls_init");
- int nonblock = XPROCESS (proc)->is_non_blocking_client ? GNUTLS_NONBLOCK : 0;
- ret = gnutls_init (&state, GNUTLS_CLIENT | nonblock);
+ int gnutls_flags = GNUTLS_CLIENT;
+#ifdef GNUTLS_NONBLOCK
+ if (XPROCESS (proc)->is_non_blocking_client)
+ gnutls_flags |= GNUTLS_NONBLOCK;
+#endif
+ ret = gnutls_init (&state, gnutls_flags);
XPROCESS (proc)->gnutls_state = state;
if (ret < GNUTLS_E_SUCCESS)
return gnutls_make_error (ret);
--
2.5.5
next prev parent reply other threads:[~2016-08-03 11:50 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-03 10:32 emacs make error on linux Colin Baxter
2016-08-03 11:50 ` Paul Eggert [this message]
2016-08-03 12:08 ` Colin Baxter
2016-08-04 14:16 ` Ted Zlatanov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a38a2652-6560-50fd-b164-caed535f8a57@cs.ucla.edu \
--to=eggert@cs.ucla.edu \
--cc=emacs-devel@gnu.org \
--cc=m43cap@yandex.com \
--cc=tzz@lifelogs.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.