From e6381ec0dc0e48441acf4431a0485ac5cceba11a Mon Sep 17 00:00:00 2001 From: rpmbuild Date: Tue, 24 Sep 2019 09:06:27 +0000 Subject: [PATCH] bump to version 2019.4.18 --- .gitignore | 3 +- pefile-fix-build-43c1cc79a71.patch | 53 ------------------------------ python-pefile.spec | 30 +++++++++++------ sources | 2 +- 4 files changed, 23 insertions(+), 65 deletions(-) delete mode 100644 pefile-fix-build-43c1cc79a71.patch diff --git a/.gitignore b/.gitignore index 717602d..613548d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,8 @@ -pefile-1.2.10-63.tar.gz +/pefile-1.2.10-63.tar.gz /pefile-1.2.10-123.tar.gz /pefile-1.2.10-139.tar.gz /pefile-2016.3.28.tar.gz /pefile-2017.5.26.tar.gz /pefile-2017.8.1.tar.gz /pefile-2017.11.5.tar.gz +/pefile-2019.4.18.tar.gz diff --git a/pefile-fix-build-43c1cc79a71.patch b/pefile-fix-build-43c1cc79a71.patch deleted file mode 100644 index 45b83b2..0000000 --- a/pefile-fix-build-43c1cc79a71.patch +++ /dev/null @@ -1,53 +0,0 @@ -diff --git a/setup.py b/setup.py -index f5345bb..b932eb7 100755 ---- a/setup.py -+++ b/setup.py -@@ -5,6 +5,9 @@ import os - import re - import sys - -+if sys.version_info.major == 3: -+ from io import open -+ - try: - from setuptools import setup, Command - except ImportError as excp: -@@ -22,8 +25,12 @@ def _read_doc(): - Parse docstring from file 'pefile.py' and avoid importing - this module directly. - """ -- with open('pefile.py', 'r') as f: -- tree = ast.parse(f.read()) -+ 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()) - return ast.get_docstring(tree) - - -@@ -35,8 +42,12 @@ def _read_attr(attr_name): - __version__, __author__, __contact__, - """ - regex = attr_name + r"\s+=\s+'(.+)'" -- with open('pefile.py', 'r') as f: -- match = re.search(regex, f.read()) -+ 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()) - # Second item in the group is the value of attribute. - return match.group(1) - -@@ -80,7 +91,7 @@ setup(name = 'pefile', - author = _read_attr('__author__'), - author_email = _read_attr('__contact__'), - url = 'https://github.com/erocarrera/pefile', -- download_url='https://github.com/erocarrera/pefile/releases/download/v2016.3.28/pefile-2016.3.28.tar.gz', -+ download_url='https://github.com/erocarrera/pefile/files/192316/pefile-2016.3.28.tar.gz', - keywords = ['pe', 'exe', 'dll', 'pefile', 'pecoff'], - classifiers = [ - 'Development Status :: 5 - Production/Stable', diff --git a/python-pefile.spec b/python-pefile.spec index 1fa1b11..38a5afa 100644 --- a/python-pefile.spec +++ b/python-pefile.spec @@ -1,3 +1,11 @@ +Name: python-pefile +Version: 2019.4.18 +Release: 1%{?dist} +Summary: Python module for working with Portable Executable files +License: MIT +URL: https://github.com/erocarrera/pefile + + %global srcname pefile %global common_desc pefile is a multi-platform Python module to read and work with Portable\ @@ -15,14 +23,8 @@ Some of the tasks that pefile makes possible are:\ * PEiD signature generation\ -Name: python-%{srcname} -Version: 2017.11.5 -Release: 8%{?dist} -Summary: Python module for working with Portable Executable files -License: MIT -URL: https://github.com/erocarrera/pefile - -Source0: https://github.com/erocarrera/pefile/archive/v%{version}/pefile-%{version}.tar.gz +#Source0: https://github.com/erocarrera/%{srcname}/archive/v%{version}/%{srcname}-%{version}.tar.gz +Source0: https://github.com/erocarrera/%{srcname}/releases/download/v%{version}/%{srcname}-%{version}.tar.gz BuildArch: noarch BuildRequires: python3-devel @@ -53,8 +55,13 @@ sed -i -e '/^#!\//, 1d' pefile.py %install %py3_install -%check -%{__python3} setup.py test +# check +# regression tests in this package are based on binary blob of exe files - commercial and malware +# at this point (2019-09-20) not suitable to be in Fedora. +# More info on: +# https://github.com/erocarrera/pefile/issues/171 +# https://github.com/erocarrera/pefile/issues/82#issuecomment-192018385 +# %{__python3} setup.py test %files -n python3-%{srcname} %license LICENSE @@ -62,6 +69,9 @@ sed -i -e '/^#!\//, 1d' pefile.py %{python3_sitelib}/* %changelog +* Fri Sep 20 2019 Michal Ambroz - 2019.4.18-1 +- bump to version 2019.4.18 + * Mon Aug 19 2019 Miro HronĨok - 2017.11.5-8 - Rebuilt for Python 3.8 diff --git a/sources b/sources index 7403c69..9a3c4a9 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (pefile-2017.11.5.tar.gz) = 820f7770d18256857436698a9d72276dc8089a2a85c20f1c2e284c541680879016f7acf7b3029e7dd1f32ef093b52fe1c8e8f7962e5b9a7dbbc0f94caf6d0d66 +SHA512 (pefile-2019.4.18.tar.gz) = 33c53120fd6a0fde22f4076c19ed8f69fc2b53b16d0c581133446d0d770e290dcb2ddd1e9941e8d8debc28c1cb4ff64ff055c2b8c0958015d9121de72ae20c76