!10 修复python-hyperlink在master工程编译失败

From: @penelope_y 
Reviewed-by: @myeuler 
Signed-off-by: @myeuler
This commit is contained in:
openeuler-ci-bot 2022-04-02 10:59:39 +00:00 committed by Gitee
commit da9c95e978
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -1,6 +1,8 @@
%bcond_with docs
Name: python-hyperlink Name: python-hyperlink
Version: 18.0.0 Version: 18.0.0
Release: 10 Release: 11
Summary: A pure-Python implementation of immutable URLs Summary: A pure-Python implementation of immutable URLs
License: MIT and BSD and OFL License: MIT and BSD and OFL
URL: https://github.com/python-hyper/hyperlink URL: https://github.com/python-hyper/hyperlink
@ -21,7 +23,9 @@ Hyperlink is a featureful, pure-Python implementation of the URL, with an emphas
%package help %package help
Summary: This package contains help documents Summary: This package contains help documents
%if %{with docs}
Requires: fontawesome-fonts Requires: fontawesome-fonts
%endif
Provides: python-hyperlink-doc = %{version}-%{release} Provides: python-hyperlink-doc = %{version}-%{release}
Obsoletes: python-hyperlink-doc < %{version}-%{release} Obsoletes: python-hyperlink-doc < %{version}-%{release}
@ -34,6 +38,8 @@ rm -rf hyperlink.egg-info
%build %build
%py3_build %py3_build
%if %{with docs}
PYTHONPATH=${PWD} sphinx-build-3 docs html PYTHONPATH=${PWD} sphinx-build-3 docs html
rm -rf html/.{doctrees,buildinfo} html/_static/underscore*.js html/_static/jquery*.js rm -rf html/.{doctrees,buildinfo} html/_static/underscore*.js html/_static/jquery*.js
cd html/_static/fonts/ cd html/_static/fonts/
@ -46,6 +52,7 @@ ln -s /usr/share/javascript/underscore/underscore-min.js html/_static/underscore
ln -s /usr/share/javascript/underscore/underscore.js html/_static/underscore-1.3.1.js ln -s /usr/share/javascript/underscore/underscore.js html/_static/underscore-1.3.1.js
ln -s /usr/share/javascript/jquery/3.2.1/jquery.min.js html/_static/jquery.js ln -s /usr/share/javascript/jquery/3.2.1/jquery.min.js html/_static/jquery.js
ln -s /usr/share/javascript/jquery/3.2.1/jquery.js html/_static/jquery-3.2.1.js ln -s /usr/share/javascript/jquery/3.2.1/jquery.js html/_static/jquery-3.2.1.js
%endif
%install %install
%py3_install %py3_install
@ -56,12 +63,19 @@ ln -s /usr/share/javascript/jquery/3.2.1/jquery.js html/_static/jquery-3.2.1.js
%files -n python3-hyperlink %files -n python3-hyperlink
%doc LICENSE %doc LICENSE
%{python3_sitelib}/hyperlink %{python3_sitelib}/hyperlink
%{python3_sitelib}/hyperlink-%{version}-py?.?.egg-info %{python3_sitelib}/hyperlink-%{version}-py%{python3_version}.egg-info
%files help %files help
%if %{with docs}
%doc README.md html %doc README.md html
%else
%doc README.md
%endif
%changelog %changelog
* Fri Apr 01 2022 xigaoxinyan <xigaoxinyan@huawei.com> - 18.0.0-11
- Drop docs package: sphinx Update make docs build error and Fix build error caused by py3.10+ wildcard
* Mon Dec 07 2020 zhangjiapeng <zhangjiapeng9@huawei.com> - 18.0.0-10 * Mon Dec 07 2020 zhangjiapeng <zhangjiapeng9@huawei.com> - 18.0.0-10
- Add python3-devel dependency - Add python3-devel dependency