source: trunk/dports/gis/mapserver/Portfile @ 114392

Last change on this file since 114392 was 111355, checked in by ryandesign@…, 7 years ago

remove use of [suffix] proc in openmaintainer ports because it is thought to be confusing

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 4.9 KB
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id: Portfile 111355 2013-09-19 07:29:32Z ryandesign@macports.org $
3
4PortSystem          1.0
5
6name                mapserver
7version             6.2.1
8revision            1
9maintainers         hbaspecto.com:jea openmaintainer
10categories          gis
11license             permissive
12platforms           darwin
13
14description         mapserver
15long_description    MapServer is an Open Source development environment for \
16                    building spatially-enabled internet applications.
17
18homepage            http://mapserver.org
19master_sites        http://download.osgeo.org/mapserver
20
21checksums           md5     8c48991dc54a307076b1fb670bc59ef9 \
22                    rmd160  4914dd5c5d400bc4f5d4cbdb40277b0b21967f24 \
23                    sha256  77087306246451df2cea3711e601f56ebf8a55f29ede4ca8e5f0433dfad743d5
24
25depends_lib         port:gd2 \
26                    port:jpeg \
27                    port:libpng \
28                    port:freetype \
29                    port:giflib \
30
31# fix gd version check
32patchfiles-append   patch-configure.diff
33
34configure.args      --with-gd=${prefix} \
35                    --with-png=${prefix} \
36                    --with-zlib=${prefix} \
37                    --with-jpeg=${prefix} \
38                    --with-gif=${prefix} \
39
40default_variants    +wms +gdal +ogr +proj +cairo +wfs +proj \
41                    +geos +postgis +wmsclient +wfsclient \
42                    +wcs +sos +kml +fastcgi
43
44if {[variant_isset postgis]} {
45    # check for most recent version of postgresql installed
46    set HAVE_PGCONFIG [llength [glob -nocomplain -d ${prefix}/lib postgresql*/bin/pg_config]]
47    # if not found, intall the postgresql port
48    if {$HAVE_PGCONFIG == 0} {
49        depends_lib-append  port:postgresql90
50    }
51}
52
53variant postgis description {Add support for postgis sources} {
54    set PGSQL_DIR [lindex [lsort -dec [glob -nocomplain -d ${prefix}/lib postgresql*]] 0]
55    configure.args-append   "--with-postgis=${PGSQL_DIR}/bin/pg_config"
56}
57
58variant wms description {Add WMS server support} {
59    default_variants-append +proj
60}
61
62variant wfs description {Add WFS server support} {
63    depends_lib-append      port:libxml2
64    default_variants-append +proj +ogr +geos
65    configure.args-append   --with-wfs
66}
67
68variant sos description {Add SOS server support} {
69    depends_lib-append      port:libxml2
70    default_variants-append +proj +ogr
71    configure.args-append   --with-sos
72}
73
74variant wcs description {Add WCS server support} {
75    default_variants-append +proj +gdal
76    configure.args-append   --with-wcs
77}
78
79variant wmsclient description {Add WMS client support} {
80    depends_lib-append      port:curl
81    default_variants-append +proj +gdal
82    configure.args-append   --with-wmsclient
83}
84
85variant kml description {Add KML output support} {
86    configure.args-append   --with-kml
87}
88
89variant wfsclient description {Add WFS client support} {
90    depends_lib-append      port:libxml2 \
91                            port:curl
92    default_variants-append +proj +ogr +geos
93    configure.args-append   --with-wfsclient
94}
95
96variant cairo description {Add SVG and PDF support through cairo} {
97    depends_lib-append      path:lib/pkgconfig/cairo.pc:cairo
98    configure.args-append   --with-cairo
99}
100
101variant gdal description {Add GDAL input format support} {
102    depends_lib-append      port:gdal
103    configure.args-append   --with-gdal
104}
105
106variant ogr description {Add OGR input format support} {
107    depends_lib-append      port:gdal
108    configure.args-append   --with-ogr
109}
110
111variant proj description {Proj.4 reprojection support} {
112    depends_lib-append      port:proj
113    configure.args-append   --with-proj=${prefix}
114}
115
116variant fastcgi description {FastCGI support} {
117    depends_lib-append      port:fcgi
118    configure.args-append   --with-fastcgi=${prefix}
119}
120
121variant geos description {Add GEOS operations support} {
122    depends_lib-append      port:geos
123    configure.args-append   --with-geos
124}
125
126variant apache conflicts apache2 apache_apple description {Use MacPorts Apache 1} {
127    depends_run-append      port:apache
128    global cgi_path
129    set cgi_path "${prefix}/www/cgi-bin/"
130}
131
132variant apache2 conflicts apache apache_apple description {Use MacPorts Apache 2} {
133    depends_run-append      port:apache2
134    global cgi_path
135    set cgi_path "${prefix}/apache2/cgi-bin/"
136}
137
138variant apache_apple conflicts apache apache2 description {Use Apple Apache} {
139    global cgi_path
140    set cgi_path "/Library/WebServer/CGI-Executables/"
141}
142
143if {![variant_isset apache] && ![variant_isset apache2] && ![variant_isset apache_apple]} {
144    # default to the apple apache version if none specified
145    default_variants +apache_apple
146}
147
148destroot.violate_mtree yes
149
150post-destroot {
151    file mkdir ${destroot}${cgi_path}
152    xinstall -m 755 ${worksrcpath}/mapserv ${destroot}${cgi_path}/mapserv
153}
154
155livecheck.type      regex
156livecheck.url       [lindex ${master_sites} 0]
157livecheck.regex     ${name}-(\[0-9.\]+)${extract.suffix}
Note: See TracBrowser for help on using the repository browser.