# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4 # $Id$ PortSystem 1.0 name postgis2 categories databases gis license GPL version 2.3.0 epoch 1 platforms darwin maintainers vince openmaintainer description PostGIS is the spatial extension to the\ PostGreSQL database. long_description PostGIS 2 adds geometrical, geographical and topological\ types, and functions operating thereon, to the PostGreSQL\ database. The 2.0 release also provides raster handling\ and basic 3D geometry capacities (TIN and polyhedra). homepage http://postgis.refractions.net/ master_sites http://download.osgeo.org/postgis/source distname postgis-${version} checksums rmd160 b93c77e9f1c8d999e2f548ba79553a8d1f09d824 \ sha256 0dbff06f4a196d49e5ac06ae6cc21bd5253aaa646af624c9bbf19df582d6cf55 depends_build port:autoconf \ port:automake \ port:libtool \ port:libxslt depends_lib port:geos\ port:proj\ port:libiconv\ port:libxml2 # PostGIS 2.0 is not compatible with PostGIS 1.5 conflicts postgis # Neither is PostGIS 2.0 compatible with PostGreSQL 8 variant postgresql95 description {Builds with postgresql 9.5} \ conflicts postgresql96 { depends_lib-append port:postgresql95 configure.args-append --libdir=${prefix}/lib/postgresql95\ --with-pgconfig=${prefix}/lib/postgresql95/bin/pg_config build.args-append PGSQL_DOCDIR=${destroot}${prefix}/share/doc/postgresql95\ PGSQL_MANDIR=${destroot}${prefix}/share/man } variant postgresql96 description {Builds with postgresql 9.6} \ conflicts postgresql95 { depends_lib-append port:postgresql96 configure.args-append --libdir=${prefix}/lib/postgresql96\ --with-pgconfig=${prefix}/lib/postgresql96/bin/pg_config build.args-append PGSQL_DOCDIR=${destroot}${prefix}/share/doc/postgresql96\ PGSQL_MANDIR=${destroot}${prefix}/share/man } variant raster description {Build raster support} { depends_lib-append port:gdal configure.args-append --with-raster } variant topology description {Build topology support} { configure.args-append --with-topology } variant sfcgal description {Uses SFCGAL for 3D queries} { depends_lib-append port:sfcgal configure.args-append --with-sfcgal=${prefix}/bin/sfcgal-config } variant gui description {Build the GUI import tool} { depends_lib-append port:gtk2 configure.args-append --with-gui } variant comments description {Build comments -- ! broken } { ui_warn "The comments variant is currently broken. Use at your own risk." depends_build-append port:docbook-xsl \ port:libxslt \ port:ImageMagick configure.args-append --datadir=${prefix}/share/${name} \ --with-projdir=${prefix} \ --with-xsldir=${prefix}/share/xsl/docbook-xsl build.target-append comments destroot.target-append docs-install comments-install } default_variants +raster +topology if {![variant_isset postgresql95] && ![variant_isset postgresql96]} { default_variants +postgresql95 } # Port phases configure.cflags-append \ -Diconv=libiconv -Diconv_open=libiconv_open -Diconv_close=libiconv_close # JSON-C new version is incompatible with this version of PostGIS configure.args-append -without-json post-configure { if {[variant_isset universal]} { # We must add universal flags to compile liblwgeom properly file copy ${filespath}/ed_command ${worksrcpath}/ed_command reinplace -E "s#XXX#${configure.universal_cflags}#" \ ${worksrcpath}/ed_command system -W ${worksrcpath}/liblwgeom \ "ed Makefile < ${worksrcpath}/ed_command" } } build.args ICONV_LDFLAGS='-L${prefix}/lib -liconv' use_parallel_build no livecheck.type regex livecheck.url ${master_sites} livecheck.regex {postgis2?-(\d+(?:\.\d+)*)\.[tz]}