New subpackage for python3 build

epel9
Seth Jennings 9 years ago
parent edbc91d921
commit 38f79ca2fe

@ -1,6 +1,6 @@
Name: pyscard Name: pyscard
Version: 1.9.0 Version: 1.9.0
Release: 1%{?dist} Release: 2%{?dist}
Summary: A framework for building smart card aware applications in Python Summary: A framework for building smart card aware applications in Python
Group: Development/Libraries Group: Development/Libraries
@ -13,6 +13,7 @@ License: LGPLv2+ and Python and CC-BY-SA
URL: https://sourceforge.net/projects/pyscard/ URL: https://sourceforge.net/projects/pyscard/
Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
BuildRequires: python2-devel
BuildRequires: python3-devel BuildRequires: python3-devel
BuildRequires: pcsc-lite-devel BuildRequires: pcsc-lite-devel
BuildRequires: swig >= 1.3.31 BuildRequires: swig >= 1.3.31
@ -23,26 +24,52 @@ The pyscard smartcard library is a framework for building smart card aware
applications in Python. The smartcard module is built on top of the PCSC API applications in Python. The smartcard module is built on top of the PCSC API
Python wrapper module. Python wrapper module.
This is the python2 package.
%package -n python3-%{name}
Summary: A framework for building smart card aware applications in Python
Requires: pcsc-lite
%description -n python3-%{name}
The pyscard smartcard library is a framework for building smart card aware
applications in Python. The smartcard module is built on top of the PCSC API
Python wrapper module.
This is the python3 package.
%prep %prep
%setup -q %setup -q
# license file is CRLF terminated -- prevent a rpmlint warning # license file is CRLF terminated -- prevent a rpmlint warning
sed -i 's/\r//' LICENSE sed -i 's/\r//' LICENSE
%build %build
CFLAGS="$RPM_OPT_FLAGS" %{__python3} setup.py build %{__python2} setup.py build
%{__python3} setup.py build
%install %install
%{__python3} setup.py install -O1 --skip-build --root %{buildroot} %{__python2} setup.py install --root %{buildroot}
chmod 755 %{buildroot}%{python3_sitearch}/smartcard/scard/_scard.*.so chmod 755 %{buildroot}%{python2_sitearch}/smartcard/scard/*.so
%{__python3} setup.py install --root %{buildroot}
chmod 755 %{buildroot}%{python3_sitearch}/smartcard/scard/*.so
%files %files
%license LICENSE %license LICENSE
%doc README %doc README
%doc smartcard/doc/* %doc smartcard/doc/*
%{python2_sitearch}/smartcard/
%{python2_sitearch}/%{name}-%{version}-py*.egg-info
%files -n python3-%{name}
%license LICENSE
%doc README
%doc smartcard/doc/*
%{python3_sitearch}/smartcard/ %{python3_sitearch}/smartcard/
%{python3_sitearch}/%{name}-%{version}-py*.egg-info %{python3_sitearch}/%{name}-%{version}-py*.egg-info
%changelog %changelog
* Mon Aug 31 2015 Seth Jennings <spartacus06@gmail.com> 1.9.0-2
- New subpackage for python3 build
* Fri Aug 14 2015 Nikos Mavrogiannopoulos <nmav@redhat.com> 1.9.0-1 * Fri Aug 14 2015 Nikos Mavrogiannopoulos <nmav@redhat.com> 1.9.0-1
- New upstream release - New upstream release
- Built with python3 - Built with python3

Loading…
Cancel
Save