Lines 6-19
Link Here
|
6 |
# |
6 |
# |
7 |
|
7 |
|
8 |
PORTNAME= postgis |
8 |
PORTNAME= postgis |
9 |
DISTVERSION= 1.3.6 |
9 |
DISTVERSION= 1.4.0 |
10 |
PORTREVISION= 1 |
|
|
11 |
CATEGORIES= databases geography |
10 |
CATEGORIES= databases geography |
12 |
MASTER_SITES= http://postgis.refractions.net/download/ |
11 |
MASTER_SITES= http://postgis.refractions.net/download/ \ |
|
|
12 |
http://www.postgis.org/download/ |
13 |
|
13 |
|
14 |
MAINTAINER= anderson@cnpm.embrapa.br |
14 |
MAINTAINER= anderson@cnpm.embrapa.br |
15 |
COMMENT= Adds support for geographic objects to PostgreSQL databases |
15 |
COMMENT= Adds support for geographic objects to PostgreSQL databases |
16 |
|
16 |
|
|
|
17 |
BUILD_DEPENDS= ${LOCALBASE}/bin/geos-config:${PORTSDIR}/graphics/geos |
17 |
LIB_DEPENDS= proj.5:${PORTSDIR}/graphics/proj |
18 |
LIB_DEPENDS= proj.5:${PORTSDIR}/graphics/proj |
18 |
RUN_DEPENDS= postmaster:${PORTSDIR}/databases/postgresql${PGSQL_VER}-server |
19 |
RUN_DEPENDS= postmaster:${PORTSDIR}/databases/postgresql${PGSQL_VER}-server |
19 |
|
20 |
|
Lines 25-76
Link Here
|
25 |
|
26 |
|
26 |
INSTALL_TARGET= install |
27 |
INSTALL_TARGET= install |
27 |
|
28 |
|
28 |
OPTIONS= GEOS "Include GEOS - the OpenGIS 'Simple Features for SQL'" off \ |
|
|
29 |
UTF8 "UTF-8 support for shp2pgsql. (needs libiconv)" off |
30 |
|
31 |
GNU_CONFIGURE= yes |
29 |
GNU_CONFIGURE= yes |
32 |
CONFIGURE_ARGS= --datadir=${PREFIX}/share/postgis \ |
30 |
CFLAGS+= -I${LOCALBASE}/include |
33 |
--bindir=${PREFIX}/bin \ |
31 |
LDFLAGS+= -L${LOCALBASE}/lib |
34 |
--libdir=${PREFIX}/lib \ |
32 |
MAKE_ENV= DATADIR=${DATADIR} DOCSDIR=${DOCSDIR} |
35 |
--with-proj |
33 |
CONFIGURE_ARGS= --with-projdir=${LOCALBASE} |
36 |
|
34 |
|
37 |
.include <bsd.port.pre.mk> |
35 |
.include <bsd.port.pre.mk> |
38 |
|
36 |
|
39 |
.if !defined(NOPORTDOCS) |
37 |
.if !defined(NOPORTDOCS) |
40 |
BUILD_DEPENDS+= xsltproc:${PORTSDIR}/textproc/libxslt \ |
38 |
BUILD_DEPENDS+= xsltproc:${PORTSDIR}/textproc/libxslt \ |
41 |
${LOCALBASE}/share/xsl/docbook/html/chunk.xsl:${PORTSDIR}/textproc/docbook-xsl |
39 |
${LOCALBASE}/share/xsl/docbook/html/chunk.xsl:${PORTSDIR}/textproc/docbook-xsl |
42 |
MAKE_ARGS+= WITH-DOC=yes |
40 |
CONFIGURE_ARGS+= --with-xsldir=${LOCALBASE}/share/xsl/docbook |
43 |
MAN1= pgsql2shp.1 shp2pgsql.1 |
41 |
MAN1= pgsql2shp.1 shp2pgsql.1 |
44 |
PORTDOCS= * |
42 |
PORTDOCS= * |
45 |
.else |
43 |
#.else |
46 |
MAKE_ARGS+= NOPORTSDOC=yes |
44 |
#MAKE_ARGS+= NOPORTDOCS=yes |
47 |
.endif |
|
|
48 |
|
49 |
.if defined(WITH_UTF8) |
50 |
USE_ICONV= yes |
51 |
MAKE_ENV+= "LDFLAGS=-L${LOCALBASE}/lib" |
52 |
.else |
53 |
CONFIGURE_ARGS+= --without-iconv |
54 |
.endif |
55 |
|
56 |
.if defined(WITH_GEOS) |
57 |
LIB_DEPENDS+= geos:${PORTSDIR}/graphics/geos |
58 |
CONFIGURE_ARGS+= --with-geos=${LOCALBASE}/bin/geos-config |
59 |
.else |
60 |
CONFIGURE_ARGS+= --without-geos |
61 |
.endif |
45 |
.endif |
62 |
|
46 |
|
63 |
pre-everything:: |
47 |
post-extract: |
64 |
@${SH} ${PKGINSTALL} ${PORTNAME} MESSAGE |
48 |
@${REINPLACE_CMD} -e 's#@ICONV_LDFLAGS@#-liconv -L${LOCALBASE}/lib#g' \ |
|
|
49 |
${WRKSRC}/loader/Makefile.in |
50 |
|
51 |
post-patch: |
52 |
@${REINPLACE_CMD} -e 's#%PERL%#${PERL}#g' \ |
53 |
${WRKSRC}/postgis/Makefile.in |
65 |
|
54 |
|
66 |
post-install: |
55 |
post-install: |
|
|
56 |
@${MKDIR} ${DATADIR}/utils |
57 |
${INSTALL_SCRIPT} ${WRKSRC}/utils/create_undef.pl ${DATADIR}/utils/ |
58 |
${INSTALL_SCRIPT} ${WRKSRC}/utils/new_postgis_restore.pl ${DATADIR}/utils/ |
59 |
${INSTALL_SCRIPT} ${WRKSRC}/utils/profile_intersects.pl ${DATADIR}/utils/ |
60 |
${INSTALL_SCRIPT} ${WRKSRC}/utils/postgis_proc_upgrade.pl ${DATADIR}/utils/ |
61 |
${INSTALL_SCRIPT} ${WRKSRC}/utils/test_estimation.pl ${DATADIR}/utils/ |
62 |
${INSTALL_SCRIPT} ${WRKSRC}/utils/postgis_restore.pl ${DATADIR}/utils/ |
63 |
${INSTALL_SCRIPT} ${WRKSRC}/utils/test_joinestimation.pl ${DATADIR}/utils/ |
67 |
@${MKDIR} ${PREFIX}/lib/postgresql |
64 |
@${MKDIR} ${PREFIX}/lib/postgresql |
68 |
@${LN} -s ${PREFIX}/lib/liblwgeom.so.1 ${PREFIX}/lib/postgresql |
65 |
@${LN} -s ${PREFIX}/lib/postgresql/postgis-1.4.so ${PREFIX}/lib/postgresql/postgis.so |
69 |
@${SETENV} PKG_PREFIX=${PREFIX} \ |
66 |
@${LN} -s ${PREFIX}/lib/postgresql/postgis-1.4.so ${PREFIX}/lib/postgresql/liblwgeom.so.1 |
70 |
${SH} ${PKGINSTALL} ${PORTNAME} POST-INSTALL |
67 |
@${LN} -s ${PREFIX}/lib/postgresql/postgis-1.4.so ${PREFIX}/lib/postgresql/liblwgeom.so |
71 |
|
|
|
72 |
post-deinstall: |
73 |
@ ${SETENV} PKG_PREFIX=${PREFIX} \ |
74 |
${SH} ${PKGDEINSTALL} ${PORTNAME} POST-DEINSTALL |
75 |
|
68 |
|
76 |
.include <bsd.port.post.mk> |
69 |
.include <bsd.port.post.mk> |