1.9.66 - Python 3 support.

This commit is contained in:
Jiri Popelka 2013-11-27 15:12:49 +01:00
parent e51d2a3302
commit 0c0fe63243
3 changed files with 41 additions and 4 deletions

1
.gitignore vendored
View File

@ -9,3 +9,4 @@
/pycups-1.9.62.tar.bz2 /pycups-1.9.62.tar.bz2
/pycups-1.9.63.tar.bz2 /pycups-1.9.63.tar.bz2
/pycups-1.9.65.tar.bz2 /pycups-1.9.65.tar.bz2
/pycups-1.9.66.tar.bz2

View File

@ -5,21 +5,32 @@
Summary: Python bindings for CUPS Summary: Python bindings for CUPS
Name: python-cups Name: python-cups
Version: 1.9.65 Version: 1.9.66
Release: 1%{?dist} Release: 1%{?dist}
URL: http://cyberelk.net/tim/software/pycups/ URL: http://cyberelk.net/tim/software/pycups/
Source: http://cyberelk.net/tim/data/pycups/pycups-%{version}.tar.bz2 Source: http://cyberelk.net/tim/data/pycups/pycups-%{version}.tar.bz2
License: GPLv2+ License: GPLv2+
Group: Development/Languages Group: Development/Languages
BuildRequires: cups-devel BuildRequires: cups-devel
BuildRequires: python2-devel BuildRequires: python2-devel python3-devel
BuildRequires: epydoc BuildRequires: epydoc
%description %description
This package provides Python bindings for the CUPS API, This package provides Python bindings for CUPS API,
known as pycups. It was written for use with known as pycups. It was written for use with
system-config-printer, but can be put to other uses as well. system-config-printer, but can be put to other uses as well.
%package -n python3-cups
Summary: Python3 bindings for CUPS API, known as pycups.
Group: Development/Languages
%description -n python3-cups
This package provides Python bindings for CUPS API,
known as pycups. It was written for use with
system-config-printer, but can be put to other uses as well.
This is a ported release for python 3
%package doc %package doc
Summary: Documentation for python-cups Summary: Documentation for python-cups
Group: Documentation Group: Documentation
@ -30,13 +41,28 @@ Documentation for python-cups.
%prep %prep
%setup -q -n pycups-%{version} %setup -q -n pycups-%{version}
rm -rf %{py3dir}
cp -a . %{py3dir}
%build %build
make CFLAGS="%{optflags} -fno-strict-aliasing" make CFLAGS="%{optflags} -fno-strict-aliasing"
make doc make doc
pushd %{py3dir}
CFLAGS="%{optflags}" %{__python3} setup.py build
popd
%install %install
make install DESTDIR="%{buildroot}" make install DESTDIR="%{buildroot}"
pushd %{py3dir}
%{__python3} setup.py install -O1 --skip-build --root %{buildroot}
chmod 755 %{buildroot}%{python3_sitearch}/cups*.so
popd
%files %files
%doc COPYING ChangeLog README NEWS TODO %doc COPYING ChangeLog README NEWS TODO
%{python_sitearch}/cups.so %{python_sitearch}/cups.so
@ -44,10 +70,20 @@ make install DESTDIR="%{buildroot}"
%{_rpmconfigdir}/fileattrs/psdriver.attr %{_rpmconfigdir}/fileattrs/psdriver.attr
%{_rpmconfigdir}/postscriptdriver.prov %{_rpmconfigdir}/postscriptdriver.prov
%files -n python3-cups
%doc COPYING README NEWS
%{python3_sitearch}/cups.cpython-3*.so
%{python3_sitearch}/pycups*.egg-info
%{_rpmconfigdir}/fileattrs/psdriver.attr
%{_rpmconfigdir}/postscriptdriver.prov
%files doc %files doc
%doc examples html %doc examples html
%changelog %changelog
* Wed Nov 27 2013 Jiri Popelka <jpopelka@redhat.com> - 1.9.66-1
- 1.9.66 - Python 3 support.
* Wed Nov 27 2013 Tim Waugh <twaugh@redhat.com> - 1.9.65-1 * Wed Nov 27 2013 Tim Waugh <twaugh@redhat.com> - 1.9.65-1
- 1.9.65. - 1.9.65.

View File

@ -1 +1 @@
aa6a181c5b60801ad2434adda6441ea3 pycups-1.9.65.tar.bz2 a6cc4d40ac908dd9182ed93739b4bb79 pycups-1.9.66.tar.bz2