r111979 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r111978‎ | r111979 | r111980 >
Date:23:14, 20 February 2012
Author:wikinaut
Status:deferred
Tags:
Comment:
convenience version 1.001 for Extension:OpenID. Dropped the method of downloading and patching; instead I have setup a regular fork and new branch mw-extension-openid on Github https://github.com/Wikinaut/php-openid/tree/mw-extension-openid which includes the former patch for making the library PHP 5.3.x compatible. Everyone can now see what is actually downloaded, and can compare it (there are no changes except the former patch) with the previous php-openid-2.2.2 version. The former patch file has been deleted, a new sha1 checksum is calculated and compared.
Modified paths:
  • /trunk/extensions/OpenID/Makefile (modified) (history)
  • /trunk/extensions/OpenID/README.OpenID-mediawiki-extension (modified) (history)
  • /trunk/extensions/OpenID/patches/php-openid-2.2.2.patch (deleted) (history)
  • /trunk/extensions/OpenID/php-openid-2.2.2.tar.gz.sha1 (deleted) (history)
  • /trunk/extensions/OpenID/php-openid-mw-extension-openid.tar.gz.sha1 (added) (history)

Diff [purge]

Index: trunk/extensions/OpenID/php-openid-2.2.2.tar.gz.sha1
@@ -1 +0,0 @@
2 -009715779b32b42223292ecb5939112bc65334b7 php-openid-2.2.2.tar.gz
Index: trunk/extensions/OpenID/README.OpenID-mediawiki-extension
@@ -1,5 +1,5 @@
22 MediaWiki OpenID extension README.OpenID-mediawiki-extension file
3 -version 1.000 20120212
 3+version 1.001 20120220
44 Homepage and manual http://www.mediawiki.org/wiki/Extension:OpenID
55
66 Please check OpenID.setup.php for the current program version number
@@ -118,10 +118,8 @@
119119 cd $IP/extensions/OpenID
120120 make
121121
122 -The makefile downloads the openid-php library from http://www.openidenabled.com/php-openid/
123 -and applies a patch to avoid PHP errors because Call-time pass-by-reference is deprecated
124 -since PHP 5.3.x see https://github.com/openid/php-openid/issues#issue/8 and
125 -the patch and fork of user kost https://github.com/openid/php-openid/pull/44/files
 122+The makefile downloads the openid-php library from
 123+https://github.com/Wikinaut/php-openid/tree/mw-extension-openid .
126124
127125 Version 0.3 and below of this extension used a different database structure
128126 that was pretty inefficient. If you installed this extension before, you should
@@ -466,6 +464,8 @@
467465 into that account now
468466
469467 == CHANGES ==
 468+* 1.001 convenience release with download of the version for PHP 5.3.x
 469+ from https://github.com/Wikinaut/php-openid/tree/mw-extension-openid
470470 * 1.000 release version
471471 * 0.947 using jQuery closure for redirect
472472 * 0.946 fixed the problem of broken automatic redirect to OpenID provider login
Index: trunk/extensions/OpenID/patches/php-openid-2.2.2.patch
@@ -1,81 +0,0 @@
2 -diff -bru _Auth//OpenID/Consumer.php Auth//OpenID/Consumer.php
3 -+++ Auth//OpenID/Consumer.php 2011-02-03 12:17:42.000000000 +0100
4 -@@ -666,7 +666,7 @@
5 - '_completeInvalid');
6 -
7 - return call_user_func_array(array($this, $method),
8 -- array($message, &$endpoint, $return_to));
9 -+ array($message, $endpoint, $return_to));
10 - }
11 -
12 - /**
13 -@@ -1181,7 +1181,7 @@
14 - // oidutil.log('Performing discovery on %s' % (claimed_id,))
15 - list($unused, $services) = call_user_func($this->discoverMethod,
16 - $claimed_id,
17 -- &$this->fetcher);
18 -+ $this->fetcher);
19 -
20 - if (!$services) {
21 - return new Auth_OpenID_FailureResponse(null,
22 -diff -bru _Auth//OpenID/Server.php Auth//OpenID/Server.php
23 -+++ Auth//OpenID/Server.php 2011-02-03 12:18:56.000000000 +0100
24 -@@ -1704,7 +1704,7 @@
25 - {
26 - if (method_exists($this, "openid_" . $request->mode)) {
27 - $handler = array($this, "openid_" . $request->mode);
28 -- return call_user_func($handler, &$request);
29 -+ return call_user_func($handler, $request);
30 - }
31 - return null;
32 - }
33 -diff -bru _Auth//OpenID/TrustRoot.php Auth//OpenID/TrustRoot.php
34 -+++ Auth//OpenID/TrustRoot.php 2011-02-03 12:19:24.000000000 +0100
35 -@@ -413,7 +413,7 @@
36 - }
37 -
38 - call_user_func_array($discover_function,
39 -- array($relying_party_url, &$fetcher));
40 -+ array($relying_party_url, $fetcher));
41 -
42 - $return_to_urls = array();
43 - $matching_endpoints = Auth_OpenID_extractReturnURL($endpoints);
44 -diff -bru _Auth//Yadis/Manager.php Auth//Yadis/Manager.php
45 -+++ Auth//Yadis/Manager.php 2011-02-03 12:20:44.000000000 +0100
46 -@@ -413,7 +413,7 @@
47 -
48 - list($yadis_url, $services) = call_user_func($discover_cb,
49 - $this->url,
50 -- &$fetcher);
51 -+ $fetcher);
52 -
53 - $manager = $this->createManager($services, $yadis_url);
54 - }
55 -diff -bru _Auth//Yadis/XRDS.php Auth//Yadis/XRDS.php
56 -+++ Auth//Yadis/XRDS.php 2011-02-03 12:19:58.000000000 +0100
57 -@@ -429,7 +429,7 @@
58 -
59 - foreach ($filters as $filter) {
60 -
61 -- if (call_user_func_array($filter, array(&$service))) {
62 -+ if (call_user_func_array($filter, array($service))) {
63 - $matches++;
64 -
65 - if ($filter_mode == SERVICES_YADIS_MATCH_ANY) {
66 -diff -bru _Auth//Yadis/Yadis.php Auth//Yadis/Yadis.php
67 -+++ Auth//Yadis/Yadis.php 2011-02-03 12:20:26.000000000 +0100
68 -@@ -141,7 +141,7 @@
69 - }
70 -
71 - $yadis_result = call_user_func_array($discover_func,
72 -- array($input_url, &$fetcher));
73 -+ array($input_url, $fetcher));
74 -
75 - if ($yadis_result === null) {
76 - return array($input_url, array());
Index: trunk/extensions/OpenID/php-openid-mw-extension-openid.tar.gz.sha1
@@ -0,0 +1 @@
 2+54208aa1eb4828a63a20890de695b6431595af67 php-openid-mw-extension-openid.tar.gz
Index: trunk/extensions/OpenID/Makefile
@@ -1,9 +1,7 @@
2 -PHP_OPENID_VERSION=2.2.2
3 -SUBDIR=openid-php-openid-782224d
 2+PHP_OPENID_VERSION=mw-extension-openid
 3+SUBDIR=Wikinaut-php-openid-e46daed
44 SHELL = /bin/sh
55
6 -# how to make that one predictable easily?
7 -
86 # http://www.mediawiki.org/wiki/Extension:OpenID
97 #
108 # This makefile automates the installation of a prerequisite for the MediaWiki OpenID extension.
@@ -29,8 +27,9 @@
3028 # svn checkout svn+ssh://USERNAME@svn.wikimedia.org/svnroot/mediawiki/trunk/extensions/OpenID OpenID
3129 #
3230 # STEP 2
33 -# The makefile downloads the openid-php library from http://www.openidenabled.com/php-openid/
34 -# and applies a patch to avoid PHP errors because Call-time pass-by-reference is deprecated
 31+# The makefile downloads the php-openid library see http://www.openidenabled.com/php-openid/
 32+# from the fork version https://github.com/Wikinaut/php-openid/tree/mw-extension-openid
 33+# which contains a patch to avoid PHP errors because Call-time pass-by-reference is deprecated
3534 # since PHP 5.3.x see https://github.com/openid/php-openid/issues#issue/8 and
3635 # the patch and fork of user kost https://github.com/openid/php-openid/pull/44/files
3736 #
@@ -50,32 +49,17 @@
5150 # initially written by Brion Vibber
5251 # 20110203 T. Gries
5352 # 20111014 added a test whether "patch" (program) exists before starting it blindly
 53+# 20120220 removed the patch and checks
 54+# pointing to and downloading the already patched version
 55+# from https://github.com/Wikinaut/php-openid/tree/mw-extension-openid
5456
55 -install: check-if-patch-exists Auth
 57+install: Auth
5658
57 -# test if "patch" program is installed
58 -# some distributions don't have it installed by default
59 -#
60 -# as suggested in
61 -# http://stackoverflow.com/questions/592620/check-if-a-program-exists-from-a-bash-script
62 -# we use "hash" to test existence of "patch"
63 -
64 -check-if-patch-exists:
65 - @if $(SHELL) -c 'hash patch' >/dev/null 2>&1; then \
66 - # echo "... The 'patch' program exists." ; \
67 - true; \
68 - else \
69 - echo "... The 'patch' program does not exist on your system. Please install it before running make."; \
70 - false; \
71 - fi
72 -
7359 Auth: php-openid-$(PHP_OPENID_VERSION).tar.gz check-php-openid-sha1
7460 @echo "... Extracting php-openid-$(PHP_OPENID_VERSION).tar.gz:"
7561 tar -xzf php-openid-$(PHP_OPENID_VERSION).tar.gz $(SUBDIR)/Auth
7662 rm -f php-openid-$(PHP_OPENID_VERSION).tar.gz
7763 mv $(SUBDIR)/Auth ./
78 - @echo "... Patching php-openid-$(PHP_OPENID_VERSION) files in the Auth subdirectory:"
79 - patch -p1 -d Auth < patches/php-openid-$(PHP_OPENID_VERSION).patch
8064 rmdir $(SUBDIR)
8165 @echo -e "\n\
8266 ... Now almost everything is ready for making your MediaWiki OpenID-aware.\n\
@@ -85,7 +69,7 @@
8670
8771 php-openid-$(PHP_OPENID_VERSION).tar.gz:
8872 @echo "... Downloading the PHP library for OpenID:"
89 - wget --no-check-certificate https://github.com/openid/php-openid/tarball/$(PHP_OPENID_VERSION) -O php-openid-$(PHP_OPENID_VERSION).tar.gz
 73+ wget --no-check-certificate https://github.com/Wikinaut/php-openid/tarball/$(PHP_OPENID_VERSION) -O php-openid-$(PHP_OPENID_VERSION).tar.gz
9074
9175 check-php-openid-sha1:
9276 @if $(SHELL) -c "sha1sum -c php-openid-$(PHP_OPENID_VERSION).tar.gz.sha1" >/dev/null 2>&1; then \

Follow-up revisions

RevisionCommit summaryAuthorDate
r112842follow-up r111979 . Only updated a passage in README to reflect the changes o...wikinaut22:05, 1 March 2012

Status & tagging log