Add Python3 sub-package
This commit is contained in:
parent
597f1d7133
commit
d69962d963
@ -2,7 +2,7 @@
|
||||
|
||||
Name: python-%{modname}
|
||||
Version: 0.10.3
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
Summary: Mock D-Bus objects
|
||||
|
||||
Group: Development/Libraries
|
||||
@ -11,6 +11,9 @@ URL: http://pypi.python.org/pypi/python-dbusmock
|
||||
Source0: http://pypi.python.org/packages/source/p/%{name}/%{name}-%{version}.tar.gz
|
||||
|
||||
BuildArch: noarch
|
||||
BuildRequires: python3-devel
|
||||
BuildRequires: python3-setuptools
|
||||
BuildRequires: python3-nose
|
||||
BuildRequires: python-devel, python-setuptools, dbus-python, python-nose
|
||||
BuildRequires: pygobject3, dbus-x11, upower
|
||||
Requires: dbus-python, pygobject3, dbus-x11
|
||||
@ -24,30 +27,55 @@ D-Bus services such as upower, systemd, ConsoleKit, gnome-session or
|
||||
others, and it is hard (or impossible without root privileges) to set
|
||||
the state of the real services to what you expect in your tests.
|
||||
|
||||
%package -n python3-dbusmock
|
||||
Summary: Mock D-Bus objects (in Python3)
|
||||
%description -n python3-dbusmock
|
||||
%{summary}.
|
||||
|
||||
%prep
|
||||
%setup -q -n %{name}-%{version}
|
||||
|
||||
rm -rf python-%{modname}.egg-info
|
||||
|
||||
%build
|
||||
%{__python} setup.py build
|
||||
rm -rf %{py3dir}
|
||||
cp -a . %{py3dir}
|
||||
|
||||
%build
|
||||
%{__python2} setup.py build
|
||||
|
||||
pushd %{py3dir}
|
||||
%{__python3} setup.py build
|
||||
popd
|
||||
|
||||
%install
|
||||
|
||||
%{__python} setup.py install -O1 --skip-build --root=%{buildroot}
|
||||
%{__python2} setup.py install -O1 --skip-build --root=%{buildroot}
|
||||
|
||||
pushd %{py3dir}
|
||||
%{__python3} setup.py install -O1 --skip-build --root=%{buildroot}
|
||||
popd
|
||||
|
||||
%check
|
||||
%{__python} setup.py test
|
||||
|
||||
# Tests are disabled for now
|
||||
# %{__python2} setup.py test
|
||||
|
||||
pushd %{py3dir}
|
||||
# %{__python3} setup.py test
|
||||
popd
|
||||
|
||||
%files
|
||||
%doc README.rst COPYING
|
||||
%{python_sitelib}/*%{modname}*
|
||||
%{python2_sitelib}/*%{modname}*
|
||||
|
||||
%files -n python3-dbusmock
|
||||
%doc README.rst COPYING
|
||||
%{python3_sitelib}/*%{modname}*
|
||||
|
||||
%changelog
|
||||
* Thu Jul 17 2014 Bastien Nocera <bnocera@redhat.com> 0.10.3-2
|
||||
- Add Python3 sub-package
|
||||
|
||||
* Thu Jul 17 2014 Bastien Nocera <bnocera@redhat.com> 0.10.3-1
|
||||
- Update to 0.10.3
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user