Import of pkgsrc-2016Q3

This commit is contained in:
2016-10-14 07:49:11 +02:00
committed by Lionel Sambuc
parent 9d819b6d54
commit 1242aa1e36
35952 changed files with 949749 additions and 377083 deletions

View File

@@ -1,4 +1,4 @@
# $NetBSD: phpversion.mk,v 1.111 2015/09/06 12:27:43 taca Exp $
# $NetBSD: phpversion.mk,v 1.158 2016/09/17 08:36:50 taca Exp $
#
# This file selects a PHP version, based on the user's preferences and
# the installed packages. It does not add a dependency on the PHP
@@ -10,8 +10,8 @@
# The PHP version to choose when more than one is acceptable to
# the package.
#
# Possible: 54 55 56
# Default: 54
# Possible: 56 70 71
# Default: 56
#
# === Infrastructure variables ===
#
@@ -27,12 +27,18 @@
# PHP_VERSIONS_ACCEPTED
# The PHP versions that are accepted by the package.
#
# Possible: 54 55 56
# Default: 54
# Possible: 56 70 71
# Default: 56
#
# PHP_VERSIONS_INCOMPATIBLE
# The PHP versions that are not supported by the package.
#
# Possible: 56 70 71
# Default: (empty)
#
# PHP_CHECK_INSTALLED
# Check installed version of PHP. Should be used by lang/php54,
# lang/php55 and lang/php56 only.
# Check installed version of PHP. Should be used by lang/php56,
# lang/php70, or lang/php71 only.
#
# Possible: Yes No
# Default: Yes
@@ -42,7 +48,7 @@
# PKG_PHP_VERSION
# The selected PHP version.
#
# Possible: 54 55 56
# Possible: 56 70 71
# Default: ${PHP_VERSION_DEFAULT}
#
# PHP_BASE_VERS
@@ -51,7 +57,7 @@
# PKG_PHP_MAJOR_VERS
# The selected PHP's major version.
#
# Possible: 5
# Possible: 5 7
# Default: 5
#
# PKG_PHP
@@ -61,18 +67,18 @@
# The directory of the PHP implementation, relative to the
# package directory.
#
# Example: ../../lang/php54
# Example: ../../lang/php56
#
# PHP_PKG_PREFIX
# The prefix that is prepended to the package name.
#
# Example: php54, php55 php56
# Example: php56 php70 php71
#
# PHP_EXTENSION_DIR
# Relative path to ${PREFIX} for PHP's extensions. It is derived from
# initial release of major version.
#
# Example: lib/php/20090630
# Example: lib/php/20140828
#
# Keywords: php
#
@@ -81,14 +87,14 @@
PHPVERSION_MK= defined
# Define each PHP's version.
PHP54_VERSION= 5.4.45
PHP55_VERSION= 5.5.29
PHP56_VERSION= 5.6.13
PHP56_VERSION= 5.6.26
PHP70_VERSION= 7.0.11
PHP71_VERSION= 7.1.0RC2
# Define initial release of major version.
PHP54_RELDATE= 20120301
PHP55_RELDATE= 20130620
PHP56_RELDATE= 20140828
PHP70_RELDATE= 20151203
PHP71_RELDATE= 20160303
_VARGROUPS+= php
_USER_VARS.php= PHP_VERSION_DEFAULT
@@ -98,24 +104,29 @@ _SYS_VARS.php= PKG_PHP_VERSION PKG_PHP PHPPKGSRCDIR PHP_PKG_PREFIX \
.include "../../mk/bsd.prefs.mk"
PHP_VERSION_DEFAULT?= 54
PHP_VERSIONS_ACCEPTED?= 54 55 56
PHP_VERSION_DEFAULT?= 56
PHP_VERSIONS_ACCEPTED?= 56 70 71
.for pv in ${PHP_VERSIONS_ACCEPTED}
. if empty(PHP_VERSIONS_INCOMPATIBLE:M${pv})
_PHP_VERSIONS_ACCEPTED+= ${pv}
. endif
.endfor
# transform the list into individual variables
.for pv in ${PHP_VERSIONS_ACCEPTED}
.for pv in ${_PHP_VERSIONS_ACCEPTED}
_PHP_VERSION_${pv}_OK= yes
.endfor
# check what is installed
.if exists(${LOCALBASE}/lib/php/20140828)
.if exists(${LOCALBASE}/lib/php/${PHP71_RELDATE})
_PHP_VERSION_71_INSTALLED= yes
_PHP_INSTALLED= yes
.elif exists(${LOCALBASE}/lib/php/${PHP70_RELDATE})
_PHP_VERSION_70_INSTALLED= yes
_PHP_INSTALLED= yes
.elif exists(${LOCALBASE}/lib/php/${PHP56_RELDATE})
_PHP_VERSION_56_INSTALLED= yes
_PHP_INSTALLED= yes
.elif exists(${LOCALBASE}/lib/php/20130620)
_PHP_VERSION_55_INSTALLED= yes
_PHP_INSTALLED= yes
.elif exists(${LOCALBASE}/lib/php/20120301)
_PHP_VERSION_54_INSTALLED= yes
_PHP_INSTALLED= yes
.endif
# if a version is explicitely required, take it
@@ -132,7 +143,7 @@ _PHP_VERSION= ${PHP_VERSION_DEFAULT}
.endif
# prefer an already installed version, in order of "accepted"
.if !defined(_PHP_VERSION)
.for pv in ${PHP_VERSIONS_ACCEPTED}
.for pv in ${_PHP_VERSIONS_ACCEPTED}
.if defined(_PHP_VERSION_${pv}_INSTALLED)
_PHP_VERSION?= ${pv}
.else
@@ -160,8 +171,8 @@ MULTI+= PHP_VERSION_REQD=${_PHP_VERSION}
PKG_PHP_VERSION:= ${_PHP_VERSION:C/\.[0-9]//}
PKG_PHP:= PHP${_PHP_VERSION:C/([0-9])([0-9])/\1.\2/}
# currently we have only PHP 5.x packages.
PKG_PHP_MAJOR_VERS:= 5
# Major version
PKG_PHP_MAJOR_VERS:= ${_PHP_VERSION:C/^([0-9]).*/\1/}
PHP_CHECK_INSTALLED?= Yes
@@ -184,24 +195,24 @@ PHP_VERSION_REQD:= ${PKG_PHP_VERSION}
#
# set variables for the version we decided to use:
#
.if ${_PHP_VERSION} == "54"
PHPPKGSRCDIR= ../../lang/php54
PHP_VERSION= ${PHP54_VERSION}
PHP_INITIAL_TEENY= 4
PHP_PKG_PREFIX= php54
PHP_EXTENSION_DIR= lib/php/${PHP54_RELDATE}
.elif ${_PHP_VERSION} == "55"
PHPPKGSRCDIR= ../../lang/php55
PHP_VERSION= ${PHP55_VERSION}
PHP_INITIAL_TEENY= 1
PHP_PKG_PREFIX= php55
PHP_EXTENSION_DIR= lib/php/${PHP55_RELDATE}
.elif ${_PHP_VERSION} == "56"
.if ${_PHP_VERSION} == "56"
PHPPKGSRCDIR= ../../lang/php56
PHP_VERSION= ${PHP56_VERSION}
PHP_INITIAL_TEENY= 3
PHP_PKG_PREFIX= php56
PHP_EXTENSION_DIR= lib/php/${PHP56_RELDATE}
.elif ${_PHP_VERSION} == "70"
PHPPKGSRCDIR= ../../lang/php70
PHP_VERSION= ${PHP70_VERSION}
PHP_INITIAL_TEENY= 0
PHP_PKG_PREFIX= php70
PHP_EXTENSION_DIR= lib/php/${PHP70_RELDATE}
.elif ${_PHP_VERSION} == "71"
PHPPKGSRCDIR= ../../lang/php71
PHP_VERSION= ${PHP71_VERSION}
PHP_INITIAL_TEENY= 0
PHP_PKG_PREFIX= php71
PHP_EXTENSION_DIR= lib/php/${PHP71_RELDATE}
.else
# force an error
PKG_FAIL_REASON+= "${PKG_PHP} is not a valid package"