Also build documentation

This commit is contained in:
Zbigniew Jędrzejewski-Szmek 2015-07-08 15:55:48 -04:00
parent 4e34883fe7
commit ce361e1cc5
3 changed files with 15 additions and 10 deletions

1
.gitignore vendored
View File

@ -0,0 +1 @@
/python-systemd-230.tar.gz

View File

@ -5,10 +5,12 @@ Summary: Python module wrapping systemd functionality
License: LGPLv2+ License: LGPLv2+
URL: https://github.com/systemd/python-systemd URL: https://github.com/systemd/python-systemd
Source0: https://github.com/systemd/python-systemd/archive/v%{version}.tar.gz #Source0: https://github.com/systemd/python-systemd/archive/v%%{version}.tar.gz
# 'make dist' output from https://github.com/systemd/python-systemd/
Source0: python-systemd-%{version}.tar.gz
BuildRequires: python2-devel
BuildRequires: systemd-devel BuildRequires: systemd-devel
BuildRequires: python2-devel
Provides: systemd-python = %{version}-%{release} Provides: systemd-python = %{version}-%{release}
Provides: systemd-python%{?_isa} = %{version}-%{release} Provides: systemd-python%{?_isa} = %{version}-%{release}
@ -28,6 +30,7 @@ This is the version for Python 2.
%package -n python3-systemd %package -n python3-systemd
Summary: %{summary} Summary: %{summary}
BuildRequires: python3-devel BuildRequires: python3-devel
BuildRequires: python3-sphinx
Provides: systemd-python3 = %{version}-%{release} Provides: systemd-python3 = %{version}-%{release}
Provides: systemd-python3%{?_isa} = %{version}-%{release} Provides: systemd-python3%{?_isa} = %{version}-%{release}
@ -46,23 +49,23 @@ This is the version for Python 3.
%autosetup %autosetup
%build %build
sed -n -r 's/,//g; s/#define (SD_MESSAGE_[A-Z0-9_]+)\s.*/add_id(m, "\1", \1) JOINER/p' \ make PYTHON=%{__python2} build
</usr/include/systemd/sd-messages.h >systemd/id128-constants.h make PYTHON=%{__python3} build
%{__python2} setup.py build make PYTHON=%{__python3} SPHINX_BUILD=sphinx-build-3 sphinx-html
%{__python3} setup.py build rm -r build/html/.buildinfo build/html/.doctrees
%install %install
%{__python2} setup.py install -O1 --skip-build --root %{buildroot} %make_install PYTHON=%{__python2}
%{__python3} setup.py install -O1 --skip-build --root %{buildroot} %make_install PYTHON=%{__python3}
%files %files
%license LICENSE.txt %license LICENSE.txt
%doc README.md %doc README.md build/html
%{python2_sitearch}/* %{python2_sitearch}/*
%files -n python3-systemd %files -n python3-systemd
%license LICENSE.txt %license LICENSE.txt
%doc README.md %doc %{_pkgdocdir}
%{python3_sitearch}/* %{python3_sitearch}/*
%changelog %changelog

View File

@ -0,0 +1 @@
9ead70ab71bf42fb99e94e8af1ed78a5 python-systemd-230.tar.gz