Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 16 Oct 2020 01:35:20 +0000 (UTC)
From:      Jan Beich <jbeich@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r552487 - in head/devel/pygobject3-common: . files
Message-ID:  <202010160135.09G1ZKLO010784@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jbeich
Date: Fri Oct 16 01:35:19 2020
New Revision: 552487
URL: https://svnweb.freebsd.org/changeset/ports/552487

Log:
  devel/pygobject3-common: unbreak with DEFAULT_VERSIONS += python=3.9
  
  pygobject-object.c:849:35: error: no member named 'tp_print' in '_typeobject'
                                    offsetof(PyTypeObject, tp_print) };
                                    ^                      ~~~~~~~~
  /usr/include/stddef.h:75:31: note: expanded from macro 'offsetof'
   #define offsetof(type, field)   __offsetof(type, field)
                                   ^                ~~~~~
  /usr/include/sys/cdefs.h:480:34: note: expanded from macro '__offsetof'
   #define __offsetof(type, field)  __builtin_offsetof(type, field)
                                    ^                        ~~~~~
  pygobject-object.c:856:21: error: invalid application of 'sizeof' to an incomplete type 'int []'
      for (i = 0; i < G_N_ELEMENTS(slot_offsets); ++i)
                      ^~~~~~~~~~~~~~~~~~~~~~~~~~
  /usr/local/include/glib-2.0/glib/gmacros.h:822:36: note: expanded from macro 'G_N_ELEMENTS'
   #define G_N_ELEMENTS(arr)               (sizeof (arr) / sizeof ((arr)[0]))
                                                   ^~~~~
  
  Regressed by:	https://github.com/python/cpython/commit/f9bab74d5b34
  Obtained from:	upstream

Added:
  head/devel/pygobject3-common/files/patch-python39   (contents, props changed)
Modified:
  head/devel/pygobject3-common/Makefile   (contents, props changed)

Modified: head/devel/pygobject3-common/Makefile
==============================================================================
--- head/devel/pygobject3-common/Makefile	Thu Oct 15 23:38:45 2020	(r552486)
+++ head/devel/pygobject3-common/Makefile	Fri Oct 16 01:35:19 2020	(r552487)
@@ -3,7 +3,7 @@
 
 PORTNAME=	gobject
 PORTVERSION=	3.28.3
-PORTREVISION=	2
+PORTREVISION=	3
 CATEGORIES=	devel python
 MASTER_SITES=	GNOME/sources/pygobject/${PORTVERSION:C/^([0-9]+\.[0-9]+).*/\1/}
 PKGNAMEPREFIX?=	py

Added: head/devel/pygobject3-common/files/patch-python39
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/pygobject3-common/files/patch-python39	Fri Oct 16 01:35:19 2020	(r552487)
@@ -0,0 +1,16 @@
+https://gitlab.gnome.org/GNOME/pygobject/-/commit/07cb8d7dfc2f
+
+--- gi/pygobject-object.c.orig	2018-05-31 14:39:04 UTC
++++ gi/pygobject-object.c
+@@ -846,7 +846,10 @@ pygobject_inherit_slots(PyTypeObject *type, PyObject *
+                                   offsetof(PyTypeObject, tp_iter),
+                                   offsetof(PyTypeObject, tp_repr),
+                                   offsetof(PyTypeObject, tp_str),
+-                                  offsetof(PyTypeObject, tp_print) };
++#if PY_VERSION_HEX < 0x03000000
++                                  offsetof(PyTypeObject, tp_print),
++#endif
++    };
+     gsize i;
+ 
+     /* Happens when registering gobject.GObject itself, at least. */



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202010160135.09G1ZKLO010784>