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

commit:     14f9b996d4ffbc5f9ea6af578521806332f39c66
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Thu Jun  1 07:06:55 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Jun  1 07:24:05 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=14f9b996

dev-python/pycryptodome: enable py3.12

Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../pycryptodome-3.18.0-python3.12-unittest.patch  | 22 ++++++++++++++++++++++
 dev-python/pycryptodome/pycryptodome-3.18.0.ebuild |  7 ++++---
 2 files changed, 26 insertions(+), 3 deletions(-)

diff --git a/dev-python/pycryptodome/files/pycryptodome-3.18.0-python3.12-unittest.patch b/dev-python/pycryptodome/files/pycryptodome-3.18.0-python3.12-unittest.patch
new file mode 100644
index 000000000000..6e49a784af16
--- /dev/null
+++ b/dev-python/pycryptodome/files/pycryptodome-3.18.0-python3.12-unittest.patch
@@ -0,0 +1,22 @@
+https://github.com/Legrandin/pycryptodome/pull/746
+
+From 9d70fbca927516b31ef61fd7cc3ed3e0ebc95fa6 Mon Sep 17 00:00:00 2001
+From: Sam James <sam@gentoo.org>
+Date: Thu, 1 Jun 2023 08:03:18 +0100
+Subject: [PATCH] Replace deprecated unittest aliases for Python 3.12
+
+See https://docs.python.org/3.12/whatsnew/3.12.html#removed.
+--- a/lib/Crypto/SelfTest/PublicKey/test_import_ECC.py
++++ b/lib/Crypto/SelfTest/PublicKey/test_import_ECC.py
+@@ -2269,9 +2269,9 @@ def test_import_x509_pem(self):
+     def test_import_openssh_public(self):
+         key_file = load_file("ecc_ed25519_public_openssh.txt")
+         key = ECC._import_openssh_public(key_file)
+-        self.failIf(key.has_private())
++        self.assertFalse(key.has_private())
+         key = ECC.import_key(key_file)
+-        self.failIf(key.has_private())
++        self.assertFalse(key.has_private())
+ 
+     def test_import_openssh_private_clear(self):
+         key_file = load_file("ecc_ed25519_private_openssh.pem")

diff --git a/dev-python/pycryptodome/pycryptodome-3.18.0.ebuild b/dev-python/pycryptodome/pycryptodome-3.18.0.ebuild
index 71faf0d17415..cb0b4894d406 100644
--- a/dev-python/pycryptodome/pycryptodome-3.18.0.ebuild
+++ b/dev-python/pycryptodome/pycryptodome-3.18.0.ebuild
@@ -5,7 +5,7 @@ EAPI=8
 
 DISTUTILS_EXT=1
 DISTUTILS_USE_PEP517=setuptools
-PYTHON_COMPAT=( python3_{10..11} pypy3 )
+PYTHON_COMPAT=( python3_{10..12} pypy3 )
 PYTHON_REQ_USE="threads(+)"
 
 inherit distutils-r1
@@ -26,11 +26,11 @@ SLOT="0"
 KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris"
 
 DEPEND="
-	dev-libs/gmp:0=
+	dev-libs/gmp:=
 	>=dev-libs/libtomcrypt-1.18.2-r1:=
 "
 BDEPEND="
-	virtual/python-cffi[${PYTHON_USEDEP}]
+	$(python_gen_cond_dep 'dev-python/cffi[${PYTHON_USEDEP}]' 'python*')
 "
 RDEPEND="
 	${DEPEND}
@@ -40,6 +40,7 @@ RDEPEND="
 
 PATCHES=(
 	"${FILESDIR}/pycryptodome-3.10.1-system-libtomcrypt.patch"
+	"${FILESDIR}/pycryptodome-3.18.0-python3.12-unittest.patch"
 )
 
 python_prepare_all() {


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

* [gentoo-commits] repo/gentoo:master commit in: dev-python/pycryptodome/files/, dev-python/pycryptodome/
@ 2023-11-14 19:01 Michał Górny
  0 siblings, 0 replies; 4+ messages in thread
From: Michał Górny @ 2023-11-14 19:01 UTC (permalink / raw
  To: gentoo-commits

commit:     b1f4a60612395dd8af27ea39b4b72a3827ba1f5f
Author:     Alfred Wingate <parona <AT> protonmail <DOT> com>
AuthorDate: Tue Nov 14 17:20:19 2023 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Tue Nov 14 18:56:39 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b1f4a606

dev-python/pycryptodome: add 3.19.0

Signed-off-by: Alfred Wingate <parona <AT> protonmail.com>
Closes: https://github.com/gentoo/gentoo/pull/33824
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 dev-python/pycryptodome/Manifest                   |   1 +
 ...ycryptodome-3.19.0-fix-verbosity-in-tests.patch | 120 +++++++++++++++++++++
 dev-python/pycryptodome/pycryptodome-3.19.0.ebuild |  61 +++++++++++
 3 files changed, 182 insertions(+)

diff --git a/dev-python/pycryptodome/Manifest b/dev-python/pycryptodome/Manifest
index 52265221b4a2..7d8268b41a31 100644
--- a/dev-python/pycryptodome/Manifest
+++ b/dev-python/pycryptodome/Manifest
@@ -1 +1,2 @@
 DIST pycryptodome-3.18.0.gh.tar.gz 16720227 BLAKE2B dfdc3a7cc0b1aea1e7b7d8f6e8bcf651ca92f0020e2c51849512d00e716283537feb884cacdc655d99a6b992305db9b899172d022bc9ff65d6349ee40b40c4d5 SHA512 a30a6b406bfd1d4288169924924636246c36999ca1e14c5cb70bd2f71ce25739dae04726ca97bdaebf7a8b36927cc6f617fbe2599fad48512a2c5e016a528247
+DIST pycryptodome-3.19.0.gh.tar.gz 17153954 BLAKE2B 5ecaacce490e5eec052d632b1427a4e36ba19a863c28934f53f247b945bb32a1367aeaf1b8669018978bd19d53c28a00f711158c6be014779c47c48f263b2e8c SHA512 1afa71336da38efb32f79d87b442a1d50537a6908ec153be7a087027a8540cebabab12922557c92e501f2d6da5c2f35466d3bbe6a3de44540de7278069691290

diff --git a/dev-python/pycryptodome/files/pycryptodome-3.19.0-fix-verbosity-in-tests.patch b/dev-python/pycryptodome/files/pycryptodome-3.19.0-fix-verbosity-in-tests.patch
new file mode 100644
index 000000000000..7d54e5e4c2a7
--- /dev/null
+++ b/dev-python/pycryptodome/files/pycryptodome-3.19.0-fix-verbosity-in-tests.patch
@@ -0,0 +1,120 @@
+https://github.com/Legrandin/pycryptodome/issues/765
+https://github.com/Legrandin/pycryptodome/commit/87ff66373a5b80cddc9b0dd76e9bb8c15f6a8e50
+
+From 87ff66373a5b80cddc9b0dd76e9bb8c15f6a8e50 Mon Sep 17 00:00:00 2001
+From: Helder Eijs <helderijs@gmail.com>
+Date: Sun, 17 Sep 2023 23:32:02 +0200
+Subject: [PATCH] Fix verbosity problem in tests
+
+--- a/lib/Crypto/SelfTest/Protocol/test_ecdh.py
++++ b/lib/Crypto/SelfTest/Protocol/test_ecdh.py
+@@ -72,6 +72,8 @@ def ecdh_test_rev(self,
+ 
+ class TestVectorsECDHWycheproof(unittest.TestCase):
+ 
++    desc = "Wycheproof ECDH tests"
++
+     def add_tests(self, filename):
+ 
+         def curve(g):
+@@ -107,7 +109,6 @@ def shortDescription(self):
+         return self.desc
+ 
+     def test_verify(self, tv):
+-        self._id = "Wycheproof ECDH Verify Test #%d (%s, %s)" % (tv.id, tv.comment, tv.filename)
+ 
+         if len(tv.public) == 0:
+             return
+@@ -138,7 +139,7 @@ def test_verify(self, tv):
+ 
+     def runTest(self):
+         for tv in self.tv:
+-            self.desc = "Test #%d (%s) - %s" % (tv.id, tv.filename, tv.comment)
++            self.desc = "Wycheproof ECDH Verify Test #%d (%s, %s)" % (tv.id, tv.comment, tv.filename)
+             self.test_verify(tv)
+ 
+ 
+--- a/lib/Crypto/SelfTest/__init__.py
++++ b/lib/Crypto/SelfTest/__init__.py
+@@ -28,18 +28,19 @@
+ application runs.
+ """
+ 
+-__revision__ = "$Id$"
+-
+ import sys
+ import unittest
++from importlib import import_module
+ from Crypto.Util.py3compat import StringIO
+ 
++
+ class SelfTestError(Exception):
+     def __init__(self, message, result):
+         Exception.__init__(self, message, result)
+         self.message = message
+         self.result = result
+ 
++
+ def run(module=None, verbosity=0, stream=None, tests=None, config=None, **kwargs):
+     """Execute self-tests.
+ 
+@@ -77,21 +78,25 @@ def run(module=None, verbosity=0, stream=None, tests=None, config=None, **kwargs
+         raise SelfTestError("Self-test failed", result)
+     return result
+ 
++
+ def get_tests(config={}):
+     tests = []
+-    from Crypto.SelfTest import Cipher; tests += Cipher.get_tests(config=config)
+-    from Crypto.SelfTest import Hash;   tests += Hash.get_tests(config=config)
+-    from Crypto.SelfTest import Protocol; tests += Protocol.get_tests(config=config)
+-    from Crypto.SelfTest import PublicKey; tests += PublicKey.get_tests(config=config)
+-    from Crypto.SelfTest import Random; tests += Random.get_tests(config=config)
+-    from Crypto.SelfTest import Util;   tests += Util.get_tests(config=config)
+-    from Crypto.SelfTest import Signature;   tests += Signature.get_tests(config=config)
+-    from Crypto.SelfTest import IO;   tests += IO.get_tests(config=config)
+-    from Crypto.SelfTest import Math;   tests += Math.get_tests(config=config)
++
++    module_names = [
++        "Cipher", "Hash", "Protocol", "PublicKey", "Random",
++        "Util", "Signature", "IO", "Math",
++        ]
++
++    for name in module_names:
++        module = import_module("Crypto.SelfTest." + name)
++        tests += module.get_tests(config=config)
++
+     return tests
+ 
++
+ if __name__ == '__main__':
+-    suite = lambda: unittest.TestSuite(get_tests())
++    def suite():
++        return unittest.TestSuite(get_tests())
+     unittest.main(defaultTest='suite')
+ 
+ # vim:set ts=4 sw=4 sts=4 expandtab:
+--- a/lib/Crypto/SelfTest/__main__.py
++++ b/lib/Crypto/SelfTest/__main__.py
+@@ -26,7 +26,7 @@
+ 
+ from Crypto import SelfTest
+ 
+-slow_tests = not "--skip-slow-tests" in sys.argv
++slow_tests = not ("--skip-slow-tests" in sys.argv)
+ if not slow_tests:
+     print("Skipping slow tests")
+ 
+@@ -34,5 +34,10 @@
+ if wycheproof_warnings:
+     print("Printing Wycheproof warnings")
+ 
+-config = {'slow_tests' : slow_tests, 'wycheproof_warnings' : wycheproof_warnings }
+-SelfTest.run(stream=sys.stdout, verbosity=1, config=config)
++if "-v" in sys.argv:
++    verbosity=2
++else:
++    verbosity=1
++
++config = {'slow_tests': slow_tests, 'wycheproof_warnings': wycheproof_warnings}
++SelfTest.run(stream=sys.stdout, verbosity=verbosity, config=config)

diff --git a/dev-python/pycryptodome/pycryptodome-3.19.0.ebuild b/dev-python/pycryptodome/pycryptodome-3.19.0.ebuild
new file mode 100644
index 000000000000..f7c07f2ea6a3
--- /dev/null
+++ b/dev-python/pycryptodome/pycryptodome-3.19.0.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2023 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..12} pypy3 )
+PYTHON_REQ_USE="threads(+)"
+
+inherit distutils-r1
+
+DESCRIPTION="A self-contained cryptographic library for Python"
+HOMEPAGE="
+	https://www.pycryptodome.org/
+	https://github.com/Legrandin/pycryptodome/
+	https://pypi.org/project/pycryptodome/
+"
+SRC_URI="
+	https://github.com/Legrandin/pycryptodome/archive/v${PV}.tar.gz
+		-> ${P}.gh.tar.gz
+"
+
+LICENSE="BSD-2 Unlicense"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
+
+DEPEND="
+	dev-libs/gmp:=
+	>=dev-libs/libtomcrypt-1.18.2-r1:=
+"
+BDEPEND="
+	$(python_gen_cond_dep 'dev-python/cffi[${PYTHON_USEDEP}]' 'python*')
+"
+RDEPEND="
+	${DEPEND}
+	${BDEPEND}
+"
+
+PATCHES=(
+	"${FILESDIR}/pycryptodome-3.10.1-system-libtomcrypt.patch"
+	"${FILESDIR}/pycryptodome-3.19.0-fix-verbosity-in-tests.patch"
+)
+
+python_prepare_all() {
+	# make sure we're unbundling it correctly
+	rm -r src/libtom || die
+
+	distutils-r1_python_prepare_all
+}
+
+python_test() {
+	local -x PYTHONPATH=${S}/test_vectors:${PYTHONPATH}
+	"${EPYTHON}" - <<-EOF || die
+		import sys
+		from Crypto import SelfTest
+		SelfTest.run(verbosity=2, stream=sys.stdout)
+	EOF
+
+	# TODO: run cmake tests from src/test?
+}


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

* [gentoo-commits] repo/gentoo:master commit in: dev-python/pycryptodome/files/, dev-python/pycryptodome/
@ 2023-12-31  7:17 Michał Górny
  0 siblings, 0 replies; 4+ messages in thread
From: Michał Górny @ 2023-12-31  7:17 UTC (permalink / raw
  To: gentoo-commits

commit:     3daa616bc23a431bf9311c787346c750800098d3
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Sun Dec 31 07:16:17 2023 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Sun Dec 31 07:17:29 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3daa616b

dev-python/pycryptodome: Remove old

Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 dev-python/pycryptodome/Manifest                   |   1 -
 ...ycryptodome-3.19.0-fix-verbosity-in-tests.patch | 120 ---------------------
 dev-python/pycryptodome/pycryptodome-3.19.0.ebuild |  61 -----------
 3 files changed, 182 deletions(-)

diff --git a/dev-python/pycryptodome/Manifest b/dev-python/pycryptodome/Manifest
index bc2bf065d8c2..9447883fe3c6 100644
--- a/dev-python/pycryptodome/Manifest
+++ b/dev-python/pycryptodome/Manifest
@@ -1,2 +1 @@
-DIST pycryptodome-3.19.0.gh.tar.gz 17153954 BLAKE2B 5ecaacce490e5eec052d632b1427a4e36ba19a863c28934f53f247b945bb32a1367aeaf1b8669018978bd19d53c28a00f711158c6be014779c47c48f263b2e8c SHA512 1afa71336da38efb32f79d87b442a1d50537a6908ec153be7a087027a8540cebabab12922557c92e501f2d6da5c2f35466d3bbe6a3de44540de7278069691290
 DIST pycryptodome-3.19.1.gh.tar.gz 17158420 BLAKE2B 2180bb37e2295f0499c6d00237207513ad6c186ff8fd8fac466cc43efa9b068cf8a272b5ae30da08d37db88d354d41c0b426643743251ea8460abb6ff627e3be SHA512 103910b385578732e356145247d3c1a4a3b0fe8acf22ce91f1c1155500cce2342e5caa0dff0a30825b11d7a614853c2dcb8657628f4d65682f6e543adb4db240

diff --git a/dev-python/pycryptodome/files/pycryptodome-3.19.0-fix-verbosity-in-tests.patch b/dev-python/pycryptodome/files/pycryptodome-3.19.0-fix-verbosity-in-tests.patch
deleted file mode 100644
index 7d54e5e4c2a7..000000000000
--- a/dev-python/pycryptodome/files/pycryptodome-3.19.0-fix-verbosity-in-tests.patch
+++ /dev/null
@@ -1,120 +0,0 @@
-https://github.com/Legrandin/pycryptodome/issues/765
-https://github.com/Legrandin/pycryptodome/commit/87ff66373a5b80cddc9b0dd76e9bb8c15f6a8e50
-
-From 87ff66373a5b80cddc9b0dd76e9bb8c15f6a8e50 Mon Sep 17 00:00:00 2001
-From: Helder Eijs <helderijs@gmail.com>
-Date: Sun, 17 Sep 2023 23:32:02 +0200
-Subject: [PATCH] Fix verbosity problem in tests
-
---- a/lib/Crypto/SelfTest/Protocol/test_ecdh.py
-+++ b/lib/Crypto/SelfTest/Protocol/test_ecdh.py
-@@ -72,6 +72,8 @@ def ecdh_test_rev(self,
- 
- class TestVectorsECDHWycheproof(unittest.TestCase):
- 
-+    desc = "Wycheproof ECDH tests"
-+
-     def add_tests(self, filename):
- 
-         def curve(g):
-@@ -107,7 +109,6 @@ def shortDescription(self):
-         return self.desc
- 
-     def test_verify(self, tv):
--        self._id = "Wycheproof ECDH Verify Test #%d (%s, %s)" % (tv.id, tv.comment, tv.filename)
- 
-         if len(tv.public) == 0:
-             return
-@@ -138,7 +139,7 @@ def test_verify(self, tv):
- 
-     def runTest(self):
-         for tv in self.tv:
--            self.desc = "Test #%d (%s) - %s" % (tv.id, tv.filename, tv.comment)
-+            self.desc = "Wycheproof ECDH Verify Test #%d (%s, %s)" % (tv.id, tv.comment, tv.filename)
-             self.test_verify(tv)
- 
- 
---- a/lib/Crypto/SelfTest/__init__.py
-+++ b/lib/Crypto/SelfTest/__init__.py
-@@ -28,18 +28,19 @@
- application runs.
- """
- 
--__revision__ = "$Id$"
--
- import sys
- import unittest
-+from importlib import import_module
- from Crypto.Util.py3compat import StringIO
- 
-+
- class SelfTestError(Exception):
-     def __init__(self, message, result):
-         Exception.__init__(self, message, result)
-         self.message = message
-         self.result = result
- 
-+
- def run(module=None, verbosity=0, stream=None, tests=None, config=None, **kwargs):
-     """Execute self-tests.
- 
-@@ -77,21 +78,25 @@ def run(module=None, verbosity=0, stream=None, tests=None, config=None, **kwargs
-         raise SelfTestError("Self-test failed", result)
-     return result
- 
-+
- def get_tests(config={}):
-     tests = []
--    from Crypto.SelfTest import Cipher; tests += Cipher.get_tests(config=config)
--    from Crypto.SelfTest import Hash;   tests += Hash.get_tests(config=config)
--    from Crypto.SelfTest import Protocol; tests += Protocol.get_tests(config=config)
--    from Crypto.SelfTest import PublicKey; tests += PublicKey.get_tests(config=config)
--    from Crypto.SelfTest import Random; tests += Random.get_tests(config=config)
--    from Crypto.SelfTest import Util;   tests += Util.get_tests(config=config)
--    from Crypto.SelfTest import Signature;   tests += Signature.get_tests(config=config)
--    from Crypto.SelfTest import IO;   tests += IO.get_tests(config=config)
--    from Crypto.SelfTest import Math;   tests += Math.get_tests(config=config)
-+
-+    module_names = [
-+        "Cipher", "Hash", "Protocol", "PublicKey", "Random",
-+        "Util", "Signature", "IO", "Math",
-+        ]
-+
-+    for name in module_names:
-+        module = import_module("Crypto.SelfTest." + name)
-+        tests += module.get_tests(config=config)
-+
-     return tests
- 
-+
- if __name__ == '__main__':
--    suite = lambda: unittest.TestSuite(get_tests())
-+    def suite():
-+        return unittest.TestSuite(get_tests())
-     unittest.main(defaultTest='suite')
- 
- # vim:set ts=4 sw=4 sts=4 expandtab:
---- a/lib/Crypto/SelfTest/__main__.py
-+++ b/lib/Crypto/SelfTest/__main__.py
-@@ -26,7 +26,7 @@
- 
- from Crypto import SelfTest
- 
--slow_tests = not "--skip-slow-tests" in sys.argv
-+slow_tests = not ("--skip-slow-tests" in sys.argv)
- if not slow_tests:
-     print("Skipping slow tests")
- 
-@@ -34,5 +34,10 @@
- if wycheproof_warnings:
-     print("Printing Wycheproof warnings")
- 
--config = {'slow_tests' : slow_tests, 'wycheproof_warnings' : wycheproof_warnings }
--SelfTest.run(stream=sys.stdout, verbosity=1, config=config)
-+if "-v" in sys.argv:
-+    verbosity=2
-+else:
-+    verbosity=1
-+
-+config = {'slow_tests': slow_tests, 'wycheproof_warnings': wycheproof_warnings}
-+SelfTest.run(stream=sys.stdout, verbosity=verbosity, config=config)

diff --git a/dev-python/pycryptodome/pycryptodome-3.19.0.ebuild b/dev-python/pycryptodome/pycryptodome-3.19.0.ebuild
deleted file mode 100644
index 3efc9c7635bc..000000000000
--- a/dev-python/pycryptodome/pycryptodome-3.19.0.ebuild
+++ /dev/null
@@ -1,61 +0,0 @@
-# Copyright 1999-2023 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..12} pypy3 )
-PYTHON_REQ_USE="threads(+)"
-
-inherit distutils-r1
-
-DESCRIPTION="A self-contained cryptographic library for Python"
-HOMEPAGE="
-	https://www.pycryptodome.org/
-	https://github.com/Legrandin/pycryptodome/
-	https://pypi.org/project/pycryptodome/
-"
-SRC_URI="
-	https://github.com/Legrandin/pycryptodome/archive/v${PV}.tar.gz
-		-> ${P}.gh.tar.gz
-"
-
-LICENSE="BSD-2 Unlicense"
-SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
-
-DEPEND="
-	dev-libs/gmp:=
-	>=dev-libs/libtomcrypt-1.18.2-r1:=
-"
-BDEPEND="
-	$(python_gen_cond_dep 'dev-python/cffi[${PYTHON_USEDEP}]' 'python*')
-"
-RDEPEND="
-	${DEPEND}
-	${BDEPEND}
-"
-
-PATCHES=(
-	"${FILESDIR}/pycryptodome-3.10.1-system-libtomcrypt.patch"
-	"${FILESDIR}/pycryptodome-3.19.0-fix-verbosity-in-tests.patch"
-)
-
-python_prepare_all() {
-	# make sure we're unbundling it correctly
-	rm -r src/libtom || die
-
-	distutils-r1_python_prepare_all
-}
-
-python_test() {
-	local -x PYTHONPATH=${S}/test_vectors:${PYTHONPATH}
-	"${EPYTHON}" - <<-EOF || die
-		import sys
-		from Crypto import SelfTest
-		SelfTest.run(verbosity=2, stream=sys.stdout)
-	EOF
-
-	# TODO: run cmake tests from src/test?
-}


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

* [gentoo-commits] repo/gentoo:master commit in: dev-python/pycryptodome/files/, dev-python/pycryptodome/
@ 2024-01-05 14:16 Sam James
  0 siblings, 0 replies; 4+ messages in thread
From: Sam James @ 2024-01-05 14:16 UTC (permalink / raw
  To: gentoo-commits

commit:     a258eee15cc0f85b035ea4e67c977ab51fb852cf
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Jan  5 14:16:17 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Jan  5 14:16:17 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a258eee1

dev-python/pycryptodome: add another gcc 14 configure patch

Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../pycryptodome-3.19.1-gcc14-configure.patch      | 25 ++++++++++++++++++++++
 ...9.1-r1.ebuild => pycryptodome-3.19.1-r2.ebuild} |  0
 2 files changed, 25 insertions(+)

diff --git a/dev-python/pycryptodome/files/pycryptodome-3.19.1-gcc14-configure.patch b/dev-python/pycryptodome/files/pycryptodome-3.19.1-gcc14-configure.patch
index ee87f615b814..f2d24f9cf696 100644
--- a/dev-python/pycryptodome/files/pycryptodome-3.19.1-gcc14-configure.patch
+++ b/dev-python/pycryptodome/files/pycryptodome-3.19.1-gcc14-configure.patch
@@ -1,5 +1,6 @@
 https://github.com/Legrandin/pycryptodome/issues/787
 https://github.com/Legrandin/pycryptodome/commit/b4083688fde0580de6c2a4d36d84da31a2549a2c
+https://github.com/Legrandin/pycryptodome/commit/3f6a86e072ef0e650f04eebf086940e6d8b33c03
 
 From b4083688fde0580de6c2a4d36d84da31a2549a2c Mon Sep 17 00:00:00 2001
 From: Helder Eijs <helderijs@gmail.com>
@@ -44,5 +45,29 @@ Subject: [PATCH] Better autodetect of AES support, in case of aggressive
 +        return ret;
      }
      """
+
+From 3f6a86e072ef0e650f04eebf086940e6d8b33c03 Mon Sep 17 00:00:00 2001
+From: Helder Eijs <helderijs@gmail.com>
+Date: Fri, 29 Dec 2023 14:52:15 +0100
+Subject: [PATCH] Use memset, to avoid emmintrin.h
+
+---
+ compiler_opt.py | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/compiler_opt.py b/compiler_opt.py
+index 57db0a6f..a2711c09 100644
+--- a/compiler_opt.py
++++ b/compiler_opt.py
+@@ -169,7 +169,8 @@ def compiler_supports_aesni():
+     }
+     int main(void) {
+         int ret;
+-        __m128i x = _mm_setzero_si128();
++        __m128i x;
++        memset(&x, 0, sizeof(x));
+         x = f(x, x);
+         memcpy(&ret, &x, sizeof(ret));
+         return ret;
  
 

diff --git a/dev-python/pycryptodome/pycryptodome-3.19.1-r1.ebuild b/dev-python/pycryptodome/pycryptodome-3.19.1-r2.ebuild
similarity index 100%
rename from dev-python/pycryptodome/pycryptodome-3.19.1-r1.ebuild
rename to dev-python/pycryptodome/pycryptodome-3.19.1-r2.ebuild


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

end of thread, other threads:[~2024-01-05 14:17 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-11-14 19:01 [gentoo-commits] repo/gentoo:master commit in: dev-python/pycryptodome/files/, dev-python/pycryptodome/ Michał Górny
  -- strict thread matches above, loose matches on Subject: below --
2024-01-05 14:16 Sam James
2023-12-31  7:17 Michał Górny
2023-06-01  7:24 Sam James

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