From 63601400e476c6cf43d985f3e7b9864681695ed4 Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Fri, 18 Jan 2013 16:46:04 +0100 Subject: Update to MediaWiki 1.20.2 this update includes: * adjusted Arch Linux skin * updated FluxBBAuthPlugin * patch for https://bugzilla.wikimedia.org/show_bug.cgi?id=44024 --- maintenance/dev/includes/php.sh | 22 ++++++++++++---------- maintenance/dev/includes/router.php | 26 ++++++++++++++++++++++---- 2 files changed, 34 insertions(+), 14 deletions(-) (limited to 'maintenance/dev') diff --git a/maintenance/dev/includes/php.sh b/maintenance/dev/includes/php.sh index 3021b93b..7ce87944 100644 --- a/maintenance/dev/includes/php.sh +++ b/maintenance/dev/includes/php.sh @@ -1,12 +1,14 @@ # Include-able script to determine the location of our php if any +# We search for a environment var called PHP, native php, +# a local copy, home directory location used by installphp.sh +# and previous home directory location +# The binary path is returned in $PHP if any -if [ -d "$DEV/php" -a -x "$DEV/php/bin/php" ]; then - # Quick local copy - PHP="$DEV/php/bin/php" -elif [ -d "$HOME/.mediawiki/php" -a -x "$HOME/.mediawiki/php/bin/php" ]; then - # Previous home directory location to install php in - PHP="$HOME/.mediawiki/php/bin/php" -elif [ -d "$HOME/.mwphp" -a -x "$HOME/.mwphp/bin/php" ]; then - # Previous home directory location to install php in - PHP="$HOME/.mwphp/bin/php" -fi +for binary in $PHP `which php || true` "$DEV/php/bin/php" "$HOME/.mediawiki/php/bin/php" "$HOME/.mwphp/bin/php" ]; do + if [ -x "$binary" ]; then + if "$binary" -r 'exit((int)!version_compare(PHP_VERSION, "5.4", ">="));'; then + PHP="$binary" + break + fi + fi +done diff --git a/maintenance/dev/includes/router.php b/maintenance/dev/includes/router.php index f6a062b6..ac96f459 100644 --- a/maintenance/dev/includes/router.php +++ b/maintenance/dev/includes/router.php @@ -1,7 +1,25 @@