Improve rpm package generation
- Filter install.sh for PB macros - adds doc to spec file
This commit is contained in:
parent
de12b09115
commit
d94b5d4850
17
install.sh
Executable file
17
install.sh
Executable file
@ -0,0 +1,17 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Syntax: install.sh <Root Dir> <Python SiteLib> <Prefix>
|
||||||
|
|
||||||
|
export rootdir=$1
|
||||||
|
export sitelib=$2
|
||||||
|
export prefix=$3
|
||||||
|
python setup.py install --skip-build --root $rootdir
|
||||||
|
rm -rf $rootdir/$sitelib/redfish/old
|
||||||
|
|
||||||
|
for i in 1; do
|
||||||
|
mkdir -p $rootdir/$prefix/man/man$i
|
||||||
|
install -m 644 doc/build/man/*.$i $rootdir/$prefix/man/man$i
|
||||||
|
done
|
||||||
|
install -d 755 $rootdir/$prefix/doc/PBPKG/html/_static
|
||||||
|
install -m 644 doc/build/singlehtml/*.html $rootdir/$prefix/doc/PBPKG/html
|
||||||
|
install -m 644 doc/build/singlehtml/_static/* $rootdir/$prefix/doc/PBPKG/html/_static
|
@ -130,7 +130,7 @@ defpkgdir python-redfish = .
|
|||||||
|
|
||||||
# List of files per pkg on which to apply filters
|
# List of files per pkg on which to apply filters
|
||||||
# Files are mentioned relatively to pbroot/defpkgdir
|
# Files are mentioned relatively to pbroot/defpkgdir
|
||||||
filteredfiles python-redfish = redfish-client/redfish-client,doc/source/conf.py
|
filteredfiles python-redfish = redfish-client/redfish-client,doc/source/conf.py,install.sh
|
||||||
#supfiles python-redfish = python-redfish.init
|
#supfiles python-redfish = python-redfish.init
|
||||||
|
|
||||||
# For perl modules, names are different depending on distro
|
# For perl modules, names are different depending on distro
|
||||||
|
@ -30,27 +30,19 @@ make singlehtml
|
|||||||
make latexpdf
|
make latexpdf
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%{__python} setup.py install -O1 --skip-build --root %{buildroot}
|
./install.sh %{buildroot} %{python_sitelib} %{_prefix}
|
||||||
# This will go in a separate script later on to share with other distros
|
|
||||||
rm -fr %{buildroot}/%{python_sitelib}/redfish/old
|
|
||||||
|
|
||||||
for i in 1; do
|
|
||||||
mkdir -p %{buildroot}/%{_mandir}/man$i
|
|
||||||
install -m 644 doc/build/man/*.$i %{buildroot}/%{_mandir}/man$i
|
|
||||||
done
|
|
||||||
install -d 755 %{buildroot}/%{_docdir}/%{name}/html/_static
|
|
||||||
install -m 644 doc/build/singlehtml/*.html %{buildroot}/%{_docdir}/%{name}/html
|
|
||||||
install -m 644 doc/build/singlehtml/_static/* %{buildroot}/%{_docdir}/%{name}/html/_static
|
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%doc README.rst examples/[a-z]*.py LICENSE
|
%doc README.rst examples/[a-z]*.py LICENSE
|
||||||
%doc doc/build/latex/*.pdf
|
%doc doc/build/latex/*.pdf
|
||||||
%dir %{python_sitelib}/redfish
|
%doc %{_docdir}/%{name}/html
|
||||||
%dir %{_docdir}/%{name}/html
|
%doc %{_docdir}/%{name}/html/*.html
|
||||||
%{_docdir}/%{name}/html/*.html
|
%doc %{_docdir}/%{name}/html/_static
|
||||||
%dir %{_docdir}/%{name}/html/_static
|
%doc %{_docdir}/%{name}/html/_static/*
|
||||||
%{_docdir}/%{name}/html/_static/*
|
|
||||||
%{_bindir}/redfish-client
|
%{_bindir}/redfish-client
|
||||||
|
# add conf file
|
||||||
|
# add template
|
||||||
|
%dir %{python_sitelib}/redfish
|
||||||
%{python_sitelib}/redfish/*.py*
|
%{python_sitelib}/redfish/*.py*
|
||||||
%{python_sitelib}/redfish/tests/*.py*
|
%{python_sitelib}/redfish/tests/*.py*
|
||||||
%{python_sitelib}/python_redfish*
|
%{python_sitelib}/python_redfish*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user