aboutsummaryrefslogtreecommitdiffstats
path: root/databases
diff options
context:
space:
mode:
authorpav <pav@FreeBSD.org>2010-12-02 22:55:36 +0800
committerpav <pav@FreeBSD.org>2010-12-02 22:55:36 +0800
commitf669b5d27d57b8503cde8daacf6a9c44b4843571 (patch)
tree48999d791826434e4770d8c3512ea3f0d2429665 /databases
parent506eb091ad165aa04da0874d5c1c2ce8df720037 (diff)
downloadfreebsd-ports-gnome-f669b5d27d57b8503cde8daacf6a9c44b4843571.tar.gz
freebsd-ports-gnome-f669b5d27d57b8503cde8daacf6a9c44b4843571.tar.zst
freebsd-ports-gnome-f669b5d27d57b8503cde8daacf6a9c44b4843571.zip
- txid bits are installed conditionally on postgresql version, fix plist
PR: ports/146913 Reported by: Alexey Markov <redrat@mail.ru> Approved by: feedback timeout on the PR
Diffstat (limited to 'databases')
-rw-r--r--databases/skytools/Makefile21
-rw-r--r--databases/skytools/pkg-plist10
2 files changed, 25 insertions, 6 deletions
diff --git a/databases/skytools/Makefile b/databases/skytools/Makefile
index c9cb854d98e3..7823f23f4cd0 100644
--- a/databases/skytools/Makefile
+++ b/databases/skytools/Makefile
@@ -29,7 +29,26 @@ CONFIGURE_ARGS= --with-python=${PYTHON_CMD} \
--docdir=${EXAMPLESDIR} \
--with-pgconfig=${LOCALBASE}/bin/pg_config
+.include <bsd.port.pre.mk>
+
+# Setting/finding PostgreSQL version we want.
+.if exists(${LOCALBASE}/bin/postmaster)
+PGSQL_VER!= ${LOCALBASE}/bin/postmaster -V | \
+ ${SED} -En 's/.*PostgreSQL[^0-9]*([0-9]+)\.([0-9]+)\..*/\1\2/p'
+.elif exists(${LOCALBASE}/bin/pg_config)
+PGSQL_VER!= ${LOCALBASE}/bin/pg_config --version | \
+ ${SED} -En 's/PostgreSQL[^0-9]*([0-9]*)\.([0-9]+)\..*/\1\2/p'
+.else
+PGSQL_VER= ${DEFAULT_PGSQL_VER}
+.endif
+
+.if ${PGSQL_VER} > 82
+PLIST_SUB+= TXID="@comment "
+.else
+PLIST_SUB+= TXID=""
+.endif
+
post-patch:
@${REINPLACE_CMD} -e 's=share/doc=share/examples=' ${WRKSRC}/setup.py
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
diff --git a/databases/skytools/pkg-plist b/databases/skytools/pkg-plist
index 4ac1066c0e77..776a3e9dc14c 100644
--- a/databases/skytools/pkg-plist
+++ b/databases/skytools/pkg-plist
@@ -81,11 +81,11 @@ bin/walmgr.py
lib/postgresql/logtriga.so
lib/postgresql/pgq_lowlevel.so
lib/postgresql/pgq_triggers.so
-lib/postgresql/txid.so
+%%TXID%%lib/postgresql/txid.so
share/doc/postgresql/contrib/README.londiste
share/doc/postgresql/contrib/README.pgq
share/doc/postgresql/contrib/README.pgq_ext
-share/doc/postgresql/contrib/README.txid
+%%TXID%%share/doc/postgresql/contrib/README.txid
share/postgresql/contrib/logtriga.sql
share/postgresql/contrib/londiste.sql
share/postgresql/contrib/londiste.upgrade.sql
@@ -95,8 +95,8 @@ share/postgresql/contrib/pgq_ext.sql
share/postgresql/contrib/pgq_lowlevel.sql
share/postgresql/contrib/pgq_triggers.sql
share/postgresql/contrib/uninstall_pgq.sql
-share/postgresql/contrib/uninstall_txid.sql
-share/postgresql/contrib/txid.sql
+%%TXID%%share/postgresql/contrib/uninstall_txid.sql
+%%TXID%%share/postgresql/contrib/txid.sql
@dirrmtry lib/postgresql
@dirrmtry share/doc/postgresql/contrib
@dirrmtry share/doc/postgresql
@@ -106,7 +106,7 @@ share/postgresql/contrib/txid.sql
%%DATADIR%%/londiste.sql
%%DATADIR%%/pgq.sql
%%DATADIR%%/pgq_ext.sql
-%%DATADIR%%/txid.sql
+%%TXID%%%%DATADIR%%/txid.sql
%%DATADIR%%/upgrade/final/v2.1.5_londiste.sql
%%DATADIR%%/upgrade/final/v2.1.5_pgq_core.sql
%%DATADIR%%/upgrade/final/v2.1.5_pgq_ext.sql