public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: dev-python/wxpython/files/, dev-python/wxpython/
@ 2024-06-18  4:49 Sam James
  0 siblings, 0 replies; 5+ messages in thread
From: Sam James @ 2024-06-18  4:49 UTC (permalink / raw
  To: gentoo-commits

commit:     e9d357d68f7a77aeff1aa1bee8c69746f5d0515d
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Tue Jun 18 04:48:25 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Tue Jun 18 04:48:53 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e9d357d6

dev-python/wxpython: fix build w/ some doxygen versions

Closes: https://bugs.gentoo.org/934482
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../files/wxpython-4.2.1-doxygen-1.9.7.patch       | 46 ++++++++++++++++++++++
 dev-python/wxpython/wxpython-4.2.1-r2.ebuild       |  1 +
 2 files changed, 47 insertions(+)

diff --git a/dev-python/wxpython/files/wxpython-4.2.1-doxygen-1.9.7.patch b/dev-python/wxpython/files/wxpython-4.2.1-doxygen-1.9.7.patch
new file mode 100644
index 000000000000..7baf5708b8ff
--- /dev/null
+++ b/dev-python/wxpython/files/wxpython-4.2.1-doxygen-1.9.7.patch
@@ -0,0 +1,46 @@
+https://bugs.gentoo.org/934482
+https://github.com/wxWidgets/Phoenix/commit/6a049ccc0ad96f25c3f7d8540b218ffe8921d8c5
+
+From 6a049ccc0ad96f25c3f7d8540b218ffe8921d8c5 Mon Sep 17 00:00:00 2001
+From: Scott Talbert <swt@techie.net>
+Date: Tue, 5 Dec 2023 23:42:21 -0500
+Subject: [PATCH] Support building with Doxygen 1.9.7
+
+Doxygen 1.9.7 made some changes whereby some method definitions are now
+defined in separate XML files, with a "refid" that links to them.  In
+order to support this, we need to follow these "refids" to pick up the
+method definition from the separate group XML files.
+--- a/etgtools/extractors.py
++++ b/etgtools/extractors.py
+@@ -62,6 +62,8 @@ def extract(self, element):
+         # class. Should be overridden in derived classes to get what each one
+         # needs in addition to the base.
+         self.name = element.find(self.nameTag).text
++        if self.name is None:
++            self.name = ''
+         if '::' in self.name:
+             loc = self.name.rfind('::')
+             self.name = self.name[loc+2:]
+@@ -1574,12 +1576,21 @@ def addElement(self, element):
+             extractingMsg(kind, element)
+             for node in element.findall('sectiondef/memberdef'):
+                 self.addElement(node)
++            for node in element.findall('sectiondef/member'):
++                node = self.resolveRefid(node)
++                self.addElement(node)
+ 
+         else:
+             raise ExtractorError('Unknown module item kind: %s' % kind)
+ 
+         return item
+ 
++    def resolveRefid(self, node):
++        from etgtools import XMLSRC
++        refid = node.get('refid')
++        fname = os.path.join(XMLSRC, refid.rsplit('_', 1)[0]) + '.xml'
++        root = et.parse(fname).getroot()
++        return root.find(".//memberdef[@id='{}']".format(refid))
+ 
+ 
+     def addCppFunction(self, type, name, argsString, body, doc=None, **kw):
+

diff --git a/dev-python/wxpython/wxpython-4.2.1-r2.ebuild b/dev-python/wxpython/wxpython-4.2.1-r2.ebuild
index f97c735170b3..2e58fca2a380 100644
--- a/dev-python/wxpython/wxpython-4.2.1-r2.ebuild
+++ b/dev-python/wxpython/wxpython-4.2.1-r2.ebuild
@@ -59,6 +59,7 @@ PATCHES=(
 	"${FILESDIR}/${PN}-4.2.0-cython-3.patch"
 	"${FILESDIR}/${PN}-4.2.1-integer-division-for-randint.patch"
 	"${FILESDIR}/${PN}-4.2.1-x86-time.patch"
+	"${FILESDIR}/${PN}-4.2.1-doxygen-1.9.7.patch"
 )
 
 python_prepare_all() {


^ permalink raw reply related	[flat|nested] 5+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-python/wxpython/files/, dev-python/wxpython/
@ 2025-03-10  2:45 Sam James
  0 siblings, 0 replies; 5+ messages in thread
From: Sam James @ 2025-03-10  2:45 UTC (permalink / raw
  To: gentoo-commits

commit:     15b4e232d105a18c46a4f394b603ce491652bb06
Author:     Quincy Fleming <quincyf467 <AT> protonmail <DOT> com>
AuthorDate: Wed Feb 26 18:01:05 2025 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Mar 10 02:41:08 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=15b4e232

dev-python/wxpython: add 4.2.2

Bug: https://bugs.gentoo.org/923418
Bug: https://bugs.gentoo.org/924057
Closes: https://bugs.gentoo.org/909973
Signed-off-by: Quincy Fleming <quincyf467 <AT> protonmail.com>
Closes: https://github.com/gentoo/gentoo/pull/39465
Signed-off-by: Sam James <sam <AT> gentoo.org>

 dev-python/wxpython/Manifest                       |   1 +
 .../files/wxpython-4.2.2-no-stacktrace.patch       |  16 +++
 .../wxpython/files/wxpython-4.2.2-setuppy.patch    |  38 ++++++
 .../wxpython/files/wxpython-4.2.2-sip-6.10.0.patch |  14 +++
 dev-python/wxpython/wxpython-4.2.2.ebuild          | 136 +++++++++++++++++++++
 5 files changed, 205 insertions(+)

diff --git a/dev-python/wxpython/Manifest b/dev-python/wxpython/Manifest
index 5c6a4c0dbfb4..c9292c83a855 100644
--- a/dev-python/wxpython/Manifest
+++ b/dev-python/wxpython/Manifest
@@ -1,2 +1,3 @@
 DIST wxPython-4.2.0.tar.gz 70958238 BLAKE2B 2e8e34c4f5d1992983bfe4e09bb56ee5619b139b9b3b5f05dee48ecdf6971cf9fe1b0fb22aec685904eb44db6f50a4ba132a08aa91930d809040da828efa097e SHA512 9ec937a024efb2916403c84382a66004f0c2bb07471246b7de517778309ce459e929eeb59e261f538d3fa077c950628de62e49a3760fbd03ab9ff2114c6f354f
 DIST wxPython-4.2.1.tar.gz 73724359 BLAKE2B d9569ea172c7279e0b2cfcb3cdcd5d1faab5324e2648c9b0f8c8b838fb2355dc6af28c4593e5dd0cfa02573133bf15a58a6ffa9711d854925a9cada0985dc7f8 SHA512 ee9ab8effb3c71de004c3d61ec583b9980c6b75fe9bb04cf2c76025ea70afc206bc3073c44d1c83c7ba604afed9fd38c01b9ef506617ba279a4ac58e3cf34438
+DIST wxPython-4.2.2.tar.gz 57358880 BLAKE2B 325256e0d57f868453ed48ea4580a1ea6763acffacb7cd937cf440c55f43fc540dab867a947fb2c9eb353855888aaa370d85103b888bd1339cf5abe7302aba19 SHA512 08b74285b94f21ebf30fef8c9ebf8cfd074dd3976209372bb5b704b0b792038f9af484dd1378894052eedb0ce603af6935b7d00d695da4e4a15e1ea3bdb3520f

diff --git a/dev-python/wxpython/files/wxpython-4.2.2-no-stacktrace.patch b/dev-python/wxpython/files/wxpython-4.2.2-no-stacktrace.patch
new file mode 100644
index 000000000000..f387612522bd
--- /dev/null
+++ b/dev-python/wxpython/files/wxpython-4.2.2-no-stacktrace.patch
@@ -0,0 +1,16 @@
+https://bugs.gentoo.org/924057
+
+--- a/sip/cpp/sip_corewxAppTraits.cpp
++++ b/sip/cpp/sip_corewxAppTraits.cpp
+@@ -471,7 +471,11 @@
+             PyErr_Clear();
+ 
+             Py_BEGIN_ALLOW_THREADS
++	#ifdef __GLIBC__
+             sipRes = new ::wxString((sipSelfWasArg ? sipCpp->::wxAppTraits::GetAssertStackTrace() : sipCpp->GetAssertStackTrace()));
++	#else
++	    sipRes = new ::wxString("");
++	#endif
+             Py_END_ALLOW_THREADS
+ 
+             if (PyErr_Occurred())

diff --git a/dev-python/wxpython/files/wxpython-4.2.2-setuppy.patch b/dev-python/wxpython/files/wxpython-4.2.2-setuppy.patch
new file mode 100644
index 000000000000..229d372aa5af
--- /dev/null
+++ b/dev-python/wxpython/files/wxpython-4.2.2-setuppy.patch
@@ -0,0 +1,38 @@
+Created by Quincy Fleming
+https://bugs.gentoo.org/909973
+
+--- a/setup.py
++++ b/setup.py
+@@ -113,6 +113,7 @@
+     """
+     user_options = [
+         ('skip-build', None, 'skip building the C/C++ code (assumes it has already been done)'),
++        ('buildpy-options=', None, 'string of commands and options passed to build.py'),
+         ]
+     boolean_options = ['skip-build']
+ 
+@@ -120,6 +121,7 @@
+     def initialize_options(self):
+         orig_build.initialize_options(self)
+         self.skip_build = '--skip-build' in sys.argv
++        self.buildpy_options = 'build'
+ 
+     def finalize_options(self):
+         orig_build.finalize_options(self)
+@@ -135,7 +137,7 @@
+                 'message and the wxWidgets and Phoenix build steps in the future.\n')
+ 
+             # Use the same Python that is running this script.
+-            cmd = ['"{}"'.format(sys.executable), '-u', 'build.py', 'build']
++            cmd = ['"{}"'.format(sys.executable), '-u', 'build.py',self.buildpy_options]
+             cmd = ' '.join(cmd)
+             runcmd(cmd)
+ 
+@@ -143,7 +145,6 @@
+         # build/lib folder like normal.
+         orig_build.run(self)
+ 
+-
+ def _cleanup_symlinks(cmd):
+     # Clean out any libwx* symlinks in the build_lib folder, as they will
+     # turn into copies in the egg since zip files can't handle symlinks.

diff --git a/dev-python/wxpython/files/wxpython-4.2.2-sip-6.10.0.patch b/dev-python/wxpython/files/wxpython-4.2.2-sip-6.10.0.patch
new file mode 100644
index 000000000000..7f15661b601f
--- /dev/null
+++ b/dev-python/wxpython/files/wxpython-4.2.2-sip-6.10.0.patch
@@ -0,0 +1,14 @@
+https://bugs.gentoo.org/949510#c4
+https://github.com/wxWidgets/Phoenix/commit/de9aa4be5bb49adf82991c7582ea3c42ed505bf7.patch
+
+--- a/buildtools/config.py
++++ b/buildtools/config.py
+@@ -85,7 +85,7 @@
+     PKGDIR = 'wx'
+     # The name of the top-level package
+ 
+-    SIP_ABI = '12.9'
++    SIP_ABI = '12.14'
+     SIP_TRACE = False
+ 
+     # ---------------------------------------------------------------

diff --git a/dev-python/wxpython/wxpython-4.2.2.ebuild b/dev-python/wxpython/wxpython-4.2.2.ebuild
new file mode 100644
index 000000000000..7a5261f7e9f3
--- /dev/null
+++ b/dev-python/wxpython/wxpython-4.2.2.ebuild
@@ -0,0 +1,136 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+DISTUTILS_EXT=1
+DISTUTILS_USE_PEP517=setuptools
+PYTHON_COMPAT=( python3_{10..13} )
+PYPI_NO_NORMALIZE=1
+PYPI_PN="wxPython"
+WX_GTK_VER="3.2-gtk3"
+
+inherit distutils-r1 multiprocessing virtualx wxwidgets pypi
+
+DESCRIPTION="A blending of the wxWindows C++ class library with Python"
+HOMEPAGE="
+	https://www.wxpython.org/
+	https://github.com/wxWidgets/Phoenix/
+	https://pypi.org/project/wxPython/
+"
+
+LICENSE="wxWinLL-3"
+SLOT="4.0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86"
+IUSE="test webkit"
+RESTRICT="!test? ( test )"
+
+# wxPython doesn't seem to be able to optionally disable features. webkit is
+# optionally patched out because it's so huge, but other elements are not,
+# which makes us have to require all features from wxGTK
+DEPEND="
+	>=x11-libs/wxGTK-3.2.6:${WX_GTK_VER}=[gstreamer,libnotify,opengl,sdl,tiff,webkit?,X]
+	media-libs/libpng:=
+	media-libs/tiff:=
+	media-libs/libjpeg-turbo:=
+"
+RDEPEND="
+	${DEPEND}
+"
+BDEPEND="
+	app-text/doxygen
+	dev-python/cython[${PYTHON_USEDEP}]
+	dev-python/setuptools[${PYTHON_USEDEP}]
+	>=dev-python/sip-6.8.5[${PYTHON_USEDEP}]
+	dev-python/six[${PYTHON_USEDEP}]
+	test? (
+		${VIRTUALX_DEPEND}
+		dev-python/appdirs[${PYTHON_USEDEP}]
+		dev-python/numpy[${PYTHON_USEDEP}]
+		dev-python/pillow[${PYTHON_USEDEP}]
+		dev-python/pytest[${PYTHON_USEDEP}]
+		dev-python/pytest-forked[${PYTHON_USEDEP}]
+		dev-python/pytest-xdist[${PYTHON_USEDEP}]
+	)
+"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-4.2.0-flags.patch"
+	"${FILESDIR}/${PN}-4.2.1-x86-time.patch"
+	"${FILESDIR}/${P}-sip-6.10.0.patch"
+	"${FILESDIR}/${P}-setuppy.patch"
+)
+
+python_prepare_all() {
+	if ! use webkit; then
+		eapply "${FILESDIR}/${PN}-4.2.0-no-webkit.patch"
+	fi
+
+	# sip assumes unconditional C99 support since 6.8.4
+	# which breaks when trying to use "sip/siplib/bool.cpp"
+	# https://github.com/Python-SIP/sip/commit/29fb3df49ff37df7aab9d5666fd72de95ac9e7f8
+	if has_version ">=dev-python/sip-6.8.4"; then
+		sed -i '\|sip/siplib/bool\.cpp|d' wscript || die
+	fi
+
+	local build_options="build_py --use_syswx --no_magic --jobs="$(makeopts_jobs)" --verbose --release"
+
+	DISTUTILS_ARGS=(
+		--verbose
+		build
+		--buildpy-options="${build_options}"
+	)
+
+	distutils-r1_python_prepare_all
+}
+
+src_configure() {
+	setup-wxwidgets
+}
+
+python_compile() {
+	#Patch will fail if copy of refreshed sip file is not restored if using multiple
+	#python implementations
+	DOXYGEN="$(type -P doxygen)" ${PYTHON} build.py dox etg sip --nodoc || die
+	cp "${S}/sip/cpp/sip_corewxAppTraits.cpp" "${S}" || die
+
+	eapply "${FILESDIR}/${P}-no-stacktrace.patch" || die
+
+	distutils-r1_python_compile
+
+	cp "${S}/sip_corewxAppTraits.cpp" "${S}/sip/cpp/" || die
+}
+
+python_test() {
+	local EPYTEST_DESELECT=(
+		# virtx probably
+		unittests/test_display.py::display_Tests::test_display
+		unittests/test_frame.py::frame_Tests::test_frameRestore
+		unittests/test_mousemanager.py::mousemanager_Tests::test_mousemanager1
+		unittests/test_uiaction.py::uiaction_KeyboardTests::test_uiactionKeyboardChar
+		unittests/test_uiaction.py::uiaction_KeyboardTests::test_uiactionKeyboardKeyDownUp
+		unittests/test_uiaction.py::uiaction_MouseTests
+
+		# assertion (TODO)
+		unittests/test_aboutdlg.py::aboutdlg_Tests::test_aboutdlgGeneric
+		unittests/test_lib_agw_piectrl.py::lib_agw_piectrl_Tests::test_lib_agw_piectrlCtor
+
+		# seems to rely on state from a previous test (sigh)
+		unittests/test_lib_agw_persist_persistencemanager.py::lib_agw_persist_persistencemanager_Tests::test_persistencemanagerRestore
+
+		# requires Spanish localization
+		unittests/test_intl.py::intl_Tests::test_intlGetString
+
+		# TODO
+		unittests/test_tipwin.py::tipwin_Tests::test_tipwinCtor
+		unittests/test_lib_pubsub_provider.py::lib_pubsub_Except::test1
+		unittests/test_windowid.py::IdManagerTest::test_newIdRef03
+	)
+	local EPYTEST_IGNORE=()
+	if ! use webkit; then
+		EPYTEST_IGNORE+=( unittests/test_webview.py )
+	fi
+
+	# We use pytest-forked as opensuse does to avoid tests corrupting each
+	# other.
+	virtx epytest --forked -n "$(makeopts_jobs)" unittests
+}


^ permalink raw reply related	[flat|nested] 5+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-python/wxpython/files/, dev-python/wxpython/
@ 2025-02-18 22:10 Sam James
  0 siblings, 0 replies; 5+ messages in thread
From: Sam James @ 2025-02-18 22:10 UTC (permalink / raw
  To: gentoo-commits

commit:     2a8e6ca015fa6107230f131d1232bfe2bb55bcbd
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Tue Feb 18 22:09:19 2025 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Tue Feb 18 22:09:37 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2a8e6ca0

dev-python/wxpython: fix build w/ >=dev-python/sip-6.10.0

Closes: https://bugs.gentoo.org/949510
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../wxpython/files/wxpython-4.2.1-sip-6.10.0.patch | 23 ++++++++++++++++++++++
 dev-python/wxpython/wxpython-4.2.1-r2.ebuild       |  3 ++-
 2 files changed, 25 insertions(+), 1 deletion(-)

diff --git a/dev-python/wxpython/files/wxpython-4.2.1-sip-6.10.0.patch b/dev-python/wxpython/files/wxpython-4.2.1-sip-6.10.0.patch
new file mode 100644
index 000000000000..5d6751d7a8d4
--- /dev/null
+++ b/dev-python/wxpython/files/wxpython-4.2.1-sip-6.10.0.patch
@@ -0,0 +1,23 @@
+https://bugs.gentoo.org/949510#c4
+https://github.com/wxWidgets/Phoenix/commit/de9aa4be5bb49adf82991c7582ea3c42ed505bf7.patch
+
+From de9aa4be5bb49adf82991c7582ea3c42ed505bf7 Mon Sep 17 00:00:00 2001
+From: Scott Talbert <swt@techie.net>
+Date: Sun, 9 Feb 2025 17:50:08 -0500
+Subject: [PATCH] Update SIP ABI version to 12.14
+
+We haven't supported 12.8 since before we upgraded to SIP 6.6+.
+However, SIP has not been correctly generating the correct module
+version until very recently, so generating 12.8 doesn't actually compile
+with current wxPython.
+--- a/buildtools/config.py
++++ b/buildtools/config.py
+@@ -88,7 +88,7 @@ class Configuration(object):
+     PKGDIR = 'wx'
+     # The name of the top-level package
+ 
+-    SIP_ABI = '12.8'
++    SIP_ABI = '12.14'
+     SIP_TRACE = False
+ 
+     # ---------------------------------------------------------------

diff --git a/dev-python/wxpython/wxpython-4.2.1-r2.ebuild b/dev-python/wxpython/wxpython-4.2.1-r2.ebuild
index ec62390a1579..0a82fba9a074 100644
--- a/dev-python/wxpython/wxpython-4.2.1-r2.ebuild
+++ b/dev-python/wxpython/wxpython-4.2.1-r2.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2024 Gentoo Authors
+# Copyright 1999-2025 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
@@ -60,6 +60,7 @@ PATCHES=(
 	"${FILESDIR}/${PN}-4.2.1-integer-division-for-randint.patch"
 	"${FILESDIR}/${PN}-4.2.1-x86-time.patch"
 	"${FILESDIR}/${PN}-4.2.1-doxygen-1.9.7.patch"
+	"${FILESDIR}/${PN}-4.2.1-sip-6.10.0.patch"
 )
 
 python_prepare_all() {


^ permalink raw reply related	[flat|nested] 5+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-python/wxpython/files/, dev-python/wxpython/
@ 2024-06-17 23:45 Sam James
  0 siblings, 0 replies; 5+ messages in thread
From: Sam James @ 2024-06-17 23:45 UTC (permalink / raw
  To: gentoo-commits

commit:     0fe84cfb62bc21d0c876cefa3b53eef2607ccc0e
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Mon Jun 17 23:44:09 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Jun 17 23:44:09 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0fe84cfb

dev-python/wxpython: fix tests on 32-bit arches

See commentary in the patch, but the gist is that we go back to 'long'
as a hack, although it's not right for Windows.

Closes: https://bugs.gentoo.org/922328
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../wxpython/files/wxpython-4.2.1-x86-time.patch   |  34 ++++++
 dev-python/wxpython/wxpython-4.2.1-r2.ebuild       | 128 +++++++++++++++++++++
 2 files changed, 162 insertions(+)

diff --git a/dev-python/wxpython/files/wxpython-4.2.1-x86-time.patch b/dev-python/wxpython/files/wxpython-4.2.1-x86-time.patch
new file mode 100644
index 000000000000..ea144419833e
--- /dev/null
+++ b/dev-python/wxpython/files/wxpython-4.2.1-x86-time.patch
@@ -0,0 +1,34 @@
+https://bugs.gentoo.org/922328
+https://github.com/wxWidgets/Phoenix/issues/1910
+https://github.com/wxWidgets/Phoenix/issues/2197 (specifically https://github.com/wxWidgets/Phoenix/issues/2197#issuecomment-1169378156)
+https://github.com/StefanBruens/Phoenix/commit/8b743981d557d0465ba53e938784be94f4679145 but w/ s/SIP_SSIZE_T/long
+i.e. a revert of https://github.com/wxWidgets/Phoenix/commit/c78823549bac1b28d99a1ad6dc1008485a2afb33.
+
+From 8b743981d557d0465ba53e938784be94f4679145 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Stefan=20Br=C3=BCns?= <stefan.bruens@rwth-aachen.de>
+Date: Tue, 28 Jun 2022 18:32:32 +0200
+Subject: [PATCH] Fix time_t ETG typedef, extend DateTime.FromTimeT tests
+
+Before c78823549bac ("Ensure time_t is treated as a 64-bit value by SIP")
+the typedef used "long" instead of wxInt64, which caused issues on Win64,
+as long is 32bit there (LLP64). On the other hand, wxInt64 is wrong on
+32 bit Linux (e.g. armv7, i586), and thus the code crashes.
+
+As SIP_SSIZE_T is 64 bit for both LLP64 (Windows) and LP64 (Linux), but
+32 bit on 32bit archs, it matches time_t better (though, according to the
+C standard, it could even be a double).
+
+Fixes #2197.
+ etg/defs.py                  | 2 +-
+
+--- a/etg/defs.py
++++ b/etg/defs.py
+@@ -73,7 +73,7 @@ def run():
+     td = module.find('wxUIntPtr')
+     module.insertItemAfter(td, etgtools.TypedefDef(type='wchar_t', name='wxUChar'))
+     module.insertItemAfter(td, etgtools.TypedefDef(type='wchar_t', name='wxChar'))
+-    module.insertItemAfter(td, etgtools.TypedefDef(type='wxInt64', name='time_t'))
++    module.insertItemAfter(td, etgtools.TypedefDef(type='long', name='time_t'))
+     module.insertItemAfter(td, etgtools.TypedefDef(type='long long', name='wxFileOffset'))
+     module.insertItemAfter(td, etgtools.TypedefDef(type='SIP_SSIZE_T', name='ssize_t'))
+     module.insertItemAfter(td, etgtools.TypedefDef(type='unsigned char', name='byte', pyInt=True))

diff --git a/dev-python/wxpython/wxpython-4.2.1-r2.ebuild b/dev-python/wxpython/wxpython-4.2.1-r2.ebuild
new file mode 100644
index 000000000000..4472b419a665
--- /dev/null
+++ b/dev-python/wxpython/wxpython-4.2.1-r2.ebuild
@@ -0,0 +1,128 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_EXT=1
+DISTUTILS_IN_SOURCE_BUILD="1"
+PYTHON_COMPAT=( python3_{10..12} )
+PYPI_NO_NORMALIZE=1
+PYPI_PN="wxPython"
+WX_GTK_VER="3.2-gtk3"
+
+inherit distutils-r1 multiprocessing virtualx wxwidgets pypi
+
+DESCRIPTION="A blending of the wxWindows C++ class library with Python"
+HOMEPAGE="
+	https://www.wxpython.org/
+	https://github.com/wxWidgets/Phoenix/
+	https://pypi.org/project/wxPython/
+"
+
+LICENSE="wxWinLL-3"
+SLOT="4.0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86"
+IUSE="test webkit"
+RESTRICT="!test? ( test )"
+
+# wxPython doesn't seem to be able to optionally disable features. webkit is
+# optionally patched out because it's so huge, but other elements are not,
+# which makes us have to require all features from wxGTK
+DEPEND="
+	>=x11-libs/wxGTK-3.0.4-r301:${WX_GTK_VER}=[gstreamer,libnotify,opengl,sdl,tiff,webkit?,X]
+	media-libs/libpng:=
+	media-libs/tiff:=
+	media-libs/libjpeg-turbo:=
+"
+RDEPEND="
+	${DEPEND}
+"
+BDEPEND="
+	app-text/doxygen
+	dev-python/cython[${PYTHON_USEDEP}]
+	dev-python/setuptools[${PYTHON_USEDEP}]
+	>=dev-python/sip-6.6.2[${PYTHON_USEDEP}]
+	dev-python/six[${PYTHON_USEDEP}]
+	test? (
+		${VIRTUALX_DEPEND}
+		dev-python/appdirs[${PYTHON_USEDEP}]
+		dev-python/numpy[${PYTHON_USEDEP}]
+		dev-python/pillow[${PYTHON_USEDEP}]
+		dev-python/pytest[${PYTHON_USEDEP}]
+		dev-python/pytest-forked[${PYTHON_USEDEP}]
+		dev-python/pytest-xdist[${PYTHON_USEDEP}]
+	)
+"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-4.2.0-flags.patch"
+	"${FILESDIR}/${PN}-4.2.0-cython-3.patch"
+	"${FILESDIR}/${PN}-4.2.1-integer-division-for-randint.patch"
+	"${FILESDIR}/${PN}-4.2.1-x86-time.patch"
+)
+
+python_prepare_all() {
+	if ! use webkit; then
+		eapply "${FILESDIR}/${PN}-4.2.0-no-webkit.patch"
+	fi
+
+	distutils-r1_python_prepare_all
+}
+
+src_configure() {
+	setup-wxwidgets
+}
+
+python_compile() {
+	DOXYGEN="$(type -P doxygen)" ${PYTHON} build.py dox etg --nodoc || die
+
+	# Refresh the bundled/pregenerated sip files
+	"${EPYTHON}" build.py sip || die
+
+	# Build the bindings
+	"${EPYTHON}" build.py build_py \
+		--use_syswx \
+		--no_magic \
+		--jobs="$(makeopts_jobs)" \
+		--verbose \
+		--release || die
+}
+
+python_test() {
+	local EPYTEST_DESELECT=(
+		# virtx probably
+		unittests/test_display.py::display_Tests::test_display
+		unittests/test_frame.py::frame_Tests::test_frameRestore
+		unittests/test_mousemanager.py::mousemanager_Tests::test_mousemanager1
+		unittests/test_uiaction.py::uiaction_KeyboardTests::test_uiactionKeyboardChar
+		unittests/test_uiaction.py::uiaction_KeyboardTests::test_uiactionKeyboardKeyDownUp
+		unittests/test_uiaction.py::uiaction_MouseTests
+
+		# assertion (TODO)
+		unittests/test_aboutdlg.py::aboutdlg_Tests::test_aboutdlgGeneric
+		unittests/test_lib_agw_piectrl.py::lib_agw_piectrl_Tests::test_lib_agw_piectrlCtor
+
+		# seems to rely on state from a previous test (sigh)
+		unittests/test_lib_agw_persist_persistencemanager.py::lib_agw_persist_persistencemanager_Tests::test_persistencemanagerRestore
+
+		# requires Spanish localization
+		unittests/test_intl.py::intl_Tests::test_intlGetString
+
+		# TODO
+		unittests/test_tipwin.py::tipwin_Tests::test_tipwinCtor
+		unittests/test_lib_pubsub_provider.py::lib_pubsub_Except::test1
+		unittests/test_windowid.py::IdManagerTest::test_newIdRef03
+	)
+	local EPYTEST_IGNORE=()
+	if ! use webkit; then
+		EPYTEST_IGNORE+=( unittests/test_webview.py )
+	fi
+
+	# We use pytest-forked as opensuse does to avoid tests corrupting each
+	# other.
+	virtx epytest --forked -n "$(makeopts_jobs)" unittests
+}
+
+python_install() {
+	distutils-r1_python_install --skip-build
+}


^ permalink raw reply related	[flat|nested] 5+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-python/wxpython/files/, dev-python/wxpython/
@ 2019-05-24 18:20 Virgil Dupras
  0 siblings, 0 replies; 5+ messages in thread
From: Virgil Dupras @ 2019-05-24 18:20 UTC (permalink / raw
  To: gentoo-commits

commit:     e8e14b564d7f9cc694a1a96031703be15b2d41bc
Author:     Virgil Dupras <vdupras <AT> gentoo <DOT> org>
AuthorDate: Fri May 24 18:19:34 2019 +0000
Commit:     Virgil Dupras <vdupras <AT> gentoo <DOT> org>
CommitDate: Fri May 24 18:19:34 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e8e14b56

dev-python/wxpython: bump to 4.0.6

Also, take over maintainership.

Closes: https://bugs.gentoo.org/632602
Closes: https://bugs.gentoo.org/667318
Signed-off-by: Virgil Dupras <vdupras <AT> gentoo.org>
Package-Manager: Portage-2.3.66, Repoman-2.3.11

 dev-python/wxpython/Manifest                       |  1 +
 .../wxpython/files/wxpython-4.0.6-no-webkit.patch  | 27 +++++++
 .../files/wxpython-4.0.6-skip-broken-tests.patch   | 91 ++++++++++++++++++++++
 dev-python/wxpython/metadata.xml                   |  6 +-
 dev-python/wxpython/wxpython-4.0.6.ebuild          | 89 +++++++++++++++++++++
 5 files changed, 213 insertions(+), 1 deletion(-)

diff --git a/dev-python/wxpython/Manifest b/dev-python/wxpython/Manifest
index 7c15b2e2009..1870b55b866 100644
--- a/dev-python/wxpython/Manifest
+++ b/dev-python/wxpython/Manifest
@@ -1,2 +1,3 @@
+DIST wxPython-4.0.6.tar.gz 68815031 BLAKE2B 49367f5d0867c28893c43d54c4ad6001807bdc95d81327082e3c88fd796e5e2daafcf6b70252828bdcfaaec8b42ba64e881575d209eb4f61a85f58ebd79e8ae4 SHA512 bfe799e1a0987cb57f2e31199cdb522471aaa08bb3b642fdf4130f4219b81487d4b6252f7a8afd3af7cdaeef2e992cecfc581e97d8b42307a4e0a8c9009db301
 DIST wxPython-demo-3.0.2.0.tar.bz2 3992212 BLAKE2B 9defe133e3863be5ae07b7adb4bcb94688487e9dd9f5ab1f768d2f5942f30d05ff678f1ba74241d9bafde3584e3c68ffeae4978117aaa300e23165140e6a6d44 SHA512 361ecaa7dfe5bae0757e04215c564370eaf8e5260ead45007f9d70439c15701725c3cbcd76691a5191258bef24fd200ebd61347a3fd920d888137bfc98a16702
 DIST wxPython-src-3.0.2.0.tar.bz2 58304944 BLAKE2B 1144acf2cfa0a18aa2f90aabe81aaeca54d3fe6139818267dbc031accbae38035478a64ec084fe8bb8b89126fb70ff96e68981026df8ad3fc82e81c6d0e22d1a SHA512 a3798e89ff19344253aac7d771971e519f7fa9723e82bd97e98f16fd7f1572e513170b02295b872dae0b1ae3fa95efc4ef34d078045b839694b4fdad3a27c9e4

diff --git a/dev-python/wxpython/files/wxpython-4.0.6-no-webkit.patch b/dev-python/wxpython/files/wxpython-4.0.6-no-webkit.patch
new file mode 100644
index 00000000000..795de3a933f
--- /dev/null
+++ b/dev-python/wxpython/files/wxpython-4.0.6-no-webkit.patch
@@ -0,0 +1,27 @@
+diff -ru wxPython-4.0.5-orig/wscript wxPython-4.0.5/wscript
+--- wxPython-4.0.5-orig/wscript	2019-05-18 22:03:12.000000000 -0400
++++ wxPython-4.0.5/wscript	2019-05-22 07:59:46.522966555 -0400
+@@ -230,15 +230,6 @@
+                        uselib_store='WXGL', mandatory=True,
+                        msg='Finding libs for WXGL')
+ 
+-        if cfg.checkSetup(wxConfigDir, 'wxUSE_WEBVIEW'):
+-            wv_libs = '--libs webview,core,net'
+-        else:
+-            wv_libs = '--libs core,net'
+-        conf.check_cfg(path=conf.options.wx_config, package='',
+-                       args='--cxxflags ' + wv_libs + rpath,
+-                       uselib_store='WXWEBVIEW', mandatory=True,
+-                       msg='Finding libs for WXWEBVIEW')
+-
+         if isDarwin:
+             conf.check_cfg(path=conf.options.wx_config, package='',
+                            args='--cxxflags --libs core,net' + rpath,
+@@ -591,7 +582,6 @@
+     makeETGRule(bld, 'etg/_stc.py',        '_stc',       'WXSTC')
+     makeETGRule(bld, 'etg/_html.py',       '_html',      'WXHTML')
+     makeETGRule(bld, 'etg/_glcanvas.py',   '_glcanvas',  'WXGL')
+-    makeETGRule(bld, 'etg/_html2.py',      '_html2',     'WXWEBVIEW')
+     makeETGRule(bld, 'etg/_xml.py',        '_xml',       'WXXML')
+     makeETGRule(bld, 'etg/_xrc.py',        '_xrc',       'WXXRC')
+     makeETGRule(bld, 'etg/_richtext.py',   '_richtext',  'WXHTML WXRICHTEXT')

diff --git a/dev-python/wxpython/files/wxpython-4.0.6-skip-broken-tests.patch b/dev-python/wxpython/files/wxpython-4.0.6-skip-broken-tests.patch
new file mode 100644
index 00000000000..22a56162726
--- /dev/null
+++ b/dev-python/wxpython/files/wxpython-4.0.6-skip-broken-tests.patch
@@ -0,0 +1,91 @@
+diff -ru wxPython-4.0.6-orig/unittests/test_frame.py wxPython-4.0.6/unittests/test_frame.py
+--- wxPython-4.0.6-orig/unittests/test_frame.py	2019-05-21 19:12:12.000000000 -0400
++++ wxPython-4.0.6/unittests/test_frame.py	2019-05-24 10:15:51.350004356 -0400
+@@ -50,7 +50,7 @@
+         f.Close()
+ 
+ 
+-    def test_frameRestore(self):
++    def xtest_frameRestore(self):
+         f = wx.Frame(self.frame, title="Title", pos=(50,50), size=(100,100))
+         f.Show()
+         f.Maximize()
+diff -ru wxPython-4.0.6-orig/unittests/test_graphics.py wxPython-4.0.6/unittests/test_graphics.py
+--- wxPython-4.0.6-orig/unittests/test_graphics.py	2019-05-21 19:12:12.000000000 -0400
++++ wxPython-4.0.6/unittests/test_graphics.py	2019-05-24 10:16:06.520256643 -0400
+@@ -23,7 +23,7 @@
+         gc = wx.GraphicsContext.Create(img)
+         self.assertTrue(gc.IsOk())
+ 
+-    def test_gcCreate4(self):
++    def xtest_gcCreate4(self):
+         class MyPanel(wx.Panel):
+             def __init__(self, parent):
+                 super(MyPanel, self).__init__(parent)
+diff -ru wxPython-4.0.6-orig/unittests/test_lib_pubsub_provider.py wxPython-4.0.6/unittests/test_lib_pubsub_provider.py
+--- wxPython-4.0.6-orig/unittests/test_lib_pubsub_provider.py	2019-05-21 19:12:12.000000000 -0400
++++ wxPython-4.0.6/unittests/test_lib_pubsub_provider.py	2019-05-24 10:16:49.649969339 -0400
+@@ -49,7 +49,7 @@
+ 
+ class lib_pubsub_Except(wtc.PubsubTestCase):
+ 
+-    def test1(self):
++    def xtest1(self):
+ 
+         self.pub.addTopicDefnProvider(my_topics, self.pub.TOPIC_TREE_FROM_CLASS)
+ 
+diff -ru wxPython-4.0.6-orig/unittests/test_lib_pubsub_topicmgr.py wxPython-4.0.6/unittests/test_lib_pubsub_topicmgr.py
+--- wxPython-4.0.6-orig/unittests/test_lib_pubsub_topicmgr.py	2019-05-21 19:12:12.000000000 -0400
++++ wxPython-4.0.6/unittests/test_lib_pubsub_topicmgr.py	2019-05-24 10:17:18.276438743 -0400
+@@ -215,7 +215,7 @@
+         assert 1 == topicMgr.getNumDefnProviders()
+         topicMgr.clearDefnProviders()
+ 
+-    def test20_UseProvider(self):
++    def xtest20_UseProvider(self):
+         #
+         # Test the use of definition providers for topics. We create
+         # two so we can check that more than one can work together.
+diff -ru wxPython-4.0.6-orig/unittests/test_sizer.py wxPython-4.0.6/unittests/test_sizer.py
+--- wxPython-4.0.6-orig/unittests/test_sizer.py	2019-05-21 19:12:12.000000000 -0400
++++ wxPython-4.0.6/unittests/test_sizer.py	2019-05-24 10:18:03.937181671 -0400
+@@ -71,7 +71,7 @@
+         self.assertTrue(items[1].IsSpacer())
+         self.assertTrue(items[2].Border == 5)
+ 
+-    def test_iter(self):
++    def xtest_iter(self):
+         bs = wx.BoxSizer()
+         widgetlist = [wx.Panel(self.frame) for _ in range(5)]
+ 
+diff -ru wxPython-4.0.6-orig/unittests/test_utils.py wxPython-4.0.6/unittests/test_utils.py
+--- wxPython-4.0.6-orig/unittests/test_utils.py	2019-05-21 19:12:12.000000000 -0400
++++ wxPython-4.0.6/unittests/test_utils.py	2019-05-24 11:14:09.399035368 -0400
+@@ -34,7 +34,7 @@
+         with wx.BusyCursor():
+             self.myYield()
+ 
+-    def test_utilsSomeOtherStuff(self):
++    def xtest_utilsSomeOtherStuff(self):
+         wx.GetBatteryState()
+         wx.GetPowerType()
+         wx.GetKeyState(wx.WXK_F1)
+diff -ru wxPython-4.0.6-orig/unittests/test_windowid.py wxPython-4.0.6/unittests/test_windowid.py
+--- wxPython-4.0.6-orig/unittests/test_windowid.py	2019-05-21 19:12:12.000000000 -0400
++++ wxPython-4.0.6/unittests/test_windowid.py	2019-05-24 10:18:24.158508491 -0400
+@@ -28,12 +28,12 @@
+             assert isinstance(ref, wx.WindowIDRef)
+ 
+ 
+-    def test_newIdRef03(self):
++    def xtest_newIdRef03(self):
+         """Check that Auto ID Management is enabled (--enable-autoidman)"""
+         # This test is expected to fail if autoID mangagement is turned on
+-        # because a reference to the ID is not being saved, so it will be 
++        # because a reference to the ID is not being saved, so it will be
+         # unreserved when the first widget is destroyed.
+-        
++
+         id = wx.Window.NewControlId()
+         b = wx.Button(self.frame, id, 'button')
+         b.Destroy()

diff --git a/dev-python/wxpython/metadata.xml b/dev-python/wxpython/metadata.xml
index f6588d2f5c3..7012622a081 100644
--- a/dev-python/wxpython/metadata.xml
+++ b/dev-python/wxpython/metadata.xml
@@ -1,6 +1,10 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
 <pkgmetadata>
+	<maintainer type="person">
+		<email>vdupras@gentoo.org</email>
+		<name>Virgil Dupras</name>
+	</maintainer>
 	<maintainer type="project">
 		<email>wxwidgets@gentoo.org</email>
 		<name>Gentoo wxWidgets Project</name>
@@ -13,6 +17,6 @@
 		<flag name="examples">Install interactive demo module browser and sample applets.</flag>
 	</use>
 	<upstream>
-		<remote-id type="sourceforge">wxpython</remote-id>
+		<remote-id type="github">wxWidgets/Phoenix</remote-id>
 	</upstream>
 </pkgmetadata>

diff --git a/dev-python/wxpython/wxpython-4.0.6.ebuild b/dev-python/wxpython/wxpython-4.0.6.ebuild
new file mode 100644
index 00000000000..04e6a637c7d
--- /dev/null
+++ b/dev-python/wxpython/wxpython-4.0.6.ebuild
@@ -0,0 +1,89 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+# wxPython 4 supports python 2.7, but because it's going EOL soon and to ease
+# transition from wxPython 3.x, we make this package py3-only.
+PYTHON_COMPAT=( python3_{5,6,7} )
+WX_GTK_VER="3.0-gtk3"
+
+inherit distutils-r1 multiprocessing virtualx wxwidgets
+
+MY_PN="wxPython"
+
+DESCRIPTION="A blending of the wxWindows C++ class library with Python"
+HOMEPAGE="http://www.wxpython.org/"
+SRC_URI="mirror://pypi/${P:0:1}/${MY_PN}/${MY_PN}-${PV}.tar.gz"
+
+LICENSE="wxWinLL-3"
+SLOT="4.0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86"
+IUSE="test webkit"
+
+# wxPython doesn't seem to be able to optionally disable features. webkit is
+# optionally patched out because it's so huge, but other elements are not,
+# which makes us have to require all features from wxGTK
+RDEPEND="
+	>=x11-libs/wxGTK-3.0.4-r301:${WX_GTK_VER}=[gstreamer,libnotify,opengl,sdl,tiff,webkit?,X]
+	media-libs/libpng:0=
+	media-libs/tiff:0
+	virtual/jpeg:0"
+
+DEPEND="${RDEPEND}
+	app-doc/doxygen
+	dev-python/pathlib2[${PYTHON_USEDEP}]
+	dev-python/setuptools[${PYTHON_USEDEP}]
+	dev-python/six[${PYTHON_USEDEP}]
+	test? (
+		${VIRTUALX_DEPEND}
+		dev-python/appdirs[${PYTHON_USEDEP}]
+		dev-python/numpy[${PYTHON_USEDEP}]
+		dev-python/pillow[${PYTHON_USEDEP}]
+		dev-python/pytest[${PYTHON_USEDEP}]
+	)"
+
+S="${WORKDIR}/${MY_PN}-${PV}"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-4.0.6-skip-broken-tests.patch"
+)
+
+python_prepare_all() {
+	if ! use webkit; then
+		eapply "${FILESDIR}/${PN}-4.0.6-no-webkit.patch"
+		rm unittests/test_webview.py || die
+	fi
+	# Most of these tests disabled below fail because of the virtx/portage
+	# environment, but some fail for unknown reasons.
+	rm unittests/test_uiaction.py \
+		unittests/test_notifmsg.py \
+		unittests/test_mousemanager.py \
+		unittests/test_display.py \
+		unittests/test_pi_import.py \
+		unittests/test_lib_agw_thumbnailctrl.py \
+		unittests/test_sound.py || die
+
+	distutils-r1_python_prepare_all
+}
+
+src_configure() {
+	setup-wxwidgets
+}
+
+python_compile() {
+	DOXYGEN=/usr/bin/doxygen ${PYTHON} build.py dox etg --nodoc || die
+	${PYTHON} build.py build_py \
+		--use_syswx \
+		--no_magic \
+		--jobs=$(makeopts_jobs) \
+		--release || die
+}
+
+python_install() {
+	distutils-r1_python_install --skip-build
+}
+
+python_test() {
+	virtx pytest -vv unittests || die "Test failed with ${EPYTHON}"
+}


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2025-03-10  2:46 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-18  4:49 [gentoo-commits] repo/gentoo:master commit in: dev-python/wxpython/files/, dev-python/wxpython/ Sam James
  -- strict thread matches above, loose matches on Subject: below --
2025-03-10  2:45 Sam James
2025-02-18 22:10 Sam James
2024-06-17 23:45 Sam James
2019-05-24 18:20 Virgil Dupras

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox