* [gentoo-commits] repo/gentoo:master commit in: dev-python/pefile/, dev-python/pefile/files/
@ 2022-12-27 10:23 Sam James
0 siblings, 0 replies; 2+ messages in thread
From: Sam James @ 2022-12-27 10:23 UTC (permalink / raw
To: gentoo-commits
commit: 34d649fc4f68c08c130bb5bda22d921bf48c7fca
Author: Mario Haustein <mario.haustein <AT> hrz <DOT> tu-chemnitz <DOT> de>
AuthorDate: Mon Dec 26 10:23:12 2022 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Tue Dec 27 10:21:36 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=34d649fc
dev-python/pefile: remove dependency to dev-python/future
Closes: https://bugs.gentoo.org/888279
Signed-off-by: Mario Haustein <mario.haustein <AT> hrz.tu-chemnitz.de>
Closes: https://github.com/gentoo/gentoo/pull/28825
Signed-off-by: Sam James <sam <AT> gentoo.org>
.../files/pefile-2022.5.30-remove-future.patch | 115 +++++++++++++++++++++
...file-9999.ebuild => pefile-2022.5.30-r1.ebuild} | 5 +-
dev-python/pefile/pefile-9999.ebuild | 5 +-
3 files changed, 119 insertions(+), 6 deletions(-)
diff --git a/dev-python/pefile/files/pefile-2022.5.30-remove-future.patch b/dev-python/pefile/files/pefile-2022.5.30-remove-future.patch
new file mode 100644
index 000000000000..7f7cc5d29d48
--- /dev/null
+++ b/dev-python/pefile/files/pefile-2022.5.30-remove-future.patch
@@ -0,0 +1,115 @@
+Bug: https://bugs.gentoo.org/888279
+
+From 36bf63f1185b8407ff9b4ce8c1c8e8620d8ae30f Mon Sep 17 00:00:00 2001
+From: Letu Ren <fantasquex@gmail.com>
+Date: Sun, 26 Jun 2022 22:54:27 +0800
+Subject: [PATCH] Remove future from dependencies
+
+Fix: #348
+---
+ ordlookup/__init__.py | 15 ++-------------
+ peutils.py | 7 -------
+ setup.py | 19 ++++---------------
+ tests/pefile_test.py | 3 ---
+ 4 files changed, 6 insertions(+), 38 deletions(-)
+
+diff --git a/ordlookup/__init__.py b/ordlookup/__init__.py
+index c69aee0..8841d74 100644
+--- a/ordlookup/__init__.py
++++ b/ordlookup/__init__.py
+@@ -1,5 +1,3 @@
+-from __future__ import absolute_import
+-import sys
+ from . import ws2_32
+ from . import oleaut32
+
+@@ -15,18 +13,9 @@
+ b"oleaut32.dll": oleaut32.ord_names,
+ }
+
+-PY3 = sys.version_info > (3,)
+
+-if PY3:
+-
+- def formatOrdString(ord_val):
+- return "ord{}".format(ord_val).encode()
+-
+-
+-else:
+-
+- def formatOrdString(ord_val):
+- return b"ord%d" % ord_val
++def formatOrdString(ord_val):
++ return "ord{}".format(ord_val).encode()
+
+
+ def ordLookup(libname, ord_val, make_name=False):
+diff --git a/peutils.py b/peutils.py
+index 34b98f5..4d4b2bd 100644
+--- a/peutils.py
++++ b/peutils.py
+@@ -6,13 +6,6 @@
+
+ All rights reserved.
+ """
+-from __future__ import division
+-from future import standard_library
+-
+-standard_library.install_aliases()
+-from builtins import range
+-from builtins import object
+-
+ import os
+ import re
+ import string
+diff --git a/setup.py b/setup.py
+index c8ab89f..206db6f 100755
+--- a/setup.py
++++ b/setup.py
+@@ -5,8 +5,6 @@
+ import re
+ import sys
+
+-if sys.version_info.major == 3:
+- from io import open
+
+ try:
+ from setuptools import setup, Command
+@@ -25,12 +23,8 @@ def _read_doc():
+ Parse docstring from file 'pefile.py' and avoid importing
+ this module directly.
+ """
+- if sys.version_info.major == 2:
+- with open('pefile.py', 'r') as f:
+- tree = ast.parse(f.read())
+- else:
+- with open('pefile.py', 'r', encoding='utf-8') as f:
+- tree = ast.parse(f.read())
++ with open('pefile.py', 'r', encoding='utf-8') as f:
++ tree = ast.parse(f.read())
+ return ast.get_docstring(tree)
+
+
+@@ -42,12 +36,8 @@ def _read_attr(attr_name):
+ __version__, __author__, __contact__,
+ """
+ regex = attr_name + r"\s+=\s+['\"](.+)['\"]"
+- if sys.version_info.major == 2:
+- with open('pefile.py', 'r') as f:
+- match = re.search(regex, f.read())
+- else:
+- with open('pefile.py', 'r', encoding='utf-8') as f:
+- match = re.search(regex, f.read())
++ with open('pefile.py', 'r', encoding='utf-8') as f:
++ match = re.search(regex, f.read())
+ # Second item in the group is the value of attribute.
+ return match.group(1)
+
+@@ -89,7 +79,6 @@ def run(self):
+ python_requires=">=3.6.0",
+ packages = ['ordlookup'],
+ install_requires=[
+- 'future',
+ ],
+ license="MIT",
+ )
diff --git a/dev-python/pefile/pefile-9999.ebuild b/dev-python/pefile/pefile-2022.5.30-r1.ebuild
similarity index 92%
copy from dev-python/pefile/pefile-9999.ebuild
copy to dev-python/pefile/pefile-2022.5.30-r1.ebuild
index e80b72dea457..cc72cfce3ddc 100644
--- a/dev-python/pefile/pefile-9999.ebuild
+++ b/dev-python/pefile/pefile-2022.5.30-r1.ebuild
@@ -21,8 +21,9 @@ fi
LICENSE="MIT"
SLOT="0"
-RDEPEND="${PYTHON_DEPS}
- dev-python/future[${PYTHON_USEDEP}]"
+PATCHES=(
+ "${FILESDIR}/${P}-remove-future.patch"
+)
# Unfortunately there is nothing we can test here. Upstream doesn't ship a test
# suite inside the release files. The test fixtures in the source repo is
diff --git a/dev-python/pefile/pefile-9999.ebuild b/dev-python/pefile/pefile-9999.ebuild
index e80b72dea457..9d87a3d62621 100644
--- a/dev-python/pefile/pefile-9999.ebuild
+++ b/dev-python/pefile/pefile-9999.ebuild
@@ -4,7 +4,7 @@
EAPI=8
DISTUTILS_USE_PEP517=setuptools
-PYTHON_COMPAT=( python3_{8..10} )
+PYTHON_COMPAT=( python3_{8..11} )
inherit distutils-r1
DESCRIPTION="Module to read and work with Portable Executable (PE) files"
@@ -21,9 +21,6 @@ fi
LICENSE="MIT"
SLOT="0"
-RDEPEND="${PYTHON_DEPS}
- dev-python/future[${PYTHON_USEDEP}]"
-
# Unfortunately there is nothing we can test here. Upstream doesn't ship a test
# suite inside the release files. The test fixtures in the source repo is
# encrypted so that only their CI pipeline is able to run the tests.
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-python/pefile/, dev-python/pefile/files/
@ 2023-03-11 9:58 Michał Górny
0 siblings, 0 replies; 2+ messages in thread
From: Michał Górny @ 2023-03-11 9:58 UTC (permalink / raw
To: gentoo-commits
commit: 3b27dc18709b0d4e9f00fd23e29fc0ff348ec328
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Sat Mar 11 09:56:02 2023 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Sat Mar 11 09:58:13 2023 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3b27dc18
dev-python/pefile: Remove old
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
dev-python/pefile/Manifest | 1 -
.../files/pefile-2022.5.30-remove-future.patch | 115 ---------------------
dev-python/pefile/pefile-2022.5.30-r1.ebuild | 30 ------
3 files changed, 146 deletions(-)
diff --git a/dev-python/pefile/Manifest b/dev-python/pefile/Manifest
index ee377dabf555..c776143f6b89 100644
--- a/dev-python/pefile/Manifest
+++ b/dev-python/pefile/Manifest
@@ -1,2 +1 @@
-DIST pefile-2022.5.30.tar.gz 72899 BLAKE2B 11752fe849c91749c5272ee9157513db0690fa47a51e274d24093f47c21096e877b364e1dba9cf08d9369abb7e9133743fe98d524079559b9aa9159ece76af74 SHA512 b584472387f7f0161449d2dc0035867da8983eb2c89b488952f38a3e836d23241d46f49a1c9cde13dde4253ef3f212971df48747ea2fec6b91c4db2b7618956d
DIST pefile-2023.2.7.gh.tar.gz 74852 BLAKE2B ddca4b8ef37af829bb1757eb4c4ba9f46c3914e05e6c13e13a8e5a3c88a608aba486deec9338400fddae4591867c0c7dcf7325cee14d42b1bb724751a3a2a7f0 SHA512 241d9846954f094ed39e61d80e7d8c1612829ec909650175e75657f9cf69c9bef9e2a115d4106bb14757125c0ffaa3e93abfb2f078e80326e78ac5818c7c2fd3
diff --git a/dev-python/pefile/files/pefile-2022.5.30-remove-future.patch b/dev-python/pefile/files/pefile-2022.5.30-remove-future.patch
deleted file mode 100644
index 7f7cc5d29d48..000000000000
--- a/dev-python/pefile/files/pefile-2022.5.30-remove-future.patch
+++ /dev/null
@@ -1,115 +0,0 @@
-Bug: https://bugs.gentoo.org/888279
-
-From 36bf63f1185b8407ff9b4ce8c1c8e8620d8ae30f Mon Sep 17 00:00:00 2001
-From: Letu Ren <fantasquex@gmail.com>
-Date: Sun, 26 Jun 2022 22:54:27 +0800
-Subject: [PATCH] Remove future from dependencies
-
-Fix: #348
----
- ordlookup/__init__.py | 15 ++-------------
- peutils.py | 7 -------
- setup.py | 19 ++++---------------
- tests/pefile_test.py | 3 ---
- 4 files changed, 6 insertions(+), 38 deletions(-)
-
-diff --git a/ordlookup/__init__.py b/ordlookup/__init__.py
-index c69aee0..8841d74 100644
---- a/ordlookup/__init__.py
-+++ b/ordlookup/__init__.py
-@@ -1,5 +1,3 @@
--from __future__ import absolute_import
--import sys
- from . import ws2_32
- from . import oleaut32
-
-@@ -15,18 +13,9 @@
- b"oleaut32.dll": oleaut32.ord_names,
- }
-
--PY3 = sys.version_info > (3,)
-
--if PY3:
--
-- def formatOrdString(ord_val):
-- return "ord{}".format(ord_val).encode()
--
--
--else:
--
-- def formatOrdString(ord_val):
-- return b"ord%d" % ord_val
-+def formatOrdString(ord_val):
-+ return "ord{}".format(ord_val).encode()
-
-
- def ordLookup(libname, ord_val, make_name=False):
-diff --git a/peutils.py b/peutils.py
-index 34b98f5..4d4b2bd 100644
---- a/peutils.py
-+++ b/peutils.py
-@@ -6,13 +6,6 @@
-
- All rights reserved.
- """
--from __future__ import division
--from future import standard_library
--
--standard_library.install_aliases()
--from builtins import range
--from builtins import object
--
- import os
- import re
- import string
-diff --git a/setup.py b/setup.py
-index c8ab89f..206db6f 100755
---- a/setup.py
-+++ b/setup.py
-@@ -5,8 +5,6 @@
- import re
- import sys
-
--if sys.version_info.major == 3:
-- from io import open
-
- try:
- from setuptools import setup, Command
-@@ -25,12 +23,8 @@ def _read_doc():
- Parse docstring from file 'pefile.py' and avoid importing
- this module directly.
- """
-- if sys.version_info.major == 2:
-- with open('pefile.py', 'r') as f:
-- tree = ast.parse(f.read())
-- else:
-- with open('pefile.py', 'r', encoding='utf-8') as f:
-- tree = ast.parse(f.read())
-+ with open('pefile.py', 'r', encoding='utf-8') as f:
-+ tree = ast.parse(f.read())
- return ast.get_docstring(tree)
-
-
-@@ -42,12 +36,8 @@ def _read_attr(attr_name):
- __version__, __author__, __contact__,
- """
- regex = attr_name + r"\s+=\s+['\"](.+)['\"]"
-- if sys.version_info.major == 2:
-- with open('pefile.py', 'r') as f:
-- match = re.search(regex, f.read())
-- else:
-- with open('pefile.py', 'r', encoding='utf-8') as f:
-- match = re.search(regex, f.read())
-+ with open('pefile.py', 'r', encoding='utf-8') as f:
-+ match = re.search(regex, f.read())
- # Second item in the group is the value of attribute.
- return match.group(1)
-
-@@ -89,7 +79,6 @@ def run(self):
- python_requires=">=3.6.0",
- packages = ['ordlookup'],
- install_requires=[
-- 'future',
- ],
- license="MIT",
- )
diff --git a/dev-python/pefile/pefile-2022.5.30-r1.ebuild b/dev-python/pefile/pefile-2022.5.30-r1.ebuild
deleted file mode 100644
index f2bd1adb8c03..000000000000
--- a/dev-python/pefile/pefile-2022.5.30-r1.ebuild
+++ /dev/null
@@ -1,30 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-DISTUTILS_USE_PEP517=setuptools
-PYTHON_COMPAT=( python3_{9..11} )
-inherit distutils-r1
-
-DESCRIPTION="Module to read and work with Portable Executable (PE) files"
-HOMEPAGE="https://github.com/erocarrera/pefile"
-
-if [[ ${PV} == 9999 ]] ; then
- EGIT_REPO_URI="https://github.com/erocarrera/pefile.git"
- inherit git-r3
-else
- SRC_URI="https://github.com/erocarrera/pefile/releases/download/v${PV}/${P}.tar.gz"
- KEYWORDS="amd64 ~arm ~arm64 x86"
-fi
-
-LICENSE="MIT"
-SLOT="0"
-
-PATCHES=(
- "${FILESDIR}/${P}-remove-future.patch"
-)
-
-# Unfortunately there is nothing we can test here. Upstream doesn't ship a test
-# suite inside the release files. The test fixtures in the source repo is
-# encrypted so that only their CI pipeline is able to run the tests.
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-03-11 9:58 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-03-11 9:58 [gentoo-commits] repo/gentoo:master commit in: dev-python/pefile/, dev-python/pefile/files/ Michał Górny
-- strict thread matches above, loose matches on Subject: below --
2022-12-27 10:23 Sam James
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox