From c9e05b925df89eccd4fb927abc3c48a71d34b6bdca657dec2734d7ec422e5011 Mon Sep 17 00:00:00 2001
From: Denisart Benjamin
Date: Sat, 16 May 2015 13:24:19 +0000
Subject: [PATCH] Accepting request 306587 from
home:benoit_monin:branches:devel:languages:python
- update to version 0.30
- update source URL
- point the source URL to pypi
- add BuildRequires python-setuptools and unzip
- fix end of line encoding of scour.py
- remove unwanted shebang of python sitelib files
- run setup.py build and install instead of copying the files
- remove the documentation files: not provided anymore
- add egg-info to the package
OBS-URL: https://build.opensuse.org/request/show/306587
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-scour?expand=0&rev=4
---
python-scour-0.26.tar.bz2 | 3 ---
python-scour.changes | 14 ++++++++++++++
python-scour.spec | 26 +++++++++++++++-----------
scour-0.30.zip | 3 +++
4 files changed, 32 insertions(+), 14 deletions(-)
delete mode 100644 python-scour-0.26.tar.bz2
create mode 100644 scour-0.30.zip
diff --git a/python-scour-0.26.tar.bz2 b/python-scour-0.26.tar.bz2
deleted file mode 100644
index 4a4acaa..0000000
--- a/python-scour-0.26.tar.bz2
+++ /dev/null
@@ -1,3 +0,0 @@
-version https://git-lfs.github.com/spec/v1
-oid sha256:0699e1a3df21eb52f671cf900d33d8342bb9ab322355f133bdcf09e5fbb06b36
-size 40027
diff --git a/python-scour.changes b/python-scour.changes
index f07971b..3b8b38d 100644
--- a/python-scour.changes
+++ b/python-scour.changes
@@ -1,3 +1,17 @@
+-------------------------------------------------------------------
+Tue May 12 15:16:12 UTC 2015 - benoit.monin@gmx.fr
+
+- update to version 0.30:
+ * no changelog available
+- update source URL
+- point the source URL to pypi
+- add BuildRequires python-setuptools and unzip
+- fix end of line encoding of scour.py
+- remove unwanted shebang of python sitelib files
+- run setup.py build and install instead of copying the files
+- remove the documentation files: not provided anymore
+- add egg-info to the package
+
-------------------------------------------------------------------
Mon Jan 30 10:37:42 UTC 2012 - saschpe@suse.de
diff --git a/python-scour.spec b/python-scour.spec
index aee7d80..b4b20fa 100644
--- a/python-scour.spec
+++ b/python-scour.spec
@@ -1,7 +1,7 @@
#
# spec file for package python-scour
#
-# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2015 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
@@ -17,14 +17,16 @@
Name: python-scour
-Version: 0.26
+Version: 0.30
Release: 0
-License: Apache-2.0
Summary: An SVG scrubber
-Url: http://www.codedread.com/scour
+License: Apache-2.0
Group: System/Libraries
-Source: %{name}-%{version}.tar.bz2
+Url: https://github.com/oberstet/scour
+Source: https://pypi.python.org/packages/source/s/scour/scour-%{version}.zip
BuildRequires: python-devel
+BuildRequires: python-setuptools
+BuildRequires: unzip
Provides: scour = %{version}
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
@@ -37,20 +39,22 @@ BuildArch: noarch
Scour is an open-source Python script that aggressively cleans SVG files, removing a lot of 'cruft' that certain tools or authors embed into their documents. The goal of scour is to provide an identically rendered image.
%prep
-%setup -q
+%setup -q -n scour-%{version}
+# fix end of line encoding
+sed -i 's/\r$//' scour/scour.py
+# remove unwanted shebang
+sed -i '/^#!/ d' scour/{scour.py,yocto_css.py,svg_transform.py}
%build
+python setup.py build
%install
-mkdir -p %{buildroot}%{python_sitelib}/scour
-mkdir -p %{buildroot}%{_bindir}
-mv {scour,svg_regex,svg_transform,yocto_css}.py %{buildroot}%{python_sitelib}/scour/
-ln -sf %{python_sitelib}/scour/scour.py %{buildroot}%{_bindir}/scour
+python setup.py install --prefix=%{_prefix} --root=%{buildroot}
%files
%defattr(-,root,root)
-%doc LICENSE NOTICE README.txt
%{_bindir}/scour
%{python_sitelib}/scour/
+%{python_sitelib}/scour-*.egg-info
%changelog
diff --git a/scour-0.30.zip b/scour-0.30.zip
new file mode 100644
index 0000000..c284d56
--- /dev/null
+++ b/scour-0.30.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4eeadd970fbc6b13eb7c44ea0cc69579818267c639c125db195094a2809bed97
+size 44045