From 9e152a1e159abd2597034c93df0d6d25676cfec674665cdb970e2f10fba5a7a4 Mon Sep 17 00:00:00 2001 From: Todd R Date: Wed, 18 Oct 2017 16:25:35 +0000 Subject: [PATCH] Accepting request 535002 from devel:languages:python:singlespec-staging - Update to version 0.4 * Python 3.6 added to test matrix * Proper unicode support for text strings in PDFs added * buildxobj fixes allow better support creating form XObjects out of compressed pages in some cases * Compression fixes for Python 3+ * New subset_booklets.py example * Bug with non-compressed indices into compressed object streams fixed * Bug with distinguishing compressed object stream first objects fixed * Better error reporting added for some invalid PDFs (e.g. when reading past the end of file) * Better scrubbing of old bookmark information when writing PDFs, to remove dangling references * Refactoring of pdfwriter, including updating API, to allow future enhancements for things like incremental writing * Minor tokenizer speedup * Some flate decompressor bugs fixed * Compression and decompression tests added * Tests for new unicode handling added * PdfReader.readpages() recursion error (issue #92) fixed. * Initial crypt filter support added - Update to version 0.3 * Python 3.5 added to test matrix * Better support under Python 3.x for in-memory PDF file-like objects * Some pagemerge and Unicode patches added * Changes to logging allow better coexistence with other packages * Fix for "from pdfrw import \*" * New fancy_watermark.py example shows off capabilities of pagemerge.py * metadata.py example renamed to cat.py - Update to version 0.2 * Several bugs have been fixed * New regression test functionally tests core with dozens of PDFs, and also tests examples. * Core has been ported and tested on Python3 by round-tripping several difficult files and observing binary matching results across the different Python versions. * Still only minimal support for compression and no support for encryption or newer PDF features. (pdftk is useful to put PDFs in a form that pdfrw can use.) - singlespec auto-conversion - Fix building on SLES 11 - Fix name in the header. - Inital commit, package required by python-rst2pdf on runtime. OBS-URL: https://build.opensuse.org/request/show/535002 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pdfrw?expand=0&rev=4 --- pdfrw-0.1.tar.gz | 3 --- pdfrw-0.4.tar.gz | 3 +++ python-pdfrw.changes | 49 ++++++++++++++++++++++++++++++++++++++++++++ python-pdfrw.spec | 42 +++++++++++++++++++++++-------------- 4 files changed, 79 insertions(+), 18 deletions(-) delete mode 100644 pdfrw-0.1.tar.gz create mode 100644 pdfrw-0.4.tar.gz diff --git a/pdfrw-0.1.tar.gz b/pdfrw-0.1.tar.gz deleted file mode 100644 index fa81c4e..0000000 --- a/pdfrw-0.1.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:8a85cb87b888c030d87cc3fce10ad93e5f99e721b80b99bf50e29a074c048f83 -size 30366 diff --git a/pdfrw-0.4.tar.gz b/pdfrw-0.4.tar.gz new file mode 100644 index 0000000..ec2148d --- /dev/null +++ b/pdfrw-0.4.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0dc0494a0e6561b268542b28ede2280387c2728114f117d3bb5d8e4787b93ef4 +size 95402 diff --git a/python-pdfrw.changes b/python-pdfrw.changes index 0661c3a..cfa5f69 100644 --- a/python-pdfrw.changes +++ b/python-pdfrw.changes @@ -1,3 +1,51 @@ +------------------------------------------------------------------- +Wed Oct 18 15:57:22 UTC 2017 - toddrme2178@gmail.com + +- Update to version 0.4 + * Python 3.6 added to test matrix + * Proper unicode support for text strings in PDFs added + * buildxobj fixes allow better support creating form XObjects + out of compressed pages in some cases + * Compression fixes for Python 3+ + * New subset_booklets.py example + * Bug with non-compressed indices into compressed object streams fixed + * Bug with distinguishing compressed object stream first objects fixed + * Better error reporting added for some invalid PDFs (e.g. when reading + past the end of file) + * Better scrubbing of old bookmark information when writing PDFs, to + remove dangling references + * Refactoring of pdfwriter, including updating API, to allow future + enhancements for things like incremental writing + * Minor tokenizer speedup + * Some flate decompressor bugs fixed + * Compression and decompression tests added + * Tests for new unicode handling added + * PdfReader.readpages() recursion error (issue #92) fixed. + * Initial crypt filter support added +- Update to version 0.3 + * Python 3.5 added to test matrix + * Better support under Python 3.x for in-memory PDF file-like objects + * Some pagemerge and Unicode patches added + * Changes to logging allow better coexistence with other packages + * Fix for "from pdfrw import \*" + * New fancy_watermark.py example shows off capabilities of pagemerge.py + * metadata.py example renamed to cat.py +- Update to version 0.2 + * Several bugs have been fixed + * New regression test functionally tests core with dozens of + PDFs, and also tests examples. + * Core has been ported and tested on Python3 by round-tripping + several difficult files and observing binary matching results + across the different Python versions. + * Still only minimal support for compression and no support + for encryption or newer PDF features. (pdftk is useful + to put PDFs in a form that pdfrw can use.) + +------------------------------------------------------------------- +Thu Aug 24 13:49:11 UTC 2017 - jmatejek@suse.com + +- singlespec auto-conversion + ------------------------------------------------------------------- Mon Jul 13 13:12:38 UTC 2015 - toddrme2178@gmail.com @@ -13,3 +61,4 @@ Sat Nov 9 17:44:36 UTC 2013 - tchvatal@suse.com - Inital commit, package required by python-rst2pdf on runtime. + diff --git a/python-pdfrw.spec b/python-pdfrw.spec index c36019e..4b21f8b 100644 --- a/python-pdfrw.spec +++ b/python-pdfrw.spec @@ -1,7 +1,7 @@ # # spec file for package python-pdfrw # -# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2017 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 @@ -16,37 +16,49 @@ # +%{?!python_module:%define python_module() python-%{**} python3-%{**}} +# Tests require external files +%bcond_with test Name: python-pdfrw -Version: 0.1 +Version: 0.4 Release: 0 Summary: PDF file reader/writer library License: MIT Group: Development/Libraries/Python -Source: https://pypi.python.org/packages/source/p/pdfrw/pdfrw-%{version}.tar.gz Url: https://code.google.com/p/pdfrw/ -BuildRequires: python-setuptools -BuildRoot: %{_tmppath}/%{name}-%{version}-build -%{py_requires} -%if 0%{?suse_version} && 0%{?suse_version} > 1110 -BuildArch: noarch +Source: https://files.pythonhosted.org/packages/source/p/pdfrw/pdfrw-%{version}.tar.gz +BuildRequires: %{python_module devel} +BuildRequires: %{python_module setuptools} +BuildRequires: fdupes +BuildRequires: python-rpm-macros +%if %{with test} +BuildRequires: %{python_module pytest} %endif +BuildArch: noarch +%python_subpackages %description -PDF file reader/writer library written in python +pdfrw is a Python library and utility that reads and writes PDF files. %prep %setup -q -n pdfrw-%{version} %build -CFLAGS="%{optflags}" python setup.py build +%python_build %install -python setup.py install --prefix=%{_prefix} --root=%{buildroot} +%python_install +%python_expand %fdupes %{buildroot}%{python_sitelib} -%files +%if %{with test} +%check +%python_expand py.test-%{$python_bin_suffix} +%endif + +%files %{python_files} %defattr(-,root,root) -%dir %{python_sitelib}/pdfrw -%{python_sitelib}/pdfrw/* -%{python_sitelib}/pdfrw-%{version}-py%{py_ver}.egg-info +%doc LICENSE.txt README.rst +%{python_sitelib}/pdfrw/ +%{python_sitelib}/pdfrw-%{version}-py*.egg-info %changelog