pkgsrc-Changes archive

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

CVS commit: [pkgsrc-2020Q4] pkgsrc/sysutils/xentools411



Module Name:    pkgsrc
Committed By:   bsiegert
Date:           Tue Feb 16 08:30:47 UTC 2021

Modified Files:
        pkgsrc/sysutils/xentools411 [pkgsrc-2020Q4]: Makefile distinfo
        pkgsrc/sysutils/xentools411/patches [pkgsrc-2020Q4]:
            patch-tools_ocaml_common.make
Added Files:
        pkgsrc/sysutils/xentools411/patches [pkgsrc-2020Q4]:
            patch-tools_ocaml_Makefile.rules
            patch-tools_xenstore_xenstored_core.c

Log Message:
Pullup ticket #6425 - requested by bouyer
sysutils/xentools411: build fix, bugfix

Revisions pulled up:
- sysutils/xentools411/Makefile                                 1.25
- sysutils/xentools411/distinfo                                 1.16
- sysutils/xentools411/patches/patch-tools_ocaml_Makefile.rules 1.1
- sysutils/xentools411/patches/patch-tools_ocaml_common.make    1.2
- sysutils/xentools411/patches/patch-tools_xenstore_xenstored_core.c 1.1

---
   Module Name: pkgsrc
   Committed By:        bouyer
   Date:                Thu Feb  4 11:45:53 UTC 2021

   Modified Files:
        pkgsrc/sysutils/xentools411: Makefile distinfo
        pkgsrc/sysutils/xentools411/patches: patch-tools_ocaml_common.make
   Added Files:
        pkgsrc/sysutils/xentools411/patches: patch-tools_ocaml_Makefile.rules
            patch-tools_xenstore_xenstored_core.c

   Log Message:
   Fix build with newer ocaml.
   Fix xenstored leaking file descriptors and busy-looping over them.


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.24.2.1 pkgsrc/sysutils/xentools411/Makefile
cvs rdiff -u -r1.15 -r1.15.2.1 pkgsrc/sysutils/xentools411/distinfo
cvs rdiff -u -r0 -r1.1.2.2 \
    pkgsrc/sysutils/xentools411/patches/patch-tools_ocaml_Makefile.rules \
    pkgsrc/sysutils/xentools411/patches/patch-tools_xenstore_xenstored_core.c
cvs rdiff -u -r1.1 -r1.1.20.1 \
    pkgsrc/sysutils/xentools411/patches/patch-tools_ocaml_common.make

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/sysutils/xentools411/Makefile
diff -u pkgsrc/sysutils/xentools411/Makefile:1.24 pkgsrc/sysutils/xentools411/Makefile:1.24.2.1
--- pkgsrc/sysutils/xentools411/Makefile:1.24   Thu Dec 17 16:48:12 2020
+++ pkgsrc/sysutils/xentools411/Makefile        Tue Feb 16 08:30:47 2021
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.24 2020/12/17 16:48:12 bouyer Exp $
+# $NetBSD: Makefile,v 1.24.2.1 2021/02/16 08:30:47 bsiegert Exp $
 #
 # VERSION is set in version.mk as it is shared with other packages
-PKGREVISION=   2
+PKGREVISION=   3
 .include       "version.mk"
 
 DIST_IPXE=     ipxe-git-${VERSION_IPXE}.tar.gz

Index: pkgsrc/sysutils/xentools411/distinfo
diff -u pkgsrc/sysutils/xentools411/distinfo:1.15 pkgsrc/sysutils/xentools411/distinfo:1.15.2.1
--- pkgsrc/sysutils/xentools411/distinfo:1.15   Thu Dec 17 16:48:12 2020
+++ pkgsrc/sysutils/xentools411/distinfo        Tue Feb 16 08:30:47 2021
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.15 2020/12/17 16:48:12 bouyer Exp $
+$NetBSD: distinfo,v 1.15.2.1 2021/02/16 08:30:47 bsiegert Exp $
 
 SHA1 (xen411/ipxe-git-356f6c1b64d7a97746d1816cef8ca22bdd8d0b5d.tar.gz) = 272b8c904dc0127690eca2c5c20c67479e40da34
 RMD160 (xen411/ipxe-git-356f6c1b64d7a97746d1816cef8ca22bdd8d0b5d.tar.gz) = cfcb4a314c15da19b36132b27126f3bd9699d0e5
@@ -62,7 +62,8 @@ SHA1 (patch-tools_libxl_libxl_dom.c) = 0
 SHA1 (patch-tools_libxl_libxl_event.c) = 8147122d03102eccc45c48a7d6ca1aa5d6286040
 SHA1 (patch-tools_libxl_libxl_internal.h) = 613edc0fa055b23f5dc2a2448456d3d6005337fe
 SHA1 (patch-tools_libxl_libxl_uuid.c) = 1eb8c027dbeb7e67df7475ee6e4d87220140c65b
-SHA1 (patch-tools_ocaml_common.make) = 4b845bdf3a013852109749ee18dfe28e3440d951
+SHA1 (patch-tools_ocaml_Makefile.rules) = 2198396f896999adb8ea05f100a0a5ec36733b1a
+SHA1 (patch-tools_ocaml_common.make) = 731744c8acd9ec4d04ef585c31348d498ac861b0
 SHA1 (patch-tools_ocaml_libs_xentoollog_xentoollog__stubs.c) = adee03d87168e735cb0d42ce06d0c31a14315b8d
 SHA1 (patch-tools_ocaml_libs_xl__xenlight_stubs.c) = cc612908524670f650a294af133a5912f955f39e
 SHA1 (patch-tools_ocaml_xenstored_Makefile) = b267702cf4090c7b45bba530e60327fced24e3e5
@@ -87,6 +88,7 @@ SHA1 (patch-tools_qemu-xen_qemu-doc.texi
 SHA1 (patch-tools_xenpaging_xenpaging.c) = 0a154b97f1f452a5f80f7c9a835a1f216f12f7e1
 SHA1 (patch-tools_xenpmd_xenpmd.c) = 851ce7a295e2f41ffcd966850d8003c82670c751
 SHA1 (patch-tools_xenstore_xc.c) = cf49b65cba064667e13bb041d1f0099c76ab6a40
+SHA1 (patch-tools_xenstore_xenstored_core.c) = f3d3011cb945772f298404b3505ca032a8bc06ea
 SHA1 (patch-tools_xenstore_xs_lib.c) = e3a8f6e3b149c3ab0f4ec8dcfa455983f94e6c16
 SHA1 (patch-tools_xentrace_xentrace.c) = f964c7555f454358a39f28a2e75db8ee100a4243
 SHA1 (patch-tools_xl_Makefile) = dd4fa8cc66c74eea8b022cd6129aa2831776f2a8

Index: pkgsrc/sysutils/xentools411/patches/patch-tools_ocaml_common.make
diff -u pkgsrc/sysutils/xentools411/patches/patch-tools_ocaml_common.make:1.1 pkgsrc/sysutils/xentools411/patches/patch-tools_ocaml_common.make:1.1.20.1
--- pkgsrc/sysutils/xentools411/patches/patch-tools_ocaml_common.make:1.1       Tue Jul 24 13:40:11 2018
+++ pkgsrc/sysutils/xentools411/patches/patch-tools_ocaml_common.make   Tue Feb 16 08:30:47 2021
@@ -1,11 +1,6 @@
-$NetBSD: patch-tools_ocaml_common.make,v 1.1 2018/07/24 13:40:11 bouyer Exp $
-
-Handle ocaml-findlib 1.7.3 already appending destdir
-Add -unsafe-string to fix build with ocaml-4.06.0 and later
-
---- tools/ocaml/common.make.orig       2018-01-23 13:49:58.000000000 +0000
-+++ tools/ocaml/common.make
-@@ -3,7 +3,7 @@ include $(XEN_ROOT)/tools/Rules.mk
+--- tools/ocaml/common.make.orig       2020-04-17 13:58:20.000000000 +0200
++++ tools/ocaml/common.make    2021-02-04 11:25:02.393221932 +0100
+@@ -3,7 +3,7 @@
  CC ?= gcc
  OCAMLOPT ?= ocamlopt
  OCAMLC ?= ocamlc
@@ -14,14 +9,7 @@ Add -unsafe-string to fix build with oca
  OCAMLDEP ?= ocamldep
  OCAMLLEX ?= ocamllex
  OCAMLYACC ?= ocamlyacc
-@@ -12,11 +12,11 @@ OCAMLFIND ?= ocamlfind
- CFLAGS += -fPIC -Werror -I$(shell ocamlc -where)
- 
- OCAMLOPTFLAG_G := $(shell $(OCAMLOPT) -h 2>&1 | sed -n 's/^  *\(-g\) .*/\1/p')
--OCAMLOPTFLAGS = $(OCAMLOPTFLAG_G) -ccopt "$(LDFLAGS)" -dtypes $(OCAMLINCLUDE) -cc $(CC) -w F -warn-error F
--OCAMLCFLAGS += -g $(OCAMLINCLUDE) -w F -warn-error F
-+OCAMLOPTFLAGS = $(OCAMLOPTFLAG_G) -unsafe-string -ccopt "$(LDFLAGS)" -dtypes $(OCAMLINCLUDE) -cc $(CC) -w F -warn-error F
-+OCAMLCFLAGS += -unsafe-string -g $(OCAMLINCLUDE) -w F -warn-error F
+@@ -17,6 +17,6 @@
  
  VERSION := 4.1
  

Added files:

Index: pkgsrc/sysutils/xentools411/patches/patch-tools_ocaml_Makefile.rules
diff -u /dev/null pkgsrc/sysutils/xentools411/patches/patch-tools_ocaml_Makefile.rules:1.1.2.2
--- /dev/null   Tue Feb 16 08:30:47 2021
+++ pkgsrc/sysutils/xentools411/patches/patch-tools_ocaml_Makefile.rules        Tue Feb 16 08:30:47 2021
@@ -0,0 +1,13 @@
+$NetBSD: patch-tools_ocaml_Makefile.rules,v 1.1.2.2 2021/02/16 08:30:47 bsiegert Exp $
+
+--- tools/ocaml/Makefile.rules.orig    2021-01-08 22:48:10.638776688 +0100
++++ tools/ocaml/Makefile.rules 2021-01-08 22:49:05.627085243 +0100
+@@ -34,7 +34,7 @@
+       $(call quiet-command, $(OCAMLYACC) -q $<,MLYACC,$@)
+ 
+ %.o: %.c
+-      $(call quiet-command, $(CC) $(CFLAGS) -c -o $@ $<,CC,$@)
++      $(call quiet-command, $(CC) $(CFLAGS) -Wno-error=discarded-qualifiers -c -o $@ $<,CC,$@)
+ 
+ META: META.in
+       sed 's/@VERSION@/$(VERSION)/g' < $< $o
Index: pkgsrc/sysutils/xentools411/patches/patch-tools_xenstore_xenstored_core.c
diff -u /dev/null pkgsrc/sysutils/xentools411/patches/patch-tools_xenstore_xenstored_core.c:1.1.2.2
--- /dev/null   Tue Feb 16 08:30:47 2021
+++ pkgsrc/sysutils/xentools411/patches/patch-tools_xenstore_xenstored_core.c   Tue Feb 16 08:30:47 2021
@@ -0,0 +1,29 @@
+$NetBSD: patch-tools_xenstore_xenstored_core.c,v 1.1.2.2 2021/02/16 08:30:47 bsiegert Exp $
+
+On error, don't keep socket connection in ignored state but close them.
+When the remote end of a socket is closed, xenstored will flag it as an
+error and switch the connection to ignored. But on some OSes (e.g.
+NetBSD), poll(2) will return only POLLIN in this case, so sockets in ignored
+state will stay open forever in xenstored (and it will loop with CPU 100%
+busy).
+
+Signed-off-by: Manuel Bouyer <bouyer%netbsd.org@localhost>
+Fixes: d2fa370d3ef9cbe22d7256c608671cdcdf6e0083
+---
+ tools/xenstore/xenstored_core.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/tools/xenstore/xenstored_core.c b/tools/xenstore/xenstored_core.c
+index 1ab6f162cb..0fea598352 100644
+--- tools/xenstore/xenstored_core.c.orig
++++ tools/xenstore/xenstored_core.c
+@@ -1440,6 +1440,9 @@ static void ignore_connection(struct connection *conn)
+ 
+       talloc_free(conn->in);
+       conn->in = NULL;
++      /* if this is a socket connection, drop it now */
++      if (conn->fd >= 0)
++              talloc_free(conn);
+ }
+ 
+ static const char *sockmsg_string(enum xsd_sockmsg_type type)



Home | Main Index | Thread Index | Old Index