From ee6bee7261bc2a9271341ea784483d541060704daa6d39bdd9f41865d4c65fc2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Wed, 15 May 2019 16:11:57 +0000 Subject: [PATCH] Accepting request 701953 from home:pgajdos - version update to 1.4.5 * Fix published taglib.cpp * Remove cython dependency from setup.py - added patches fix 'LocalPath'object has no attribute 'endswith' for python2 + python-pytaglib-python2-localpath.patch OBS-URL: https://build.opensuse.org/request/show/701953 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pytaglib?expand=0&rev=8 --- pytaglib-1.4.3.tar.gz | 3 --- python-pytaglib-python2-localpath.patch | 12 ++++++++++++ python-pytaglib.changes | 10 ++++++++++ python-pytaglib.spec | 23 +++++++++++++++-------- v1.4.5.tar.gz | 3 +++ 5 files changed, 40 insertions(+), 11 deletions(-) delete mode 100644 pytaglib-1.4.3.tar.gz create mode 100644 python-pytaglib-python2-localpath.patch create mode 100644 v1.4.5.tar.gz diff --git a/pytaglib-1.4.3.tar.gz b/pytaglib-1.4.3.tar.gz deleted file mode 100644 index 6db68f3..0000000 --- a/pytaglib-1.4.3.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:44ab26dc4b33962b8db0bb8856e7b166539c0c555bc933a6bbbc96f4ec51c7a2 -size 112806 diff --git a/python-pytaglib-python2-localpath.patch b/python-pytaglib-python2-localpath.patch new file mode 100644 index 0000000..0a27796 --- /dev/null +++ b/python-pytaglib-python2-localpath.patch @@ -0,0 +1,12 @@ +Index: pytaglib-1.4.5/tests/__init__.py +=================================================================== +--- pytaglib-1.4.5.orig/tests/__init__.py 2019-03-26 21:48:08.000000000 +0100 ++++ pytaglib-1.4.5/tests/__init__.py 2019-05-09 15:30:36.799060223 +0200 +@@ -12,6 +12,6 @@ import os.path, shutil + def copy_test_file(filename, tmpdir): + """Make a temporary copy of test data file *name* (without dir) and return its full path.""" + source = os.path.join(os.path.dirname(__file__), 'data', filename) +- target = os.path.join(tmpdir, filename) ++ target = os.path.join(tmpdir.strpath, filename) + shutil.copyfile(source, target) + return target diff --git a/python-pytaglib.changes b/python-pytaglib.changes index de3cba7..970909d 100644 --- a/python-pytaglib.changes +++ b/python-pytaglib.changes @@ -1,3 +1,13 @@ +------------------------------------------------------------------- +Thu May 9 15:33:15 UTC 2019 - pgajdos@suse.com + +- version update to 1.4.5 + * Fix published taglib.cpp + * Remove cython dependency from setup.py +- added patches + fix 'LocalPath'object has no attribute 'endswith' for python2 + + python-pytaglib-python2-localpath.patch + ------------------------------------------------------------------- Wed Aug 8 23:17:52 UTC 2018 - jsikes@suse.de diff --git a/python-pytaglib.spec b/python-pytaglib.spec index cdf044e..1bae1ad 100644 --- a/python-pytaglib.spec +++ b/python-pytaglib.spec @@ -1,7 +1,7 @@ # # spec file for package python-pytaglib # -# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -12,21 +12,25 @@ # 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/ # %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-pytaglib -Version: 1.4.3 +Version: 1.4.5 Release: 0 Summary: Metadata "tagging" library based on TagLib -License: GPL-3.0-or-later +License: GPL-3.0-only OR MIT Group: Development/Libraries/Python URL: https://github.com/supermihi/pytaglib -Source: https://files.pythonhosted.org/packages/source/p/pytaglib/pytaglib-%{version}.tar.gz +Source: https://github.com/supermihi/pytaglib/archive/v%{version}.tar.gz +# https://github.com/supermihi/pytaglib/issues/63 +# fix 'LocalPath'object has no attribute 'endswith' for python2 +Patch0: python-pytaglib-python2-localpath.patch BuildRequires: %{python_module Cython} BuildRequires: %{python_module devel} +BuildRequires: %{python_module pytest-runner} BuildRequires: %{python_module setuptools} BuildRequires: fdupes BuildRequires: gcc-c++ @@ -41,6 +45,7 @@ It relies on the TagLib C++ library. %prep %setup -q -n "pytaglib-%{version}" +%patch0 -p1 # Remove pre-generated source rm -vf src/taglib.cpp sed -i -e "1d" src/pyprinttags.py @@ -52,6 +57,9 @@ sed -i -e "1d" src/pyprinttags.py %python_install mv %{buildroot}%{_bindir}/pyprinttags3 %{buildroot}/%{_bindir}/pyprinttags %python_expand %fdupes -s %{buildroot}%{$python_sitearch} +# https://github.com/supermihi/pytaglib/issues/62 +mkdir -p %{buildroot}%{python3_sitelib} +install -m 644 src/pyprinttags.py %{buildroot}%{python3_sitelib} %check export LANG=en_US.UTF-8 @@ -59,10 +67,9 @@ export LANG=en_US.UTF-8 %files %{python_files} %license COPYING -%doc README.txt +%doc README.md %python3_only %{_bindir}/pyprinttags -%pycache_only %{python_sitearch}/__pycache__ -%{python_sitearch}/pyprinttags.py* +%python3_only %{python3_sitelib}/pyprinttags.py %{python_sitearch}/taglib*.so %{python_sitearch}/pytaglib-%{version}-py%{python_version}.egg-info/ diff --git a/v1.4.5.tar.gz b/v1.4.5.tar.gz new file mode 100644 index 0000000..47ea06e --- /dev/null +++ b/v1.4.5.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:78d9da23bd9666fb05729b51674b0f09eae27783c95597e260853f66cf361554 +size 467498