dbus-python/dbus-python.spec

170 lines
3.9 KiB
RPMSpec
Raw Normal View History

2019-09-30 10:36:37 -04:00
%global _configure ../configure
%global python2dir %{_builddir}/python2-%{name}-%{version}-%{release}
%global python3dir %{_builddir}/python3-%{name}-%{version}-%{release}
2019-09-30 10:36:37 -04:00
Name: dbus-python
2020-08-07 11:03:12 +08:00
Version: 1.2.16
Release: 3
2019-09-30 10:36:37 -04:00
Summary: original Python binding for dbus
License: MIT and (AFL-2.1 or GPL-2.0-or-later)
2019-09-30 10:36:37 -04:00
URL: http://www.freedesktop.org/wiki/Software/DBusBindings/
Source0: http://dbus.freedesktop.org/releases/dbus-python/%{name}-%{version}.tar.gz
2020-08-07 11:03:12 +08:00
Source1: http://dbus.freedesktop.org/releases/dbus-python/%{name}-%{version}.tar.gz.asc
2019-09-30 10:36:37 -04:00
Patch0: 0001-Move-python-modules-to-architecture-specific-directo.patch
2020-08-07 11:03:12 +08:00
BuildRequires: dbus-devel dbus-glib-devel python2-docutils glib2-devel
2019-09-30 10:36:37 -04:00
BuildRequires: dbus-x11 python2-gobject python3-gobject
2020-03-21 14:33:57 +08:00
BuildRequires: autoconf-archive automake libtool gdb
2019-09-30 10:36:37 -04:00
%description
Dbus-python is the original Python binding for dbus, the reference
implementation of the D-Bus protocol.
%package -n python2-dbus
Summary: Python2 bindings for dbus
BuildRequires: python2-devel
Provides: %{name} = %{version}-%{release}
Provides: %{name}%{?_isa} = %{version}-%{release}
2019-11-06 19:05:19 +08:00
Obsoletes: %{name} < %{version}-%{release}
%{?python_provide:%python_provide python2-dbus}
2019-09-30 10:36:37 -04:00
%description -n python2-dbus
Python2 bindings for dbus.
%package -n python3-dbus
Summary: Python3 bindings for dbus
BuildRequires: python3-devel
2019-11-06 19:05:19 +08:00
%{?python_provide:%python_provide python3-dbus}
2019-09-30 10:36:37 -04:00
%description -n python3-dbus
Python3 bindings for dbus
%package devel
Summary: Development files for %{name}
2019-11-06 19:05:19 +08:00
Requires: %{name} = %{version}-%{release}
2019-09-30 10:36:37 -04:00
%description devel
The %{name}-devel package contains libraries and header files for
developing applications that use %{name}.
2019-11-06 19:05:19 +08:00
%package_help
2019-09-30 10:36:37 -04:00
%prep
2019-11-06 19:05:19 +08:00
%autosetup -n %{name}-%{version} -p1
2019-09-30 10:36:37 -04:00
%build
autoreconf -vif
install -d %{python2dir}
cp -a . %{python2dir}
mv %{python2dir} python2-build
install -d %{python3dir}
cp -a . %{python3dir}
mv %{python3dir} python3-build
pushd python2-build
%py2_build
%configure PYTHON="%{__python2}"
%make_build
popd
pushd python3-build
%py3_build
%configure PYTHON="%{__python3}"
%make_build
popd
2019-09-30 10:36:37 -04:00
%install
pushd python2-build
%py2_install
%make_install
popd
pushd python3-build
%py3_install
%make_install
popd
%delete_la
2019-09-30 10:36:37 -04:00
%check
make check -k -C python2-build || cat python2-build/test/test*.log
make check -k -C python3-build || cat python3-build/test/test*.log
2019-09-30 10:36:37 -04:00
%pre
%preun
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files -n python2-dbus
%license COPYING
%{python2_sitearch}/_dbus_bindings.so
%{python2_sitearch}/_dbus_glib_bindings.so
%{python2_sitearch}/dbus/
%{python2_sitearch}/dbus_python-%{version}-py%{python2_version}.egg-info
2019-09-30 10:36:37 -04:00
%files -n python3-dbus
%license COPYING
%{python3_sitearch}/_dbus_bindings.so
%{python3_sitearch}/_dbus_glib_bindings.so
%{python3_sitearch}/dbus/
%{python3_sitearch}/dbus_python-%{version}-py%{python3_version}.egg-info
2019-09-30 10:36:37 -04:00
%files devel
%{_includedir}/dbus-1.0/dbus/%{name}.h
%{_libdir}/pkgconfig/%{name}.pc
%files help
2020-08-07 11:03:12 +08:00
%doc NEWS ChangeLog README doc/API_CHANGES.txt doc/tutorial.txt
2019-09-30 10:36:37 -04:00
%changelog
* Mon Dec 06 2021 herengui <herengui@uniontech.com> - 1.2.16-3
- Type:update
- ID:NA
- SUG:NA
- DESC: correct licenses
* Thu Dec 02 2021 herengui <herengui@uniontech.com> - 1.2.16-2
- Type:update
- ID:NA
- SUG:NA
- DESC: Provides pythonXdist
2020-08-07 11:03:12 +08:00
* Fri Jul 31 2020 Liquor <lirui130@huawei.com> - 1.2.16-1
- Type:update
- ID:NA
- SUG:NA
- DESC:update to 1.2.16
2020-03-21 14:33:57 +08:00
* Sat Mar 21 2020 openEuler Buildteam <buildteam@openeuler.org> - 1.2.8-8
- Type:enhancement
- ID:NA
- SUG:NA
- DESC:add build requires of gdb
2019-11-06 19:05:19 +08:00
* Wed Oct 30 2019 jiangchuangang<jiangchuangang@huawei.com> - 1.2.8-7
- Type:enhancement
- ID:NA
- SUG:NA
- DESC:modify provides
* Sat Oct 12 2019 shenyangyang <shenyangyang4@huawei.com> - 1.2.8-6
- Type: enhancement
- ID: NA
- SUG: NA
- DESC:add python-provides
* Mon Sep 30 2019 luhuaxin <luhuaxin@huawei.com> - 1.2.8-5
- Type: enhancement
- ID: NA
- SUG: NA
- DESC: package rebuild
2019-09-30 10:36:37 -04:00
* Fri Aug 30 2019 luhuaxin <luhuaxin@huawei.com> - 1.2.8-4
- Package init