forked from pool/python-Rtree
Accepting request 1201610 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/1201610 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-Rtree?expand=0&rev=2
This commit is contained in:
@@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:be8772ca34699a9ad3fb4cfe2cfb6629854e453c10b3328039301bbfc128ca3e
|
|
||||||
size 44877
|
|
||||||
@@ -1,95 +1,65 @@
|
|||||||
diff -ur Rtree-0.9.7/setup.py Rtree-0.9.7.p/setup.py
|
Index: rtree-1.3.0/setup.py
|
||||||
--- Rtree-0.9.7/setup.py 2020-12-24 16:38:19.000000000 +0100
|
===================================================================
|
||||||
+++ Rtree-0.9.7.p/setup.py 2021-05-18 00:48:04.350602925 +0200
|
--- rtree-1.3.0.orig/setup.py
|
||||||
@@ -6,7 +6,6 @@
|
+++ rtree-1.3.0/setup.py
|
||||||
from setuptools.dist import Distribution
|
@@ -4,60 +4,11 @@ from pathlib import Path
|
||||||
|
from setuptools import setup
|
||||||
from setuptools.command.install import install
|
from setuptools.command.install import install
|
||||||
|
from setuptools.dist import Distribution
|
||||||
-from wheel.bdist_wheel import bdist_wheel as _bdist_wheel
|
-from wheel.bdist_wheel import bdist_wheel as _bdist_wheel
|
||||||
|
|
||||||
|
|
||||||
# Get text from README.txt
|
|
||||||
@@ -21,74 +20,6 @@
|
|
||||||
# current working directory of this setup.py file
|
# current working directory of this setup.py file
|
||||||
_cwd = os.path.abspath(os.path.split(__file__)[0])
|
_cwd = Path(__file__).resolve().parent
|
||||||
|
|
||||||
-
|
-
|
||||||
-class bdist_wheel(_bdist_wheel):
|
-class bdist_wheel(_bdist_wheel): # type: ignore[misc]
|
||||||
- def finalize_options(self):
|
- def finalize_options(self) -> None:
|
||||||
- _bdist_wheel.finalize_options(self)
|
- _bdist_wheel.finalize_options(self)
|
||||||
- self.root_is_pure = False
|
- self.root_is_pure = False
|
||||||
-
|
-
|
||||||
-
|
-
|
||||||
-class BinaryDistribution(Distribution):
|
-class BinaryDistribution(Distribution): # type: ignore[misc]
|
||||||
- """Distribution which always forces a binary package with platform name"""
|
- """Distribution which always forces a binary package with platform name"""
|
||||||
- def has_ext_modules(foo):
|
-
|
||||||
|
- def has_ext_modules(foo) -> bool:
|
||||||
- return True
|
- return True
|
||||||
-
|
-
|
||||||
-
|
-
|
||||||
-class InstallPlatlib(install):
|
-class InstallPlatlib(install): # type: ignore[misc]
|
||||||
- def finalize_options(self):
|
- def finalize_options(self) -> None:
|
||||||
- """
|
- """
|
||||||
- Copy the shared libraries into the wheel. Note that this
|
- Copy the shared libraries and header files into the wheel. Note that
|
||||||
- will *only* check in `rtree/lib` rather than anywhere on
|
- this will *only* check in `rtree/lib` and `include` rather than
|
||||||
- the system so if you are building a wheel you *must* copy or
|
- anywhere on the system so if you are building a wheel you *must* copy
|
||||||
- symlink the `.so`/`.dll`/`.dylib` files into `rtree/lib`.
|
- or symlink the `.so`/`.dll`/`.dylib` files into `rtree/lib` and
|
||||||
|
- `.h` into `rtree/include`.
|
||||||
- """
|
- """
|
||||||
- # use for checking extension types
|
|
||||||
- from fnmatch import fnmatch
|
|
||||||
-
|
|
||||||
- install.finalize_options(self)
|
- install.finalize_options(self)
|
||||||
- if self.distribution.has_ext_modules():
|
- if self.distribution.has_ext_modules():
|
||||||
- self.install_lib = self.install_platlib
|
- self.install_lib = self.install_platlib
|
||||||
- # now copy over libspatialindex
|
|
||||||
- # get the location of the shared library on the filesystem
|
|
||||||
-
|
-
|
||||||
- # where we're putting the shared library in the build directory
|
- # source files to copy
|
||||||
- target_dir = os.path.join(self.build_lib, 'rtree', 'lib')
|
- source_dir = _cwd / "rtree"
|
||||||
- # where are we checking for shared libraries
|
|
||||||
- source_dir = os.path.join(_cwd, 'rtree', 'lib')
|
|
||||||
-
|
-
|
||||||
- # what patterns represent shared libraries
|
- # destination for the files in the build directory
|
||||||
- patterns = {'*.so',
|
- target_dir = Path(self.build_lib) / "rtree"
|
||||||
- 'libspatialindex*dylib',
|
|
||||||
- '*.dll'}
|
|
||||||
-
|
-
|
||||||
- if not os.path.isdir(source_dir):
|
- # copy lib tree
|
||||||
- # no copying of binary parts to library
|
- source_lib = source_dir / "lib"
|
||||||
- # this is so `pip install .` works even
|
- if source_lib.is_dir():
|
||||||
- # if `rtree/lib` isn't populated
|
- target_lib = target_dir / "lib"
|
||||||
- return
|
- self.copy_tree(str(source_lib), str(target_lib))
|
||||||
-
|
-
|
||||||
- for file_name in os.listdir(source_dir):
|
- # copy include tree
|
||||||
- # make sure file name is lower case
|
- source_include = source_dir / "include"
|
||||||
- check = file_name.lower()
|
- if source_include.is_dir():
|
||||||
- # use filename pattern matching to see if it is
|
- target_include = target_dir / "include"
|
||||||
- # a shared library format file
|
- self.copy_tree(str(source_include), str(target_include))
|
||||||
- if not any(fnmatch(check, p) for p in patterns):
|
|
||||||
- continue
|
|
||||||
-
|
|
||||||
- # if the source isn't a file skip it
|
|
||||||
- if not os.path.isfile(os.path.join(source_dir, file_name)):
|
|
||||||
- continue
|
|
||||||
-
|
|
||||||
- # make build directory if it doesn't exist yet
|
|
||||||
- if not os.path.isdir(target_dir):
|
|
||||||
- os.makedirs(target_dir)
|
|
||||||
-
|
|
||||||
- # copy the source file to the target directory
|
|
||||||
- self.copy_file(
|
|
||||||
- os.path.join(source_dir, file_name),
|
|
||||||
- os.path.join(target_dir, file_name))
|
|
||||||
-
|
-
|
||||||
-
|
-
|
||||||
|
# See pyproject.toml for other project metadata
|
||||||
setup(
|
setup(
|
||||||
name='Rtree',
|
name="Rtree",
|
||||||
version=__version__,
|
|
||||||
@@ -105,8 +36,6 @@
|
|
||||||
package_data={"rtree": ['lib']},
|
|
||||||
zip_safe=False,
|
|
||||||
include_package_data=True,
|
|
||||||
- distclass=BinaryDistribution,
|
- distclass=BinaryDistribution,
|
||||||
- cmdclass={'bdist_wheel': bdist_wheel, 'install': InstallPlatlib},
|
- cmdclass={"bdist_wheel": bdist_wheel, "install": InstallPlatlib},
|
||||||
classifiers=[
|
)
|
||||||
'Development Status :: 5 - Production/Stable',
|
|
||||||
'Intended Audience :: Developers',
|
|
||||||
|
|||||||
@@ -1,3 +1,12 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Sep 17 11:34:46 UTC 2024 - Nico Krapp <nico.krapp@suse.com>
|
||||||
|
|
||||||
|
- Update to 1.3.0
|
||||||
|
* Upgrade binary wheels with libspatialindex-2.0.0 (#316)
|
||||||
|
* Fix binary wheels for musllinux (#316)
|
||||||
|
* Update code style, replace isort and black with ruff, modern numpy rng (#319)
|
||||||
|
* Remove libsidx version testing (#313)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed May 19 10:29:54 UTC 2021 - Ben Greiner <code@bnavigator.de>
|
Wed May 19 10:29:54 UTC 2021 - Ben Greiner <code@bnavigator.de>
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package python-Rtree
|
# spec file for package python-Rtree
|
||||||
#
|
#
|
||||||
# Copyright (c) 2021 SUSE LLC
|
# Copyright (c) 2024 SUSE LLC
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@@ -16,21 +16,22 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
%{?sle15_python_module_pythons}
|
||||||
%define skip_python36 1
|
|
||||||
Name: python-Rtree
|
Name: python-Rtree
|
||||||
Version: 0.9.7
|
Version: 1.3.0
|
||||||
Release: 0
|
Release: 0
|
||||||
Summary: R-Tree spatial index for Python GIS
|
Summary: R-Tree spatial index for Python GIS
|
||||||
License: MIT
|
License: MIT
|
||||||
URL: https://github.com/Toblerity/rtree
|
URL: https://github.com/Toblerity/rtree
|
||||||
Source: https://files.pythonhosted.org/packages/source/R/Rtree/Rtree-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/R/Rtree/rtree-%{version}.tar.gz
|
||||||
Source99: python-Rtree-rpmlintrc
|
Source99: python-Rtree-rpmlintrc
|
||||||
# PATCH-FIX-OPENSUSE Rtree-opensuse-noarch.patch -- we don't put spatialindex into a wheel so the module is kept pure. <code@bnavigator.de>
|
# PATCH-FIX-OPENSUSE Rtree-opensuse-noarch.patch -- we don't put spatialindex into a wheel so the module is kept pure. <code@bnavigator.de>
|
||||||
Patch0: Rtree-opensuse-noarch.patch
|
Patch0: Rtree-opensuse-noarch.patch
|
||||||
BuildRequires: %{python_module numpy}
|
BuildRequires: %{python_module numpy}
|
||||||
|
BuildRequires: %{python_module pip}
|
||||||
BuildRequires: %{python_module pytest}
|
BuildRequires: %{python_module pytest}
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools}
|
||||||
|
BuildRequires: %{python_module wheel}
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
# only for the shlib requirement, no headers needed
|
# only for the shlib requirement, no headers needed
|
||||||
BuildRequires: spatialindex-devel
|
BuildRequires: spatialindex-devel
|
||||||
@@ -55,7 +56,7 @@ spatial indexing features for the spatially curious Python user.
|
|||||||
for example)
|
for example)
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%autosetup -p1 -n Rtree-%{version}
|
%autosetup -p1 -n rtree-%{version}
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%python_build
|
%python_build
|
||||||
|
|||||||
3
rtree-1.3.0.tar.gz
Normal file
3
rtree-1.3.0.tar.gz
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:b36e9dd2dc60ffe3d02e367242d2c26f7281b00e1aaf0c39590442edaaadd916
|
||||||
|
size 48190
|
||||||
Reference in New Issue
Block a user