diff --git a/postgis-3.4.0-en.pdf b/postgis-3.4.0-en.pdf new file mode 100644 index 0000000000000000000000000000000000000000..6d193f5e3c7b5df688a24a7d42527cca305cdfc2 Binary files /dev/null and b/postgis-3.4.0-en.pdf differ diff --git a/postgis-3.4.0.tar.gz b/postgis-3.4.0.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..b275fa2f293b7cb16dece750419f4abe5efdb4df Binary files /dev/null and b/postgis-3.4.0.tar.gz differ diff --git a/postgis.spec b/postgis.spec new file mode 100644 index 0000000000000000000000000000000000000000..f1cacd243371ec83230a68aadd46521f0c5ff758 --- /dev/null +++ b/postgis.spec @@ -0,0 +1,179 @@ +%define anolis_release 1 + +%global majorversion 3.4 +%global soversion 3 + +%global __provides_exclude_from %{_libdir}/pgsql + +Name: postgis +Version: 3.4.0 +Release: %{anolis_release}%{?dist} +Summary: Geographic Information Systems Extensions to PostgreSQL +License: GPL-2.0-or-later + +URL: https://www.postgis.net +Source0: https://download.osgeo.org/%{name}/source/%{name}-%{version}.tar.gz +Source2: https://download.osgeo.org/%{name}/docs/%{name}-%{version}-en.pdf + +BuildRequires: make +BuildRequires: autoconf +BuildRequires: automake +BuildRequires: byacc +BuildRequires: docbook-dtds +BuildRequires: flex +BuildRequires: gcc-c++ +BuildRequires: gdal-devel >= 1.10.0 +BuildRequires: geos-devel >= 3.7.1 +BuildRequires: gtk2-devel +BuildRequires: json-c-devel +BuildRequires: libtool +BuildRequires: libxml2-devel +BuildRequires: libxslt +BuildRequires: pcre2-devel +BuildRequires: perl-generators +BuildRequires: postgresql-server-devel +BuildRequires: proj-devel >= 5.2.0 +BuildRequires: protobuf-c-devel + +%description +PostGIS adds support for geographic objects to the PostgreSQL object-relational +database. In effect, PostGIS "spatially enables" the PostgreSQL server, +allowing it to be used as a backend spatial database for geographic information +systems (GIS), much like ESRI's SDE or Oracle's Spatial extension. PostGIS +follows the OpenGIS "Simple Features Specification for SQL" and has been +certified as compliant with the "Types and Functions" profile. + +%package docs +Summary: Extra documentation for PostGIS +Buildarch: noarch + +%description docs +The postgis-docs package includes PDF documentation of PostGIS. + + +%package utils +Summary: The utils for PostGIS +Requires: %{name} = %{version}-%{release} +Buildarch: noarch + +%description utils +The postgis-utils package provides the utilities for PostGIS. + +%package gui +Summary: The shp2pgsql-gui utility for PostGIS +Requires: %{name} = %{version}-%{release} + +%description gui +The gui package provides shp2pgsql-gui for PostGIS. + +%package client +Summary: The CLI clients for PostGIS +Requires: %{name} = %{version}-%{release} + +%description client +The client package provides shp2pgsql, raster2pgsql and pgsql2shp for PostGIS. + +%prep +%autosetup -p1 +cp %{SOURCE2} . + +%build +%configure --disable-rpath --enable-raster --with-pgconfig=%{_bindir}/pg_server_config \ + --with-sfcgal=no \ + --with-gui \ + +sed -i 's| -fstack-clash-protection | |' postgis/Makefile +sed -i 's| -fstack-clash-protection | |' raster/rt_pg/Makefile +sed -i 's| -fstack-clash-protection | |' topology/Makefile +sed -i 's| -fstack-clash-protection | |' extensions/address_standardizer/Makefile +%make_build + +%make_build -C utils + +%install +%make_install +%make_install -C utils +%make_install -C extensions + +rm -f %{buildroot}%{_datadir}/*.sql + +install -d %{buildroot}%{_datadir}/%{name} +install -m 755 utils/*.pl %{buildroot}%{_datadir}/%{name} + +%{generate_compatibility_deps} + +%files +%license COPYING +%dir %{abidir} +%{_libdir}/pgsql/%{name}-%{soversion}.so +%{abidir}/%{name}-%{soversion}.dump +%{_datadir}/pgsql/contrib/postgis-%{majorversion}/*.sql +%{_datadir}/pgsql/extension/address_standardizer*.sql +%{_datadir}/pgsql/extension/address_standardizer*.control +%{_datadir}/pgsql/extension/postgis-*.sql +%{_datadir}/pgsql/extension/postgis_raster*.sql +%{_datadir}/pgsql/extension/postgis_topology*.sql +%{_datadir}/pgsql/extension/postgis.control +%{_datadir}/pgsql/extension/postgis_raster.control +%{_datadir}/pgsql/extension/postgis_topology.control +%{_datadir}/pgsql/extension/postgis_tiger_geocoder*.sql +%{_datadir}/pgsql/extension/postgis_tiger_geocoder.control +%{_datadir}/postgis/create_unpackaged.pl +%{_datadir}/postgis/create_skip_signatures.pl +%{_datadir}/postgis/create_spatial_ref_sys_config_dump.pl +%{_datadir}/postgis/create_uninstall.pl +%{_datadir}/postgis/repo_revision.pl +%{_libdir}/pgsql/address_standardizer-%{soversion}.so +%{abidir}/address_standardizer-%{soversion}.dump +%{_libdir}/pgsql/postgis_raster-%{soversion}.so +%{abidir}/postgis_raster-%{soversion}.dump +%{_libdir}/pgsql/postgis_topology-%{soversion}.so +%{abidir}/postgis_topology-%{soversion}.dump + +%files client +%dir %{abidir} +%{_bindir}/postgis +%{abidir}/postgis-option.list +%{_bindir}/postgis_restore +%{_bindir}/pgsql2shp +%{_bindir}/raster2pgsql +%{_bindir}/shp2pgsql +%{abidir}/shp2pgsql-option.list +%{_bindir}/pgtopo_export +%{abidir}/pgtopo_export-option.list +%{_bindir}/pgtopo_import +%{_mandir}/man1/pgsql2shp.1* +%{_mandir}/man1/pgtopo_export.1* +%{_mandir}/man1/pgtopo_import.1* +%{_mandir}/man1/postgis.1* +%{_mandir}/man1/postgis_restore.1* +%{_mandir}/man1/shp2pgsql.1* + +%files gui +%{_bindir}/shp2pgsql-gui +%{abidir}/shp2pgsql-gui-option.list +%{_datadir}/applications/shp2pgsql-gui.desktop +%{_datadir}/icons/hicolor/*/apps/shp2pgsql-gui.png + +%files utils +%doc utils/README +%dir %{_datadir}/%{name}/ +%doc %{_datadir}/doc/pgsql/extension/README.address_standardizer +%{_datadir}/%{name}/test_estimation.pl +%{_datadir}/%{name}/profile_intersects.pl +%{_datadir}/%{name}/test_joinestimation.pl +%{_datadir}/%{name}/create_extension_unpackage.pl +%{_datadir}/%{name}/%{name}_restore.pl +%{_datadir}/%{name}/read_scripts_version.pl +%{_datadir}/%{name}/test_geography_estimation.pl +%{_datadir}/%{name}/test_geography_joinestimation.pl +%{_datadir}/%{name}/create_or_replace_to_create.pl +%{_datadir}/%{name}/create_upgrade.pl + +%files docs +%doc postgis*.pdf +%doc CREDITS NEWS TODO README.%{name} loader/README.* doc/%{name}.xml doc/ZMSgeoms.txt + +%changelog +* Mon Sep 18 2023 Funda Wang - 3.4.0-1 +- Import package