1 | %{!?python3_sitearch: %define python3_sitearch %(python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")} |
---|
2 | %{!?python3_sitelib: %global python3_sitelib %(python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")} |
---|
3 | |
---|
4 | %define dbus_glib_version 0.70 |
---|
5 | %define dbus_version 1.6 |
---|
6 | %define pkg_release 1%{?_dist_release} |
---|
7 | |
---|
8 | Name: dbus-python3 |
---|
9 | Summary: D-Bus Python3 Bindings |
---|
10 | Summary(ja): D-Bus Python3 バインディング |
---|
11 | Version: 1.2.0 |
---|
12 | Release: %{pkg_release} |
---|
13 | |
---|
14 | Group: System Environment/Libraries |
---|
15 | License: MIT |
---|
16 | URL: http://www.freedesktop.org/software/dbus/ |
---|
17 | |
---|
18 | Source0: http://dbus.freedesktop.org/releases/dbus-python/dbus-python-%{version}.tar.gz |
---|
19 | |
---|
20 | BuildRoot: %{_tmppath}/%{name}-%{version}-root |
---|
21 | BuildRequires: dbus-devel >= %{dbus_version} |
---|
22 | BuildRequires: dbus-glib-devel >= %{dbus_glib_version} |
---|
23 | BuildRequires: python3-devel |
---|
24 | |
---|
25 | %description |
---|
26 | D-Bus python3 bindings for use with python programs. |
---|
27 | |
---|
28 | %description -l ja |
---|
29 | D-Bus を python3 プログラムから使う為のバインディングです。 |
---|
30 | |
---|
31 | |
---|
32 | %prep |
---|
33 | %setup -q -n dbus-python-%{version} |
---|
34 | |
---|
35 | %build |
---|
36 | %configure PYTHON=/usr/bin/python3 |
---|
37 | %{__make} %{?_smp_mflags} |
---|
38 | |
---|
39 | |
---|
40 | %install |
---|
41 | %{__rm} -rf ${RPM_BUILD_ROOT} |
---|
42 | %{__make} install DESTDIR=${RPM_BUILD_ROOT} |
---|
43 | |
---|
44 | # remove unnecessary *.la files |
---|
45 | find ${RPM_BUILD_ROOT} -name '*.la' -exec rm -f {} \; |
---|
46 | |
---|
47 | # remove conflict files with dbus-python |
---|
48 | rm -f ${RPM_BUILD_ROOT}%{_includedir}/dbus-1.0/dbus/dbus-python.h |
---|
49 | rm -f ${RPM_BUILD_ROOT}%{_libdir}/pkgconfig/dbus-python.pc |
---|
50 | rm -f ${RPM_BUILD_ROOT}%{_docdir}/dbus-python/* |
---|
51 | |
---|
52 | |
---|
53 | %clean |
---|
54 | rm -rf ${RPM_BUILD_ROOT} |
---|
55 | |
---|
56 | %files |
---|
57 | %defattr(-,root,root) |
---|
58 | %doc COPYING ChangeLog README NEWS |
---|
59 | %{python3_sitearch}/*.so |
---|
60 | %{python3_sitelib}/dbus/*.py* |
---|
61 | %{python3_sitelib}/dbus/mainloop/*.py* |
---|
62 | |
---|
63 | %changelog |
---|
64 | * Sun Apr 13 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.2.0-1 |
---|
65 | - initial build |
---|
66 | |
---|