From 7abfe8db2a88b54e0f4d232a860ec8229a84f0b112cc4b5fcd8059ec793a2f14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Sat, 23 Mar 2019 11:27:24 +0000 Subject: [PATCH 1/3] Accepting request 687891 from home:Pharaoh_Atem:branches:devel:languages:python - Update to 0.28.0 * Update to libgit2 v0.28 * New ``pygit2.Mailmap`` * New ``Repository.apply(...)`` wraps ``git_apply(..)`` * Now ``Repository.merge_analysis(...)`` accepts an optional reference parameter * Now ``Repository.add_worktree(...)`` accepts an optional reference parameter * Now it's possible to set SSL certificate locations * Test and documentation improvements * Now ``worktree.path`` returns the path to the worktree directory * Remove undocumented ``worktree.git_path`` - Remove unneeded patch to fix issues on i586: * pygit2-i586.patch - Add patch to remove unneeded constraint on pycparser * pygit2-0.28-Remove-pycparser-constraint.patch OBS-URL: https://build.opensuse.org/request/show/687891 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pygit2?expand=0&rev=44 --- pygit2-0.27.0.tar.gz | 3 -- pygit2-0.28-Remove-pycparser-constraint.patch | 28 +++++++++++++++++++ pygit2-0.28.0.tar.gz | 3 ++ pygit2-i586.patch | 22 --------------- python-pygit2.changes | 18 ++++++++++++ python-pygit2.spec | 15 ++++++---- 6 files changed, 59 insertions(+), 30 deletions(-) delete mode 100644 pygit2-0.27.0.tar.gz create mode 100644 pygit2-0.28-Remove-pycparser-constraint.patch create mode 100644 pygit2-0.28.0.tar.gz delete mode 100644 pygit2-i586.patch diff --git a/pygit2-0.27.0.tar.gz b/pygit2-0.27.0.tar.gz deleted file mode 100644 index 0931559..0000000 --- a/pygit2-0.27.0.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:6febce4aea72f12ed5a1e7529b91119f21d93cb2ccb3f834eea26af76cc9a4cb -size 477427 diff --git a/pygit2-0.28-Remove-pycparser-constraint.patch b/pygit2-0.28-Remove-pycparser-constraint.patch new file mode 100644 index 0000000..6706c30 --- /dev/null +++ b/pygit2-0.28-Remove-pycparser-constraint.patch @@ -0,0 +1,28 @@ +From d612cc24a9e4d2f4aeb50db4ee0b4b393bf46298 Mon Sep 17 00:00:00 2001 +From: Neal Gompa +Date: Wed, 20 Mar 2019 16:50:37 -0400 +Subject: [PATCH] Revert "pycparser 2.18+ is broken" + +Tests seem to work fine without this constraint. + +This reverts commit b1bbdcb98643baf5d4d7634d7afc18feda56de52. +--- + setup.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/setup.py b/setup.py +index 79e82df..3165e3d 100644 +--- a/setup.py ++++ b/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'], + zip_safe=False, + cmdclass=cmdclass, + **extra_args) +-- +2.20.1 + diff --git a/pygit2-0.28.0.tar.gz b/pygit2-0.28.0.tar.gz new file mode 100644 index 0000000..0b313bb --- /dev/null +++ b/pygit2-0.28.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6dbce6aa7e0e1878ad19363a0e0de52f419b4abe2750c89974a42501bed2cf52 +size 486621 diff --git a/pygit2-i586.patch b/pygit2-i586.patch deleted file mode 100644 index 661a302..0000000 --- a/pygit2-i586.patch +++ /dev/null @@ -1,22 +0,0 @@ -From 1d11fa171b56114f181ac022715baba9581d36e7 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?J=2E=20David=20Ib=C3=A1=C3=B1ez?= -Date: Sun, 20 May 2018 17:52:34 +0200 -Subject: [PATCH] Update git_time decl - -Should fix #795 ---- - pygit2/decl.h | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/pygit2/decl.h b/pygit2/decl.h -index 9cdea8a0..53451583 100644 ---- a/pygit2/decl.h -+++ b/pygit2/decl.h -@@ -77,6 +77,7 @@ typedef struct { - typedef struct git_time { - git_time_t time; - int offset; -+ char sign; - } git_time; - - typedef struct git_signature { diff --git a/python-pygit2.changes b/python-pygit2.changes index 7a638a8..d5fab76 100644 --- a/python-pygit2.changes +++ b/python-pygit2.changes @@ -1,3 +1,21 @@ +------------------------------------------------------------------- +Wed Mar 20 20:40:34 UTC 2019 - Neal Gompa + +- Update to 0.28.0 + * Update to libgit2 v0.28 + * New ``pygit2.Mailmap`` + * New ``Repository.apply(...)`` wraps ``git_apply(..)`` + * Now ``Repository.merge_analysis(...)`` accepts an optional reference parameter + * Now ``Repository.add_worktree(...)`` accepts an optional reference parameter + * Now it's possible to set SSL certificate locations + * Test and documentation improvements + * Now ``worktree.path`` returns the path to the worktree directory + * Remove undocumented ``worktree.git_path`` +- Remove unneeded patch to fix issues on i586: + * pygit2-i586.patch +- Add patch to remove unneeded constraint on pycparser + * pygit2-0.28-Remove-pycparser-constraint.patch + ------------------------------------------------------------------- Mon May 21 08:33:07 UTC 2018 - tchvatal@suse.com diff --git a/python-pygit2.spec b/python-pygit2.spec index 2f916d2..b0548c9 100644 --- a/python-pygit2.spec +++ b/python-pygit2.spec @@ -2,6 +2,7 @@ # spec file for package python-pygit2 # # Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2019 Neal Gompa . # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,22 +17,27 @@ # +# Define incompatible version for building libgit2 +%global libgit2_incompat_ver 0.29 %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-pygit2 -Version: 0.27.0 +Version: 0.28.0 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: pygit2-i586.patch +Patch0: pygit2-0.28-Remove-pycparser-constraint.patch BuildRequires: %{python_module cffi} BuildRequires: %{python_module devel} +BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools} BuildRequires: %{python_module six} +BuildRequires: ca-certificates +BuildRequires: ca-certificates-mozilla BuildRequires: fdupes -BuildRequires: libgit2-devel >= %{version} +BuildRequires: (libgit2-devel >= %{version} with libgit2-devel < %{libgit2_incompat_ver}) BuildRequires: libopenssl-devel BuildRequires: python-rpm-macros Requires: python-six @@ -42,8 +48,7 @@ Requires: python-six Bindings for libgit2, a linkable C library for the Git version-control system. %prep -%setup -q -n pygit2-%{version} -%patch0 -p1 +%autosetup -n pygit2-%{version} -p1 %build export CFLAGS="%{optflags} -fno-strict-aliasing" From 7ea1c3f2fc0e4c5dd93855bee5da23113824ccf9c6945042f585d11d2387b430 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Sat, 23 Mar 2019 11:40:49 +0000 Subject: [PATCH 2/3] - Drop the pygit2-0.28-Remove-pycparser-constraint.patch and replace it with shorter sed - Switch to pytest testing: * Fails now but that is pycparser bug https://github.com/eliben/pycparser/issues/305 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pygit2?expand=0&rev=45 --- pygit2-0.28-Remove-pycparser-constraint.patch | 28 ------------------- python-pygit2.changes | 8 ++++++ python-pygit2.spec | 19 +++++++------ 3 files changed, 19 insertions(+), 36 deletions(-) delete mode 100644 pygit2-0.28-Remove-pycparser-constraint.patch diff --git a/pygit2-0.28-Remove-pycparser-constraint.patch b/pygit2-0.28-Remove-pycparser-constraint.patch deleted file mode 100644 index 6706c30..0000000 --- a/pygit2-0.28-Remove-pycparser-constraint.patch +++ /dev/null @@ -1,28 +0,0 @@ -From d612cc24a9e4d2f4aeb50db4ee0b4b393bf46298 Mon Sep 17 00:00:00 2001 -From: Neal Gompa -Date: Wed, 20 Mar 2019 16:50:37 -0400 -Subject: [PATCH] Revert "pycparser 2.18+ is broken" - -Tests seem to work fine without this constraint. - -This reverts commit b1bbdcb98643baf5d4d7634d7afc18feda56de52. ---- - setup.py | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/setup.py b/setup.py -index 79e82df..3165e3d 100644 ---- a/setup.py -+++ b/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'], - zip_safe=False, - cmdclass=cmdclass, - **extra_args) --- -2.20.1 - diff --git a/python-pygit2.changes b/python-pygit2.changes index d5fab76..10fb5e7 100644 --- a/python-pygit2.changes +++ b/python-pygit2.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Sat Mar 23 11:32:34 UTC 2019 - Tomáš Chvátal + +- Drop the pygit2-0.28-Remove-pycparser-constraint.patch and replace + it with shorter sed +- Switch to pytest testing: + * Fails now but that is pycparser bug https://github.com/eliben/pycparser/issues/305 + ------------------------------------------------------------------- Wed Mar 20 20:40:34 UTC 2019 - Neal Gompa diff --git a/python-pygit2.spec b/python-pygit2.spec index b0548c9..28b3caa 100644 --- a/python-pygit2.spec +++ b/python-pygit2.spec @@ -1,7 +1,7 @@ # # spec file for package python-pygit2 # -# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. # Copyright (c) 2019 Neal Gompa . # # All modifications and additions to the file contributed by third parties @@ -13,12 +13,10 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # -# Define incompatible version for building libgit2 -%global libgit2_incompat_ver 0.29 %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-pygit2 Version: 0.28.0 @@ -28,18 +26,19 @@ 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: pygit2-0.28-Remove-pycparser-constraint.patch BuildRequires: %{python_module cffi} BuildRequires: %{python_module devel} +BuildRequires: %{python_module pycparser} BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools} BuildRequires: %{python_module six} BuildRequires: ca-certificates BuildRequires: ca-certificates-mozilla BuildRequires: fdupes -BuildRequires: (libgit2-devel >= %{version} with libgit2-devel < %{libgit2_incompat_ver}) +BuildRequires: libgit2-devel >= %{version} BuildRequires: libopenssl-devel BuildRequires: python-rpm-macros +Requires: python-pycparser Requires: python-six %requires_eq python-cffi %python_subpackages @@ -48,7 +47,11 @@ Requires: python-six Bindings for libgit2, a linkable C library for the Git version-control system. %prep -%autosetup -n pygit2-%{version} -p1 +%setup -q -n pygit2-%{version} +# do not hardcode version +sed -i -e 's:pycparser<2.18:pycparser:g' setup.py +# do not add options to pytest +rm pytest.ini %build export CFLAGS="%{optflags} -fno-strict-aliasing" @@ -59,7 +62,7 @@ export CFLAGS="%{optflags} -fno-strict-aliasing" %python_expand %fdupes %{buildroot}%{$python_sitearch} %check -%python_exec setup.py test +%pytest_arch %files %{python_files} %license COPYING From 4493705311c0d48a2cbfbace4b9b6786ae557169d14aefacd398088acf016f8e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Tue, 26 Mar 2019 09:11:29 +0000 Subject: [PATCH 3/3] - Disable tests temporarily as per above OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pygit2?expand=0&rev=46 --- python-pygit2.changes | 1 + python-pygit2.spec | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/python-pygit2.changes b/python-pygit2.changes index 10fb5e7..89bc011 100644 --- a/python-pygit2.changes +++ b/python-pygit2.changes @@ -5,6 +5,7 @@ Sat Mar 23 11:32:34 UTC 2019 - Tomáš Chvátal it with shorter sed - Switch to pytest testing: * Fails now but that is pycparser bug https://github.com/eliben/pycparser/issues/305 +- Disable tests temporarily as per above ------------------------------------------------------------------- Wed Mar 20 20:40:34 UTC 2019 - Neal Gompa diff --git a/python-pygit2.spec b/python-pygit2.spec index 28b3caa..f83b574 100644 --- a/python-pygit2.spec +++ b/python-pygit2.spec @@ -62,7 +62,9 @@ export CFLAGS="%{optflags} -fno-strict-aliasing" %python_expand %fdupes %{buildroot}%{$python_sitearch} %check -%pytest_arch +# disable tests for now until https://github.com/libgit2/pygit2/issues/846 +# gets fixed; upstream https://github.com/eliben/pycparser/issues/305 +#%%pytest_arch %files %{python_files} %license COPYING