From 67786127871d9975884921bdaab4d9dc8503a1a26415d6d0728588b10ce7a74c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Wed, 15 May 2019 18:35:11 +0000 Subject: [PATCH] Accepting request 703237 from home:gary_smith:branches:devel:languages:python - Update to 0.28.1 * Removed patch pycparser.patch as it is no longer needed * Now works with pycparser 2.18 and above * Now ``Repository.write_archive(..)`` keeps the file mode * New ``Patch.data`` returns the raw contents of the patch as a byte string * New ``Patch.text`` returns the contents of the patch as a text string, OBS-URL: https://build.opensuse.org/request/show/703237 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pygit2?expand=0&rev=50 --- pycparser.patch | 71 ------------------------------------------- pygit2-0.28.0.tar.gz | 3 -- pygit2-0.28.1.tar.gz | 3 ++ python-pygit2.changes | 10 ++++++ python-pygit2.spec | 5 ++- 5 files changed, 15 insertions(+), 77 deletions(-) delete mode 100644 pycparser.patch delete mode 100644 pygit2-0.28.0.tar.gz create mode 100644 pygit2-0.28.1.tar.gz diff --git a/pycparser.patch b/pycparser.patch deleted file mode 100644 index 93ee880..0000000 --- a/pycparser.patch +++ /dev/null @@ -1,71 +0,0 @@ -From 01b69f31b613a99f2a5d47c96fde12b2d0c497d5 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?J=2E=20David=20Ib=C3=A1=C3=B1ez?= -Date: Sat, 6 Apr 2019 13:14:51 +0200 -Subject: [PATCH] Work with pycparser 2.18 and 2.19 - -Fixes #846 ---- - pygit2/__init__.py | 5 ++--- - pygit2/remote.py | 5 ++--- - setup.py | 2 +- - 3 files changed, 5 insertions(+), 7 deletions(-) - -Index: pygit2-0.28.0/pygit2/__init__.py -=================================================================== ---- pygit2-0.28.0.orig/pygit2/__init__.py -+++ pygit2-0.28.0/pygit2/__init__.py -@@ -153,8 +153,7 @@ def init_repository(path, bare=False, - # Ok - return Repository(to_str(path)) - --@ffi.callback('int (*git_repository_create_cb)(git_repository **out,' -- 'const char *path, int bare, void *payload)') -+@ffi.callback('int (*cb)(git_repository **out, const char *path, int bare, void *payload)') - def _repository_create_cb(repo_out, path, bare, data): - d = ffi.from_handle(data) - try: -@@ -168,7 +167,7 @@ def _repository_create_cb(repo_out, path - - return 0 - --@ffi.callback('int (*git_remote_create_cb)(git_remote **out, git_repository *repo,' -+@ffi.callback('int (*cb)(git_remote **out, git_repository *repo,' - 'const char *name, const char *url, void *payload)') - def _remote_create_cb(remote_out, repo, name, url, data): - d = ffi.from_handle(data) -Index: pygit2-0.28.0/pygit2/remote.py -=================================================================== ---- pygit2-0.28.0.orig/pygit2/remote.py -+++ pygit2-0.28.0/pygit2/remote.py -@@ -291,7 +291,7 @@ class RemoteCallbacks(object): - - return 0 - -- @ffi.callback('int (*credentials)(git_cred **cred, const char *url,' -+ @ffi.callback('int (*cb)(git_cred **cred, const char *url,' - 'const char *username_from_url, unsigned int allowed_types,' - 'void *data)') - def _credentials_cb(cred_out, url, username, allowed, data): -@@ -312,8 +312,7 @@ class RemoteCallbacks(object): - - return 0 - -- @ffi.callback('int (*git_transport_certificate_check_cb)' -- '(git_cert *cert, int valid, const char *host, void *payload)') -+ @ffi.callback('int (*cb)(git_cert *cert, int valid, const char *host, void *payload)') - def _certificate_cb(cert_i, valid, host, data): - self = ffi.from_handle(data) - -Index: pygit2-0.28.0/setup.py -=================================================================== ---- pygit2-0.28.0.orig/setup.py -+++ pygit2-0.28.0/setup.py -@@ -154,7 +154,7 @@ setup(name='pygit2', - packages=['pygit2'], - package_data={'pygit2': ['decl.h']}, - setup_requires=['cffi'], -- install_requires=['cffi', 'six', 'pycparser<2.18'], -+ install_requires=['cffi', 'six', 'pycparser'], - zip_safe=False, - cmdclass=cmdclass, - **extra_args) diff --git a/pygit2-0.28.0.tar.gz b/pygit2-0.28.0.tar.gz deleted file mode 100644 index 0b313bb..0000000 --- a/pygit2-0.28.0.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:6dbce6aa7e0e1878ad19363a0e0de52f419b4abe2750c89974a42501bed2cf52 -size 486621 diff --git a/pygit2-0.28.1.tar.gz b/pygit2-0.28.1.tar.gz new file mode 100644 index 0000000..6729d99 --- /dev/null +++ b/pygit2-0.28.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2ccdb865ef530c799a6430d0e52952925ffc0d7c856e7608f4cf42f4b821412b +size 496243 diff --git a/python-pygit2.changes b/python-pygit2.changes index 2434629..7f29730 100644 --- a/python-pygit2.changes +++ b/python-pygit2.changes @@ -1,3 +1,13 @@ +------------------------------------------------------------------- +Wed May 15 18:22:32 UTC 2019 - Gary Smith + +- Update to 0.28.1 + * Removed patch pycparser.patch as it is no longer needed + * Now works with pycparser 2.18 and above + * Now ``Repository.write_archive(..)`` keeps the file mode + * New ``Patch.data`` returns the raw contents of the patch as a byte string + * New ``Patch.text`` returns the contents of the patch as a text string, + ------------------------------------------------------------------- Mon Apr 8 08:15:54 UTC 2019 - Tomáš Chvátal diff --git a/python-pygit2.spec b/python-pygit2.spec index e21826e..480b9dd 100644 --- a/python-pygit2.spec +++ b/python-pygit2.spec @@ -19,14 +19,13 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-pygit2 -Version: 0.28.0 +Version: 0.28.1 Release: 0 Summary: Python bindings for libgit2 License: GPL-2.0-only Group: Development/Languages/Python URL: https://github.com/libgit2/pygit2 Source: https://files.pythonhosted.org/packages/source/p/pygit2/pygit2-%{version}.tar.gz -Patch0: pycparser.patch BuildRequires: %{python_module cffi} BuildRequires: %{python_module devel} BuildRequires: %{python_module pycparser} @@ -49,7 +48,6 @@ Bindings for libgit2, a linkable C library for the Git version-control system. %prep %setup -q -n pygit2-%{version} -%patch0 -p1 # do not add options to pytest rm pytest.ini @@ -59,6 +57,7 @@ export CFLAGS="%{optflags} -fno-strict-aliasing" %install %python_install +%python_expand rm -rf %{buildroot}%{$python_sitearch}/pygit2/decl/ %python_expand %fdupes %{buildroot}%{$python_sitearch} %check