diff --git a/README.en.md b/README.en.md deleted file mode 100644 index f53b18a34c665c63b2e79477c02bde0217dc5519..0000000000000000000000000000000000000000 --- a/README.en.md +++ /dev/null @@ -1,36 +0,0 @@ -# python-networkx - -#### Description -python package for the study of complex network - -#### 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/) diff --git a/README.md b/README.md deleted file mode 100644 index 71101a53fd5f64ae2568f0f5f4705f9cb715e084..0000000000000000000000000000000000000000 --- a/README.md +++ /dev/null @@ -1,37 +0,0 @@ -# python-networkx - -#### 介绍 -python package for the study of complex network - -#### 软件架构 -软件架构说明 - - -#### 安装教程 - -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/) diff --git a/networkx-1.11.tar.gz b/networkx-1.11.tar.gz deleted file mode 100644 index d9359596f678ff590c25d3aa90b47eefdf87b45b..0000000000000000000000000000000000000000 Binary files a/networkx-1.11.tar.gz and /dev/null differ diff --git a/networkx-2.5.tar.gz b/networkx-2.5.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..226b6c1ee34ad173049d463394d35e48ac841f76 Binary files /dev/null and b/networkx-2.5.tar.gz differ diff --git a/networkx-optional-modules.patch b/networkx-optional-modules.patch deleted file mode 100644 index 6d2cc35f352fe86141f58fec418f353749b21a88..0000000000000000000000000000000000000000 --- a/networkx-optional-modules.patch +++ /dev/null @@ -1,29 +0,0 @@ -make importing of drawing and geo subpackages optional - -diff -Naur networkx-networkx-1.10.orig/networkx/__init__.py networkx-networkx-1.10/networkx/__init__.py ---- networkx-networkx-1.10.orig/networkx/__init__.py 2015-10-30 15:41:35.000000000 -0600 -+++ networkx-networkx-1.10/networkx/__init__.py 2015-11-24 09:34:20.741823392 -0700 -@@ -95,5 +95,8 @@ - from networkx.linalg import * - from networkx.tests.test import run as test - --import networkx.drawing --from networkx.drawing import * -+try: -+ import networkx.drawing -+ from networkx.drawing import * -+except ImportError: -+ pass -diff -Naur networkx-networkx-1.10.orig/networkx/readwrite/__init__.py networkx-networkx-1.10/networkx/readwrite/__init__.py ---- networkx-networkx-1.10.orig/networkx/readwrite/__init__.py 2015-10-30 15:41:35.000000000 -0600 -+++ networkx-networkx-1.10/networkx/readwrite/__init__.py 2015-11-24 09:34:46.539738141 -0700 -@@ -14,4 +14,8 @@ - from networkx.readwrite.gml import * - from networkx.readwrite.graphml import * - from networkx.readwrite.gexf import * --from networkx.readwrite.nx_shp import * -+ -+try: -+ from networkx.readwrite.nx_shp import * -+except ImportError: -+ pass diff --git a/python-networkx-sphinx.patch b/python-networkx-sphinx.patch deleted file mode 100644 index 137e98e291f61522771790636e0eb9321c1a575a..0000000000000000000000000000000000000000 --- a/python-networkx-sphinx.patch +++ /dev/null @@ -1,11 +0,0 @@ -diff -up networkx-networkx-1.11/doc/source/conf.py.sphinx networkx-networkx-1.11/doc/source/conf.py ---- networkx-networkx-1.11/doc/source/conf.py.sphinx 2016-01-30 10:25:44.000000000 -0700 -+++ networkx-networkx-1.11/doc/source/conf.py 2016-12-23 09:54:55.280925006 -0700 -@@ -74,7 +74,6 @@ extensions = [ - 'sphinx.ext.intersphinx', - 'sphinx.ext.mathjax', - 'sphinx.ext.napoleon', -- 'sphinx.ext.pngmath', - 'sphinx.ext.todo', - 'sphinx.ext.viewcode', - #'sphinxcontrib.bibtex', diff --git a/python-networkx.spec b/python-networkx.spec index 3a451aa5aead701c30cc2d762242f820192c56b9..fb5c4e7b9cb7cc10f1c895c21295d91413c90757 100644 --- a/python-networkx.spec +++ b/python-networkx.spec @@ -1,213 +1,100 @@ -Name: python-networkx -Version: 1.11 -Release: 14 -Summary: Python package for creating and manipulating graphs and networks -License: BSD -URL: http://networkx.github.io/ -Source0: https://github.com/networkx/networkx/archive/networkx-1.11.tar.gz -# make importing of drawing and geo subpackages optional -Patch0000: networkx-optional-modules.patch -# Fix sphinx build error -# https://github.com/networkx/networkx/issues/2340 -Patch0001: python-networkx-sphinx.patch -BuildArch: noarch +%global _empty_manifest_terminate_build 0 +Name: python-networkx +Version: 2.5 +Release: 1 +Summary: Python package for creating and manipulating graphs and networks +License: BSD License +URL: http://networkx.github.io/ +Source0: https://files.pythonhosted.org/packages/ef/d0/f706a9e5814a42c544fa1b2876fc33e5d17e1f2c92a5361776632c4f41ab/networkx-2.5.tar.gz +BuildArch: noarch + +Requires: python3-decorator +Requires: python3-numpy +Requires: python3-scipy +Requires: python3-pandas +Requires: python3-matplotlib +Requires: python3-pygraphviz +Requires: python3-pydot +Requires: python3-pyyaml +Requires: python3-lxml +Requires: python3-pytest +Requires: python3-gdal +Requires: python3-lxml +Requires: python3-matplotlib +Requires: python3-numpy +Requires: python3-pandas +Requires: python3-pydot +Requires: python3-pygraphviz +Requires: python3-pytest +Requires: python3-pyyaml +Requires: python3-scipy %description -NetworkX is a Python 2 package for the creation, manipulation, and -study of the structure, dynamics, and functions of complex networks. - -%package -n python2-networkx -Summary: Creates and Manipulates Graphs and Networks -Requires: python2-networkx-core = 1.11-14 python2-networkx-geo = 1.11-14 -Requires: python2-networkx-drawing = 1.11-14 - -%{?python_provide:%python_provide python2-networkx} - -%description -n python2-networkx -NetworkX is a Python 2 package for the creation, manipulation, and -study of the structure, dynamics, and functions of complex networks. - -%package -n python2-networkx-core -Summary: Creates and Manipulates Graphs and Networks -BuildRequires: python2-devel python2-decorator python2-scipy python2-setuptools -BuildRequires: python2-yaml python2-pyparsing python2-nose -Requires: python2-decorator python2-scipy python2-yaml python2-pyparsing - -%{?python_provide:%python_provide python2-networkx-core} - -%description -n python2-networkx-core -NetworkX is a Python 2 package for the creation, manipulation, and -study of the structure, dynamics, and functions of complex networks. - -%package -n python2-networkx-geo -Summary: GDAL I/O -Requires: python2-networkx-core = 1.11-14 python2-gdal -BuildRequires: python2-gdal - -%{?python_provide:%python_provide python2-networkx-geo} - -%description -n python2-networkx-geo -NetworkX is a Python 3 package for the creation, manipulation, and -study of the structure, dynamics, and functions of complex networks. - -This package provides GDAL I/O support. - -%package -n python2-networkx-drawing -Summary: visual representations for graphs and networks -Requires: python2-networkx-core = 1.11-14 -BuildRequires: python2.7dist(gv) python2-matplotlib python2-pydotplus -Requires: python2.7dist(gv) python2-matplotlib python2-pydotplus - -%{?python_provide:%python_provide python2-networkx-drawing} - -%description -n python2-networkx-drawing -NetworkX is a Python 3 package for the creation, manipulation, and -study of the structure, dynamics, and functions of complex networks. - -This package provides support for graph visualizations. +NetworkX is a Python package for the creation, manipulation, +and study of the structure, dynamics, and functions +of complex networks. %package -n python3-networkx -Summary: Creates and Manipulates Graphs and Networks -Requires: python3-networkx-core = 1.11-14 python3-networkx-geo = 1.11-14 -Requires: python3-networkx-drawing = 1.11-14 - -%{?python_provide:%python_provide python3-networkx} - +Summary: Python package for creating and manipulating graphs and networks +Provides: python-networkx +BuildRequires: python3-devel +BuildRequires: python3-setuptools %description -n python3-networkx -NetworkX is a Python 3 package for the creation, manipulation, and -study of the structure, dynamics, and functions of complex networks. - -%package -n python3-networkx-core -Summary: Creates and Manipulates Graphs and Networks -BuildRequires: python3-devel python3-decorator python3-yaml -BuildRequires: python3-scipy python3-pyparsing python3-setuptools -Requires: python3-decorator python3-yaml python3-scipy python3-pyparsing - -%{?python_provide:%python_provide python3-networkx-core} - -%description -n python3-networkx-core -NetworkX is a Python 3 package for the creation, manipulation, and -study of the structure, dynamics, and functions of complex networks. - -%package -n python3-networkx-geo -Summary: GDAL I/O -Requires: python3-networkx-core = 1.11-14 gdal-python3 -BuildRequires: gdal-python3 - -%{?python_provide:%python_provide python3-networkx-geo} - -%description -n python3-networkx-geo -NetworkX is a Python 3 package for the creation, manipulation, and -study of the structure, dynamics, and functions of complex networks. - -This package provides GDAL I/O support. - -%package -n python3-networkx-drawing -Summary: visual representations for graphs and networks -Requires: python3-networkx-core = 1.11-14 python3-matplotlib python3-pydotplus -BuildRequires: python3-matplotlib python3-pydotplus - -%{?python_provide:%python_provide python3-networkx-drawing} - -%description -n python3-networkx-drawing -NetworkX is a Python 3 package for the creation, manipulation, and -study of the structure, dynamics, and functions of complex networks. - -This package provides support for graph visualizations. +NetworkX is a Python package for the creation, manipulation, +and study of the structure, dynamics, and functions +of complex networks. %package help -Summary: Documentation for networkx -BuildRequires: python2-pandas python2-pydotplus python2-sphinx python2-sphinx_rtd_theme -BuildRequires: python2-sphinxcontrib-bibtex python2-ipython python2-numpydoc -BuildRequires: tex(latex) tex-preview python2-matplotlib -Provides: bundled(jquery) python-networkx-doc = 1.11-14 -Obsoletes: python-networkx-doc < 1.11-14 +Summary: Development documents and examples for networkx +Provides: python3-networkx-doc %description help -Documentation for networkx +NetworkX is a Python package for the creation, manipulation, +and study of the structure, dynamics, and functions +of complex networks. %prep -%autosetup -n networkx-networkx-%{version} -p1 -find examples -type f -perm /0111 | xargs chmod a-x +%autosetup -n networkx-2.5 %build -%py2_build -sed -i 's/^[[:blank:]]*python/&2/' doc/Makefile -PYTHONPATH=$PWD/build/lib make SPHINXBUILD=sphinx-build-2 -C doc html - -mv build build2 -mv networkx/*.pyc build2 - %py3_build %install %py3_install - -mv build build3 -mv build2 build -mv -f build/*.pyc networkx - -%py2_install -mv $RPM_BUILD_ROOT%{_docdir}/networkx-1.11 ./installed-docs -rm -f installed-docs/INSTALL.txt - -for f in `grep -FRl /usr/bin/env $RPM_BUILD_ROOT%{python2_sitelib}`; do - sed 's|/usr/bin/env python|%{_bindir}/python2|' $f > $f.new - touch -r $f $f.new - chmod a+x $f.new - mv -f $f.new $f -done - -for f in `grep -FRl /usr/bin/env $RPM_BUILD_ROOT%{python3_sitelib}`; do - sed 's|/usr/bin/env python|%{_bindir}/python3|' $f > $f.new - touch -r $f $f.new - chmod a+x $f.new - mv -f $f.new $f -done - -%clean -rm -fr %{buildroot} -rm -f /tmp/tmp?????? - -%check -mkdir site-packages -mv networkx site-packages -PYTHONPATH=$PWD/site-packages python2 -c "import networkx; networkx.test()" - -%files -n python2-networkx -%doc README.rst LICENSE.txt - -%files -n python2-networkx-core -%doc installed-docs/* -%{python2_sitelib}/* -%exclude %{python2_sitelib}/networkx/drawing/ -%exclude %{python2_sitelib}/networkx/readwrite/nx_shp.py* - -%files -n python2-networkx-drawing -%{python2_sitelib}/networkx/drawing - -%files -n python2-networkx-geo -%{python2_sitelib}/networkx/readwrite/nx_shp.py* - -%files -n python3-networkx -%doc README.rst LICENSE.txt - -%files -n python3-networkx-core -%doc installed-docs/* -%{python3_sitelib}/* -%exclude %{python3_sitelib}/networkx/drawing/ -%exclude %{python3_sitelib}/networkx/readwrite/nx_shp.py -%exclude %{python3_sitelib}/networkx/readwrite/__pycache__/nx_shp.* - -%files -n python3-networkx-drawing -%{python3_sitelib}/networkx/drawing - -%files -n python3-networkx-geo -%{python3_sitelib}/networkx/readwrite/nx_shp.py -%{python3_sitelib}/networkx/readwrite/__pycache__/nx_shp.* - -%files help -%doc doc/build/html/* +install -d -m755 %{buildroot}/%{_pkgdocdir} +if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi +if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi +if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi +if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi +pushd %{buildroot} +if [ -d usr/lib ]; then + find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/lib64 ]; then + find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/bin ]; then + find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/sbin ]; then + find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst +fi +touch doclist.lst +if [ -d usr/share/man ]; then + find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst +fi +popd +mv %{buildroot}/filelist.lst . +mv %{buildroot}/doclist.lst . + +%files -n python3-networkx -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* %changelog +* Wed Sep 30 2020 Python_Bot 2.5-1 +- Package Spec generated + * Tue May 10 2020 liangdong - 1.11-14 - Package init diff --git a/python-networkx.yaml b/python-networkx.yaml new file mode 100644 index 0000000000000000000000000000000000000000..af4cbd01ce8c182bd8b7c73864a873e0ee9c88ff --- /dev/null +++ b/python-networkx.yaml @@ -0,0 +1,4 @@ +version_control: pypi +src_repo: networkx +tag_prefix: +seperator: .