Accepting request 541802 from home:pluskalm:branches:devel:languages:python

- Use more of python building macros
- Do not build documentation (build is broken if /usr/bin/python is
  not present anyways)
- Run spec-cleaner

OBS-URL: https://build.opensuse.org/request/show/541802
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-systemd?expand=0&rev=16
This commit is contained in:
Johannes Weberhofer 2017-11-14 13:24:38 +00:00 committed by Git OBS Bridge
parent 4b7d586e73
commit 083c5df372
2 changed files with 12 additions and 19 deletions

View File

@ -1,3 +1,11 @@
-------------------------------------------------------------------
Tue Nov 14 12:47:02 UTC 2017 - mpluskal@suse.com
- Use more of python building macros
- Do not build documentation (build is broken if /usr/bin/python is
not present anyways)
- Run spec-cleaner
------------------------------------------------------------------- -------------------------------------------------------------------
Mon Nov 6 18:15:19 UTC 2017 - jweberhofer@weberhofer.at Mon Nov 6 18:15:19 UTC 2017 - jweberhofer@weberhofer.at

View File

@ -39,19 +39,12 @@ BuildRequires: python-rpm-macros
BuildRequires: systemd-devel BuildRequires: systemd-devel
Requires: systemd Requires: systemd
Suggests: %{name}-doc Suggests: %{name}-doc
# SECTION docs
BuildRequires: python3-Sphinx
# /SECTION # /SECTION
%if %{with test} %if %{with test}
BuildRequires: %{python_module pytest} BuildRequires: %{python_module pytest}
%endif %endif
%python_subpackages %python_subpackages
%package -n %{name}-doc
Summary: Documentation for python-systemd
Group: Documentation/HTML
Requires: %{name} = %{version}
%description %description
Python module for native access to the systemd facilities. Functionality is seperated into a number of modules: Python module for native access to the systemd facilities. Functionality is seperated into a number of modules:
* systemd.journal supports sending of structured messages to the journal and reading journal files, * systemd.journal supports sending of structured messages to the journal and reading journal files,
@ -59,33 +52,25 @@ Python module for native access to the systemd facilities. Functionality is sepe
* systemd.id128 provides functions for querying machine and boot identifiers and a lists of message identifiers provided by systemd, * systemd.id128 provides functions for querying machine and boot identifiers and a lists of message identifiers provided by systemd,
* systemd.login wraps parts of libsystemd used to query logged in users and available seats and machines. * systemd.login wraps parts of libsystemd used to query logged in users and available seats and machines.
%description -n %{name}-doc
Documentation and help files for python-systemd.
%prep %prep
%setup -q %setup -q
%patch1 -p1 %patch1 -p1
%patch100 -p1 %patch100 -p1
%build %build
%{python_expand make PYTHON=$python %{?_smp_mflags} build} %python_build
make %{?_smp_mflags} sphinx-html
rm -r build/html/.buildinfo build/html/.doctrees build/html/_sources
%install %install
%{python_expand %make_install PYTHON=$python %python_install
%fdupes %{buildroot}/%{$python_sitearch}} %fdupes %{buildroot}
%if %{with test} %if %{with test}
%check %check
%{python_expand make PYTHON=$python %{?_smp_mflags} check} %python_exec setup.py check
%endif %endif
%files %{python_files} %files %{python_files}
%doc LICENSE.txt README.md %doc LICENSE.txt README.md
%{python_sitearch}/* %{python_sitearch}/*
%files -n %{name}-doc
%doc build/html
%changelog %changelog