version 1.26, 2009/07/29 06:33:03 |
version 1.36, 2013/09/10 15:35:30 |
|
|
# PG_LIB_EXT |
# PG_LIB_EXT |
# PGSQL_TYPE |
# PGSQL_TYPE |
# PGPKGSRCDIR |
# PGPKGSRCDIR |
# |
|
|
|
.if !defined(PGVERSION_MK) |
.if !defined(PGVERSION_MK) |
PGVERSION_MK= defined |
PGVERSION_MK= defined |
Line 25 _SYS_VARS.pgsql= PG_LIB_EXT PGSQL_TYPE P |
|
Line 24 _SYS_VARS.pgsql= PG_LIB_EXT PGSQL_TYPE P |
|
|
|
.include "../../mk/bsd.prefs.mk" |
.include "../../mk/bsd.prefs.mk" |
|
|
PGSQL_VERSION_DEFAULT?= 82 |
PGSQL_VERSION_DEFAULT?= 91 |
PGSQL_VERSIONS_ACCEPTED?= 84 83 82 81 |
PGSQL_VERSIONS_ACCEPTED?= 93 92 91 90 84 |
|
|
# transform the list into individual variables |
# transform the list into individual variables |
.for pv in ${PGSQL_VERSIONS_ACCEPTED} |
.for pv in ${PGSQL_VERSIONS_ACCEPTED} |
|
|
|
|
# check what is installed |
# check what is installed |
.if ${OPSYS} == "Darwin" |
.if ${OPSYS} == "Darwin" |
.if exists(${LOCALBASE}/lib/libecpg.6.0.1.dylib) |
. if exists(${LOCALBASE}/lib/libecpg.6.5.dylib) |
|
_PGSQL_VERSION_93_INSTALLED= yes |
|
. endif |
|
. if exists(${LOCALBASE}/lib/libecpg.6.4.dylib) |
|
_PGSQL_VERSION_92_INSTALLED= yes |
|
. endif |
|
. if exists(${LOCALBASE}/lib/libecpg.6.3.dylib) |
|
_PGSQL_VERSION_91_INSTALLED= yes |
|
. endif |
|
. if exists(${LOCALBASE}/lib/libecpg.6.2.dylib) |
|
_PGSQL_VERSION_90_INSTALLED= yes |
|
. endif |
|
. if exists(${LOCALBASE}/lib/libecpg.6.1.dylib) |
_PGSQL_VERSION_84_INSTALLED= yes |
_PGSQL_VERSION_84_INSTALLED= yes |
.endif |
. endif |
.if exists(${LOCALBASE}/lib/libecpg.6.0.0.dylib) |
|
_PGSQL_VERSION_83_INSTALLED= yes |
|
.endif |
|
.if exists(${LOCALBASE}/lib/libecpg.5.0.2.dylib) |
|
_PGSQL_VERSION_82_INSTALLED= yes |
|
.endif |
|
.if exists(${LOCALBASE}/lib/libecpg.5.0.1.dylib) |
|
_PGSQL_VERSION_81_INSTALLED= yes |
|
.endif |
|
.if exists(${LOCALBASE}/lib/libecpg.5.0.dylib) |
|
_PGSQL_VERSION_80_INSTALLED= yes |
|
.endif |
|
.if exists(${LOCALBASE}/lib/libecpg.4.1.dylib) |
|
_PGSQL_VERSION_74_INSTALLED= yes |
|
.endif |
|
.if exists(${LOCALBASE}/lib/libecpg.3.dylib) |
|
_PGSQL_VERSION_73_INSTALLED=yes |
|
.endif |
|
.else |
.else |
.if exists(${LOCALBASE}/lib/libecpg.so.6.0.1) |
. if exists(${LOCALBASE}/lib/libecpg.so.6.5) |
|
_PGSQL_VERSION_93_INSTALLED= yes |
|
. endif |
|
. if exists(${LOCALBASE}/lib/libecpg.so.6.4) |
|
_PGSQL_VERSION_92_INSTALLED= yes |
|
. endif |
|
. if exists(${LOCALBASE}/lib/libecpg.so.6.3) |
|
_PGSQL_VERSION_91_INSTALLED= yes |
|
. endif |
|
. if exists(${LOCALBASE}/lib/libecpg.so.6.2) |
|
_PGSQL_VERSION_90_INSTALLED= yes |
|
. endif |
|
. if exists(${LOCALBASE}/lib/libecpg.so.6.1) |
_PGSQL_VERSION_84_INSTALLED= yes |
_PGSQL_VERSION_84_INSTALLED= yes |
.endif |
. endif |
.if exists(${LOCALBASE}/lib/libecpg.so.6.0.0) |
|
_PGSQL_VERSION_83_INSTALLED= yes |
|
.endif |
|
.if exists(${LOCALBASE}/lib/libecpg.so.5.0.2) |
|
_PGSQL_VERSION_82_INSTALLED= yes |
|
.endif |
|
.if exists(${LOCALBASE}/lib/libecpg.so.5.0.1) |
|
_PGSQL_VERSION_81_INSTALLED= yes |
|
.endif |
|
.if exists(${LOCALBASE}/lib/libecpg.so.5.0.0) |
|
_PGSQL_VERSION_80_INSTALLED= yes |
|
.endif |
|
.if exists(${LOCALBASE}/lib/libecpg.so.4.1) |
|
_PGSQL_VERSION_74_INSTALLED= yes |
|
.endif |
|
.if exists(${LOCALBASE}/lib/libecpg.so.3) |
|
_PGSQL_VERSION_73_INSTALLED=yes |
|
.endif |
|
.endif |
.endif |
|
|
# if a version is explicitely required, take it |
# if a version is explicitely required, take it |
Line 120 _PGSQL_VERSION= ${PGSQL_VERSION_DEFAULT} |
|
Line 107 _PGSQL_VERSION= ${PGSQL_VERSION_DEFAULT} |
|
_PGSQL_VERSION= ${_PGSQL_VERSION_FIRSTACCEPTED} |
_PGSQL_VERSION= ${_PGSQL_VERSION_FIRSTACCEPTED} |
.endif |
.endif |
|
|
# |
|
# set variables for the version we decided to use: |
# set variables for the version we decided to use: |
# |
.if ${_PGSQL_VERSION} == "93" |
.if ${_PGSQL_VERSION} == "84" |
PGSQL_TYPE= postgresql93-client |
|
PGPKGSRCDIR= ../../databases/postgresql93-client |
|
.elif ${_PGSQL_VERSION} == "92" |
|
PGSQL_TYPE= postgresql92-client |
|
PGPKGSRCDIR= ../../databases/postgresql92-client |
|
.elif ${_PGSQL_VERSION} == "91" |
|
PGSQL_TYPE= postgresql91-client |
|
PGPKGSRCDIR= ../../databases/postgresql91-client |
|
.elif ${_PGSQL_VERSION} == "90" |
|
PGSQL_TYPE= postgresql90-client |
|
PGPKGSRCDIR= ../../databases/postgresql90-client |
|
.elif ${_PGSQL_VERSION} == "84" |
PGSQL_TYPE= postgresql84-client |
PGSQL_TYPE= postgresql84-client |
PGPKGSRCDIR= ../../databases/postgresql84-client |
PGPKGSRCDIR= ../../databases/postgresql84-client |
.elif ${_PGSQL_VERSION} == "83" |
|
PGSQL_TYPE= postgresql83-client |
|
PGPKGSRCDIR= ../../databases/postgresql83-client |
|
.elif ${_PGSQL_VERSION} == "82" |
|
PGSQL_TYPE= postgresql82-client |
|
PGPKGSRCDIR= ../../databases/postgresql82-client |
|
.elif ${_PGSQL_VERSION} == "81" |
|
PGSQL_TYPE= postgresql81-client |
|
PGPKGSRCDIR= ../../databases/postgresql81-client |
|
.elif ${_PGSQL_VERSION} == "80" |
|
PGSQL_TYPE= postgresql80-client |
|
PGPKGSRCDIR= ../../databases/postgresql80-client |
|
.else |
.else |
# force an error |
# force an error |
PGSQL_TYPE= none |
PGSQL_TYPE= none |