diff options
| author | CoprDistGit <infra@openeuler.org> | 2023-04-10 18:48:53 +0000 |
|---|---|---|
| committer | CoprDistGit <infra@openeuler.org> | 2023-04-10 18:48:53 +0000 |
| commit | fb585d5c1ab9c2b91a092e47477f084bb8366138 (patch) | |
| tree | 92fd483002a0be3687f34acee8a89d87249adc00 /python-pyepsg.spec | |
| parent | cbb3bb0a0435ffe50f01f6273784427c061af214 (diff) | |
automatic import of python-pyepsg
Diffstat (limited to 'python-pyepsg.spec')
| -rw-r--r-- | python-pyepsg.spec | 121 |
1 files changed, 121 insertions, 0 deletions
diff --git a/python-pyepsg.spec b/python-pyepsg.spec new file mode 100644 index 0000000..3e0ce86 --- /dev/null +++ b/python-pyepsg.spec @@ -0,0 +1,121 @@ +%global _empty_manifest_terminate_build 0 +Name: python-pyepsg +Version: 0.4.0 +Release: 1 +Summary: Easy access to the EPSG database via http://epsg.io/ +License: GNU Lesser General Public License v3 (LGPLv3) +URL: https://github.com/rhattersley/pyepsg +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/15/88/78cbedccbf89ac2afbf02f54463bfecbd7908362c43766fc058c1dcab9cf/pyepsg-0.4.0.tar.gz +BuildArch: noarch + +Requires: python3-requests + +%description +|build_status| +A simple interface to http://epsg.io/ +For example, we can request the details for the projected coordinate system +identified by EPSG code 21781, aka. "Swiss CH1903 / LV03":: + >>> projection = pyepsg.get(21781) + >>> projection + <ProjectedCRS: 21781, CH1903 / LV03> + >>> projection.domain_of_validity() + [5.97, 10.49, 45.83, 47.81] + >>> projection.cartesian_cs.axes + [<Axis: east / metre>, <Axis: north / metre>] +Projected and geodetic coordinate systems can also be converted to various +other forms:: + >>> print(projection.as_proj4()[:70] + '...') + +proj=somerc +lat_0=46.95240555555556 +lon_0=7.439583333333333 +k_0=1 ... + >>> print(projection.as_wkt()[:70] + '...') + PROJCS["CH1903 / LV03",GEOGCS["CH1903",DATUM["CH1903",SPHEROID["Bessel... + +%package -n python3-pyepsg +Summary: Easy access to the EPSG database via http://epsg.io/ +Provides: python-pyepsg +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-pyepsg +|build_status| +A simple interface to http://epsg.io/ +For example, we can request the details for the projected coordinate system +identified by EPSG code 21781, aka. "Swiss CH1903 / LV03":: + >>> projection = pyepsg.get(21781) + >>> projection + <ProjectedCRS: 21781, CH1903 / LV03> + >>> projection.domain_of_validity() + [5.97, 10.49, 45.83, 47.81] + >>> projection.cartesian_cs.axes + [<Axis: east / metre>, <Axis: north / metre>] +Projected and geodetic coordinate systems can also be converted to various +other forms:: + >>> print(projection.as_proj4()[:70] + '...') + +proj=somerc +lat_0=46.95240555555556 +lon_0=7.439583333333333 +k_0=1 ... + >>> print(projection.as_wkt()[:70] + '...') + PROJCS["CH1903 / LV03",GEOGCS["CH1903",DATUM["CH1903",SPHEROID["Bessel... + +%package help +Summary: Development documents and examples for pyepsg +Provides: python3-pyepsg-doc +%description help +|build_status| +A simple interface to http://epsg.io/ +For example, we can request the details for the projected coordinate system +identified by EPSG code 21781, aka. "Swiss CH1903 / LV03":: + >>> projection = pyepsg.get(21781) + >>> projection + <ProjectedCRS: 21781, CH1903 / LV03> + >>> projection.domain_of_validity() + [5.97, 10.49, 45.83, 47.81] + >>> projection.cartesian_cs.axes + [<Axis: east / metre>, <Axis: north / metre>] +Projected and geodetic coordinate systems can also be converted to various +other forms:: + >>> print(projection.as_proj4()[:70] + '...') + +proj=somerc +lat_0=46.95240555555556 +lon_0=7.439583333333333 +k_0=1 ... + >>> print(projection.as_wkt()[:70] + '...') + PROJCS["CH1903 / LV03",GEOGCS["CH1903",DATUM["CH1903",SPHEROID["Bessel... + +%prep +%autosetup -n pyepsg-0.4.0 + +%build +%py3_build + +%install +%py3_install +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-pyepsg -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Mon Apr 10 2023 Python_Bot <Python_Bot@openeuler.org> - 0.4.0-1 +- Package Spec generated |
