Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/editors/emacs27 emacs27: add default-on option for JSO...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/b34412c094d7
branches:  trunk
changeset: 437409:b34412c094d7
user:      wiz <wiz%pkgsrc.org@localhost>
date:      Sun Aug 23 20:12:34 2020 +0000

description:
emacs27: add default-on option for JSON support and add workaround for emacsclient socket issue

Both from iquiw on pkgsrc-users.

Bump PKGREVISION.

diffstat:

 editors/emacs27/Makefile                            |   4 ++--
 editors/emacs27/distinfo                            |   3 ++-
 editors/emacs27/options.mk                          |  15 ++++++++++++---
 editors/emacs27/patches/patch-lib-src_emacsclient.c |  20 ++++++++++++++++++++
 4 files changed, 36 insertions(+), 6 deletions(-)

diffs (90 lines):

diff -r a231c3f8484d -r b34412c094d7 editors/emacs27/Makefile
--- a/editors/emacs27/Makefile  Sun Aug 23 14:58:04 2020 +0000
+++ b/editors/emacs27/Makefile  Sun Aug 23 20:12:34 2020 +0000
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.2 2020/08/17 20:18:32 leot Exp $
+# $NetBSD: Makefile,v 1.3 2020/08/23 20:12:34 wiz Exp $
 
 CONFLICTS+=    emacs27-nox11-[0-9]*
 
-PKGREVISION= 1
+PKGREVISION=   2
 .include "../../editors/emacs27/Makefile.common"
 
 .include "options.mk"
diff -r a231c3f8484d -r b34412c094d7 editors/emacs27/distinfo
--- a/editors/emacs27/distinfo  Sun Aug 23 14:58:04 2020 +0000
+++ b/editors/emacs27/distinfo  Sun Aug 23 20:12:34 2020 +0000
@@ -1,7 +1,8 @@
-$NetBSD: distinfo,v 1.1 2020/08/12 14:14:48 ryoon Exp $
+$NetBSD: distinfo,v 1.2 2020/08/23 20:12:34 wiz Exp $
 
 SHA1 (emacs-27.1.tar.gz) = 47d5c733cc41406e6f78df9784e4eddf92dfe392
 RMD160 (emacs-27.1.tar.gz) = 9ddfd28ab54c4aee168eeecb783d13599e5b5288
 SHA512 (emacs-27.1.tar.gz) = fce6c785e9fd9e53282d8293c0c222b3a8cf433db2c19de98bef9e5c1797ffe17663ce1cf205edea6a7b8ded7842df2def2c859c563f091bd68d03ffa9c39198
 Size (emacs-27.1.tar.gz) = 65782481 bytes
+SHA1 (patch-lib-src_emacsclient.c) = 2299db9359f1628b5379d2fb0a813ff88e0461cc
 SHA1 (patch-src_inotify.c) = 1fdc6566ed57e8418f1ddc85bb03518d7d9d6bb3
diff -r a231c3f8484d -r b34412c094d7 editors/emacs27/options.mk
--- a/editors/emacs27/options.mk        Sun Aug 23 14:58:04 2020 +0000
+++ b/editors/emacs27/options.mk        Sun Aug 23 20:12:34 2020 +0000
@@ -1,8 +1,8 @@
-# $NetBSD: options.mk,v 1.1 2020/08/12 14:14:48 ryoon Exp $
+# $NetBSD: options.mk,v 1.2 2020/08/23 20:12:34 wiz Exp $
 
 ### Set options
 PKG_OPTIONS_VAR=                       PKG_OPTIONS.emacs
-PKG_SUPPORTED_OPTIONS=                 dbus gconf gnutls imagemagick svg xaw3d xft2 xml
+PKG_SUPPORTED_OPTIONS=                 dbus gconf gnutls imagemagick jansson svg xaw3d xft2 xml
 # xaw3d is only valid with tookit = xaw
 
 PKG_OPTIONS_OPTIONAL_GROUPS+=          window-system
@@ -22,7 +22,7 @@
 
 # svg is omitted because it is rarely needed and either very
 # heavyweight or unmaintained.
-PKG_SUGGESTED_OPTIONS= dbus gconf gnutls gtk3 xaw3d xft2 xml x11
+PKG_SUGGESTED_OPTIONS= dbus gconf gnutls gtk3 jansson xaw3d xft2 xml x11
 
 .include "../../mk/bsd.options.mk"
 
@@ -37,6 +37,15 @@
 .endif
 
 ###
+### Support JSON
+###
+.if !empty(PKG_OPTIONS:Mjansson)
+.  include "../../textproc/jansson/buildlink3.mk"
+.else
+CONFIGURE_ARGS+=       --without-json
+.endif
+
+###
 ### Support XML2
 ###
 .if !empty(PKG_OPTIONS:Mxml)
diff -r a231c3f8484d -r b34412c094d7 editors/emacs27/patches/patch-lib-src_emacsclient.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/editors/emacs27/patches/patch-lib-src_emacsclient.c       Sun Aug 23 20:12:34 2020 +0000
@@ -0,0 +1,20 @@
+$NetBSD: patch-lib-src_emacsclient.c,v 1.1 2020/08/23 20:12:34 wiz Exp $
+
+Workaround for:
+On NetBSD, fstat on a socket returns zero instead of the user id.
+Reported upstream as http://debbugs.gnu.org/cgi/bugreport.cgi?bug=43002
+
+--- lib-src/emacsclient.c.orig 2020-07-29 21:40:41.000000000 +0000
++++ lib-src/emacsclient.c
+@@ -1478,6 +1478,11 @@ set_local_socket (char const *server_nam
+       struct stat connect_stat;
+       if (fstat (s, &connect_stat) != 0)
+       sock_status = errno;
++#if defined(__NetBSD__)
++      else if (1) {
++        return s;
++      }
++#endif
+       else if (connect_stat.st_uid == uid)
+       return s;
+       else



Home | Main Index | Thread Index | Old Index