!2 modify python-pillow.spec
Merge pull request !2 from small_leek/add_python_pillow
This commit is contained in:
commit
68cb199886
BIN
Pillow-5.3.0.tar.gz
Normal file
BIN
Pillow-5.3.0.tar.gz
Normal file
Binary file not shown.
36
README.en.md
36
README.en.md
@ -1,36 +0,0 @@
|
||||
# python-pillow
|
||||
|
||||
#### Description
|
||||
{**When you're done, you can delete the content in this README and update the file with details for others getting started with your repository**}
|
||||
|
||||
#### Software Architecture
|
||||
Software architecture description
|
||||
|
||||
#### Installation
|
||||
|
||||
1. xxxx
|
||||
2. xxxx
|
||||
3. xxxx
|
||||
|
||||
#### Instructions
|
||||
|
||||
1. xxxx
|
||||
2. xxxx
|
||||
3. xxxx
|
||||
|
||||
#### Contribution
|
||||
|
||||
1. Fork the repository
|
||||
2. Create Feat_xxx branch
|
||||
3. Commit your code
|
||||
4. Create Pull Request
|
||||
|
||||
|
||||
#### Gitee Feature
|
||||
|
||||
1. You can use Readme\_XXX.md to support different languages, such as Readme\_en.md, Readme\_zh.md
|
||||
2. Gitee blog [blog.gitee.com](https://blog.gitee.com)
|
||||
3. Explore open source project [https://gitee.com/explore](https://gitee.com/explore)
|
||||
4. The most valuable open source project [GVP](https://gitee.com/gvp)
|
||||
5. The manual of Gitee [https://gitee.com/help](https://gitee.com/help)
|
||||
6. The most popular members [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)
|
||||
39
README.md
39
README.md
@ -1,39 +0,0 @@
|
||||
# python-pillow
|
||||
|
||||
#### 介绍
|
||||
{**以下是码云平台说明,您可以替换此简介**
|
||||
码云是 OSCHINA 推出的基于 Git 的代码托管平台(同时支持 SVN)。专为开发者提供稳定、高效、安全的云端软件开发协作平台
|
||||
无论是个人、团队、或是企业,都能够用码云实现代码托管、项目管理、协作开发。企业项目请看 [https://gitee.com/enterprises](https://gitee.com/enterprises)}
|
||||
|
||||
#### 软件架构
|
||||
软件架构说明
|
||||
|
||||
|
||||
#### 安装教程
|
||||
|
||||
1. xxxx
|
||||
2. xxxx
|
||||
3. xxxx
|
||||
|
||||
#### 使用说明
|
||||
|
||||
1. xxxx
|
||||
2. xxxx
|
||||
3. xxxx
|
||||
|
||||
#### 参与贡献
|
||||
|
||||
1. Fork 本仓库
|
||||
2. 新建 Feat_xxx 分支
|
||||
3. 提交代码
|
||||
4. 新建 Pull Request
|
||||
|
||||
|
||||
#### 码云特技
|
||||
|
||||
1. 使用 Readme\_XXX.md 来支持不同的语言,例如 Readme\_en.md, Readme\_zh.md
|
||||
2. 码云官方博客 [blog.gitee.com](https://blog.gitee.com)
|
||||
3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解码云上的优秀开源项目
|
||||
4. [GVP](https://gitee.com/gvp) 全称是码云最有价值开源项目,是码云综合评定出的优秀开源项目
|
||||
5. 码云官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help)
|
||||
6. 码云封面人物是一档用来展示码云会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)
|
||||
166
python-pillow.spec
Normal file
166
python-pillow.spec
Normal file
@ -0,0 +1,166 @@
|
||||
%global py2_incdir %(python2 -c 'import distutils.sysconfig; print(distutils.sysconfig.get_python_inc())')
|
||||
%global py3_incdir %(python3 -c 'import distutils.sysconfig; print(distutils.sysconfig.get_python_inc())')
|
||||
%global py2_libbuilddir %(python2 -c 'import sys; import sysconfig; print("lib.{p}-{v[0]}.{v[1]}".format(p=sysconfig.get_platform(), v=sys.version_info))')
|
||||
%global py3_libbuilddir %(python3 -c 'import sys; import sysconfig; print("lib.{p}-{v[0]}.{v[1]}".format(p=sysconfig.get_platform(), v=sys.version_info))')
|
||||
|
||||
Name: python-pillow
|
||||
Version: 5.3.0
|
||||
Release: 3
|
||||
Summary: Python image processing library
|
||||
License: MIT
|
||||
URL: http://python-pillow.github.io/
|
||||
Source0: https://github.com/python-pillow/Pillow/archive/%{version}/Pillow-%{version}.tar.gz
|
||||
BuildRequires: freetype-devel ghostscript lcms2-devel libimagequant-devel libjpeg-devel
|
||||
BuildRequires: libtiff-devel libwebp-devel openjpeg2-devel tk-devel zlib-devel
|
||||
BuildRequires: python2-cffi python2-devel python2-numpy python2-olefile python2-setuptools
|
||||
BuildRequires: python2-sphinx python2-sphinx_rtd_theme python2-tkinter
|
||||
BuildRequires: python3-cffi python3-devel python3-numpy python3-olefile
|
||||
BuildRequires: python3-setuptools python3-sphinx python3-sphinx_rtd_theme python3-tkinter
|
||||
|
||||
Requires: ghostscript
|
||||
|
||||
%global __provides_exclude_from ^%{python2_sitearch}/PIL/.*\\.so$
|
||||
%global __provides_exclude_from ^%{python3_sitearch}/PIL/.*\\.so$
|
||||
|
||||
%description
|
||||
Pillow is the friendly PIL fork by Alex Clark and Contributors. PIL is the Python Imaging \
|
||||
Library by Fredrik Lundh and Contributors. As of 2019, Pillow development is supported by Tidelift.
|
||||
|
||||
|
||||
%package -n python2-pillow
|
||||
Summary: Python 2 image processing library
|
||||
%{?python_provide:%python_provide python2-pillow}
|
||||
Provides: python-imaging = %{version}-%{release} python2-imaging = %{version}-%{release}
|
||||
Provides: python2-pillow-tk = %{version}-%{release} python2-pillow-qt = %{version}-%{release}
|
||||
Provides: python-imaging-tk = %{version}-%{release} python2-imaging-tk = %{version}-%{release}
|
||||
Provides: python-imaging-qt = %{version}-%{release} python2-imaging-qt = %{version}-%{release}
|
||||
Requires: python2-olefile python2-tkinter python2-PyQt4
|
||||
|
||||
Obsoletes: python2-pillow-tk < %{version}-%{release} python2-pillow-qt < %{version}-%{release}
|
||||
%{?python_provide:%python_provide python2-pillow-tk}
|
||||
%{?python_provide:%python_provide python2-pillow-qt}
|
||||
|
||||
%description -n python2-pillow
|
||||
Pillow is the friendly PIL fork by Alex Clark and Contributors. PIL is the Python Imaging \
|
||||
Library by Fredrik Lundh and Contributors. As of 2019, Pillow development is supported by Tidelift.
|
||||
|
||||
|
||||
%package -n python2-pillow-devel
|
||||
Summary: Development files for pillow
|
||||
Requires: python2-devel libjpeg-devel zlib-devel python2-pillow = %{version}-%{release}
|
||||
%{?python_provide:%python_provide python2-pillow-devel}
|
||||
Provides: python-imaging-devel = %{version}-%{release} python2-imaging-devel = %{version}-%{release}
|
||||
|
||||
%description -n python2-pillow-devel
|
||||
Development files for pillow.
|
||||
|
||||
%package -n python2-pillow-help
|
||||
Summary: Documentation for pillow
|
||||
BuildArch: noarch
|
||||
Requires: python2-pillow = %{version}-%{release}
|
||||
%{?python_provide:%python_provide python2-pillow-doc}
|
||||
Provides: python-imaging-doc = %{version}-%{release} python2-imaging-doc = %{version}-%{release}
|
||||
Provides: python2-pillow-doc = %{version}-%{release}
|
||||
Obsoletes: python2-pillow-doc < %{version}-%{release}
|
||||
|
||||
%description -n python2-pillow-help
|
||||
Documentation for pillow.
|
||||
|
||||
|
||||
%package -n python3-pillow
|
||||
Summary: Python 3 image processing library
|
||||
%{?python_provide:%python_provide python3-pillow}
|
||||
Provides: python3-imaging = %{version}-%{release}
|
||||
Provides: python3-pillow-tk = %{version}-%{release} python3-imaging-tk = %{version}-%{release}
|
||||
Provides: python3-pillow-qt = %{version}-%{release} python3-imaging-qt = %{version}-%{release}
|
||||
Requires: python3-olefile python3-tkinter python3-PyQt4
|
||||
Obsoletes: python3-pillow-tk < %{version}-%{release} python3-pillow-qt < %{version}-%{release}
|
||||
%{?python_provide:%python_provide python3-pillow-tk}
|
||||
%{?python_provide:%python_provide python3-pillow-qt}
|
||||
|
||||
%description -n python3-pillow
|
||||
Pillow is the friendly PIL fork by Alex Clark and Contributors. PIL is the Python Imaging \
|
||||
Library by Fredrik Lundh and Contributors. As of 2019, Pillow development is supported by Tidelift.
|
||||
|
||||
%package -n python3-pillow-devel
|
||||
Summary: Development files for pillow
|
||||
Requires: python3-devel libjpeg-devel zlib-devel python3-pillow = %{version}-%{release}
|
||||
%{?python_provide:%python_provide python3-pillow-devel}
|
||||
Provides: python3-imaging-devel = %{version}-%{release}
|
||||
|
||||
%description -n python3-pillow-devel
|
||||
Development files for pillow.
|
||||
|
||||
%package -n python3-pillow-help
|
||||
Summary: Documentation for pillow
|
||||
BuildArch: noarch
|
||||
Requires: python3-pillow = %{version}-%{release}
|
||||
%{?python_provide:%python_provide python3-pillow-doc}
|
||||
Provides: python3-imaging-doc = %{version}-%{release} python3-pillow-doc = %{version}-%{release}
|
||||
Obsoletes: python3-pillow-doc < %{version}-%{release}
|
||||
|
||||
%description -n python3-pillow-help
|
||||
Documentation for pillow.
|
||||
|
||||
|
||||
%prep
|
||||
%autosetup -p1 -n Pillow-%{version}
|
||||
|
||||
%build
|
||||
%py2_build
|
||||
PYTHONPATH=$PWD/build/%py2_libbuilddir make -C docs html BUILDDIR=_build_py2 SPHINXBUILD=sphinx-build-%python2_version
|
||||
find . -name "docs/_build_py2/html/.buildinfo" -exec rm {} \;
|
||||
%py3_build
|
||||
PYTHONPATH=$PWD/build/%py3_libbuilddir make -C docs html BUILDDIR=_build_py3 SPHINXBUILD=sphinx-build-%python3_version
|
||||
find . -name "docs/_build_py3/html/.buildinfo" -exec rm {} \;
|
||||
|
||||
%install
|
||||
mkdir -p %{buildroot}/%{py2_incdir}/Imaging
|
||||
install -m 644 src/libImaging/*.h %{buildroot}/%{py2_incdir}/Imaging
|
||||
%py2_install
|
||||
mkdir -p %{buildroot}/%{py3_incdir}/Imaging
|
||||
install -m 644 src/libImaging/*.h %{buildroot}/%{py3_incdir}/Imaging
|
||||
%py3_install
|
||||
|
||||
|
||||
%check
|
||||
ln -s $PWD/Images $PWD/build/%py2_libbuilddir/Images
|
||||
cp -R $PWD/Tests $PWD/build/%py2_libbuilddir/Tests
|
||||
install $PWD/selftest.py $PWD/build/%py2_libbuilddir/selftest.py
|
||||
pushd build/%py2_libbuilddir
|
||||
PYTHONPATH=$PWD %{__python2} selftest.py
|
||||
popd
|
||||
|
||||
ln -s $PWD/Images $PWD/build/%py3_libbuilddir/Images
|
||||
cp -R $PWD/Tests $PWD/build/%py3_libbuilddir/Tests
|
||||
install $PWD/selftest.py $PWD/build/%py3_libbuilddir/selftest.py
|
||||
pushd build/%py3_libbuilddir
|
||||
PYTHONPATH=$PWD %{__python3} selftest.py
|
||||
popd
|
||||
|
||||
%files -n python2-pillow
|
||||
%doc README.rst CHANGES.rst
|
||||
%license docs/COPYING
|
||||
%{python2_sitearch}/*
|
||||
|
||||
%files -n python2-pillow-devel
|
||||
%{py2_incdir}/Imaging/
|
||||
|
||||
%files -n python2-pillow-help
|
||||
%doc docs/_build_py2/html
|
||||
|
||||
%files -n python3-pillow
|
||||
%doc README.rst CHANGES.rst
|
||||
%license docs/COPYING
|
||||
%{python3_sitearch}/*
|
||||
|
||||
|
||||
%files -n python3-pillow-devel
|
||||
%{py3_incdir}/Imaging/
|
||||
|
||||
%files -n python3-pillow-help
|
||||
%doc docs/_build_py3/html
|
||||
|
||||
%changelog
|
||||
* Thu Dec 12 2019 Senlin Xia <xiasenlin1@huawei.com> - 5.3.0-2
|
||||
- Package init
|
||||
Loading…
x
Reference in New Issue
Block a user