Skip to content

Commit a67c615

Browse files
committed
Merge branch 'PHP-5.5' of git.php.net:php-src into PHP-5.5
* 'PHP-5.5' of git.php.net:php-src: Fix tests expecting specific resource IDs fixed parameter order for zend_throw_exception_ex call Fix doc (svn -> git) Updated release process
2 parents e6dbf0e + 7cf6f01 commit a67c615

File tree

17 files changed

+140
-122
lines changed

17 files changed

+140
-122
lines changed

CODING_STANDARDS

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,8 @@ Exceptions:
5959
you're calling.
6060

6161
7. When commenting out code using a #if statement, do NOT use 0 only. Instead
62-
use "<svn username here>_0". For example, #if FOO_0, where FOO is your
63-
svn user foo. This allows easier tracking of why code was commented out,
62+
use "<git username here>_0". For example, #if FOO_0, where FOO is your
63+
git user foo. This allows easier tracking of why code was commented out,
6464
especially in bundled libraries.
6565

6666
8. Do not define functions that are not available. For instance, if a

README.RELEASE_PROCESS

Lines changed: 78 additions & 75 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,16 @@ General notes and tips
88
1. Do not release on Fridays, Saturdays or Sundays
99
because the sysadmins can not upgrade stuff then.
1010

11-
2. Package the day before a release. So if the release is to be on Thursday,
12-
package on Wednesday.
11+
2. Package two days before a release. So if the release is to be on Thursday,
12+
package on Tuesday. Think about timezones as well.
1313

1414
3. Ensure that Windows builds will work before packaging
1515

16-
4. Follow all steps to the letter. When unclear ask previous RM's (Derick/Ilia)
17-
before proceeding. Ideally make sure that for the first releases one of the
18-
previous RM's is around to answer questions. For the steps related to the
19-
php/QA/bug websites try to have someone from the webmaster team (Bjori) on hand.
16+
4. Follow all steps to the letter. When unclear ask previous RM's (David/Julien/
17+
Johannes/Stas/Derick/Ilia) before proceeding. Ideally make sure that for the
18+
first releases one of the previous RM's is around to answer questions. For the
19+
steps related to the php/QA/bug websites try to have someone from the webmaster
20+
team (Bjori) on hand.
2021

2122
5. Verify the tags to be extra sure everything was tagged properly.
2223

@@ -50,37 +51,47 @@ Rolling a non stable release (alpha/beta/RC)
5051
2. run the "scripts/dev/credits" script in php-src and commit the changes in the
5152
credits files in ext/standard.
5253

53-
3. Checkout the release branch for this release (e.g., PHP-5.4.2).
54+
3. Checkout the release branch for this release (e.g., PHP-5.4.2) from the main branch.
5455

5556
4. Bump the version numbers in ``main/php_version.h``, ``configure.in`` and possibly ``NEWS``.
56-
Do not use abbreviations for alpha and beta.
57+
Do not use abbreviations for alpha and beta. Do not use dashes, you should
58+
``#define PHP_VERSION "5.4.22RC1"`` and not ``#define PHP_VERSION "5.4.22-RC1"``
5759

58-
5. Commit these changes to the branch with ``git commit -a``.
60+
5. Compile and make test, with and without ZTS, using the right Bison version
61+
(for example, for 5.5, Bison 2.4.1 is used)
5962

60-
6. Tag the repository with the version, e.g.:
63+
6. Check ./sapi/cli/php -v output for version matching.
64+
65+
7. If all is right, commit the changes to the release branch with ``git commit -a``.
66+
67+
8. Tag the repository release branch with the version, e.g.:
6168
``git tag -u YOURKEYID php-5.4.2RC2``
6269

63-
7. Push the changes to the main repo:
70+
9. Bump the version numbers in ``main/php_version.h``, ``configure.in`` and ``NEWS``
71+
in the *main* branch (PHP-5.4 for example) to prepare for the **next** version.
72+
F.e. if the RC is "5.4.1RC1" then the new one should be "5.4.2-dev" - regardless if we get
73+
a new RC or not. This is to make sure ``version_compare()`` can correctly work.
74+
Commit the changes to the main branch.
75+
76+
10. Push the changes to the main repo, the tag, the main branch and the release branch :
6477
``git push --tags origin HEAD``
78+
``git push origin {main branch}``
79+
``git push origin {release branch}``
6580

66-
8. run: ``./makedist 5.4.2RC2``, this will export the tree, create configure
67-
and build three tarballs (gz,bz2 and xz). Make sure you use the same GNU Bison
68-
version as snaps. Recent bison version are known to break ZTS.
81+
11. run: ``PHPROOT=. ./makedist 5.4.2RC2``, this will export the tree, create configure
82+
and build three tarballs (gz, bz2 and xz).
6983

70-
9. Copy those three tarballs to www.php.net, in your homedir there should be a
84+
12. Copy those tarballs (scp, rsync) to downloads.php.net, in your homedir there should be a
7185
directory "downloads/". Copy them into there, so that the system can generate
72-
MD5 sums. If you do not have this directory, talk to Derick.
86+
MD5 sums. If you do not have this directory, talk to Derick or Dan.
7387

74-
10. Now the RC can be found on http://downloads.php.net/yourname,
88+
13. Now the RC can be found on http://downloads.php.net/yourname,
7589
f.e. http://downloads.php.net/derick/
7690

77-
11. Once the release has been tagged, contact the PHP Windows development team
91+
14. Once the release has been tagged, contact the PHP Windows development team
7892
(internals-win@lists.php.net) so that Windows binaries can be created. Once
7993
those are made, they should be placed into the same directory as the source snapshots.
8094

81-
12. Notify the documentation team if documentations for new features are
82-
not yet available but a stable release is imminent.
83-
8495
Getting the non stable release (alpha/beta/RC) announced
8596
--------------------------------------------------------
8697

@@ -109,9 +120,9 @@ Derick) run the following commands for you:
109120

110121
Note: Remember to update the MD5 checksum information.
111122

112-
4. Update ``php.git/include/version.inc`` (x=major version number)
123+
4. Update ``web/php.git/include/version.inc`` (x=major version number)
113124

114-
a. ``$PHP_x_RC`` = "5.4.0RC1"
125+
a. ``$PHP_x_RC`` = "5.4.0RC1" (should be set to "false" before)
115126

116127
b. ``$PHP_x_RC_DATE`` = "06 September 2007"
117128

@@ -122,70 +133,61 @@ Derick) run the following commands for you:
122133
6. For the first RC, write the doc team (phpdoc@lists.php.net) about updating the
123134
INSTALL and win32/install.txt files which are generated from the PHP manual sources.
124135

125-
7. Publish the announce on www.php.net as well (for all releases, alpha, RCs or other)
126-
127136
Rolling a stable release
128137
------------------------
129138

130-
1. Check windows snapshot builder logs (http://snaps.php.net/win32/snapshot-STABLE.log f.e.)
131-
132-
2. Bump the version numbers in ``main/php_version.h``, ``configure.in`` and possibly ``NEWS``.
139+
1. Checkout your release branch, you should have created when releasing previous RC
140+
and bump the version numbers in ``main/php_version.h``, ``configure.in`` and possibly ``NEWS``.
133141

134-
3. **Merge** all related sections in NEWS (f.e. merge the 5.4.1RC1 and 5.4.0 sections)
142+
2. If a CVE commit needs to be merged to the release, then have it commited to
143+
the base branches and merged upwards as usual (f.e commit the CVE fix to 5.3,
144+
merge to 5.4, 5.5 etc...). Then you can cherry-pick it in your release branch.
145+
Don't forget to update NEWS manually in an extra commit then.
135146

136-
4. Commit those changes
147+
3. Commit those changes
137148

138-
5. run the "scripts/dev/credits" script in php-src and commit the changes in the
149+
4. run the "scripts/dev/credits" script in php-src and commit the changes in the
139150
credits files in ext/standard.
140151

141-
6. tag the repository with the version f.e. "``git tag -s php-5.4.1``"
142-
(of course, you need to change that to the version you're rolling an RC for).
143-
When making 5.X release, you need to tag the Zend directory separately!!
152+
5. Compile and make test, with and without ZTS, using the right Bison version
153+
(for example, for 5.5, Bison 2.4.1 is used)
144154

145-
7. Bump up the version numbers in ``main/php_version.h``, ``configure.in`` and
146-
possibly ``NEWS`` again, to the **next** version. F.e. if the release candidate
147-
was "5.4.1RC1" then the new one should be "5.4.1RC2-dev" - regardless if we get
148-
a new RC or not. This is to make sure ``version_compare()`` can correctly work.
155+
6. Check ./sapi/cli/php -v output for version matching.
149156

150-
8. Commit those changes
157+
7. tag the repository with the version f.e. "``git tag -s php-5.4.1``"
151158

152-
9. Log in onto the snaps box and go into the correct tree (f.e. the PHP-5.4
153-
branch if you're rolling 5.5.x releases).
159+
8. Push the tag f.e. "``git push origin php-5.4.1``"
154160

155-
10. You do not have to update the tree, but of course you can with "``git pull
156-
origin <branch>``".
161+
9. run: ``PHPROOT=. ./makedist php 5.4.1``, this will export the tag, create configure
162+
and build three tarballs (gz, bz2 and xz).
163+
Check if the pear files are updated (phar).
157164

158-
11. run: ``./makedist php 5.4.1``, this will export the tree, create configure
159-
and build two tarballs (one gz and one bz2).
165+
10. Generate the GPG signature files for the archives.
166+
``gpg -u YOUREMAIL --armor --detach-sign php-X.Y.Z.tar.xxx``
160167

161-
12. Commit those two tarballs to web/php-distributions.git, then update the git
162-
submodule reference in web/php.git:
163-
git submodule init;
168+
11. Commit and push all the tarballs and signature files to web/php-distributions.git,
169+
then update the git submodule reference in web/php.git:
170+
``git submodule init;
164171
git submodule update;
165172
cd distributions;
166173
git pull origin master;
167174
cd ..;
168175
git commit distributions;
169-
git push;
170-
171-
13. Once the release has been tagged, contact the PHP Windows development team
172-
(internals-win@lists.php.net) so that Windows binaries can be created. Once
173-
those are made, they should be committed to SVN too.
176+
git push;``
177+
This is to fetch the last commit id from php-distributions.git and commit this
178+
last commit id to web/php.git, then, mirrors will now sync
174179

175-
14. Check if the pear files are updated (phar for 5.1+ or run pear/make-pear-bundle.php with 4.4)
176-
177-
15. When making a final release, also remind the PHP Windows development team
178-
(internals-win@lists.php.net) to prepare the installer packages for Win32.
179-
180-
16. Make sure proper documentation exists for all new features/changes.
181-
Coordinate the release with the PHP Documentation team.
180+
12. Once the release has been tagged, contact the PHP Windows development team
181+
(internals-win@lists.php.net) so that Windows binaries can be created.
182182

183183
Getting the stable release announced
184184
------------------------------------
185185

186186
1. Run the bumpRelease script for phpweb on your local checkout
187187

188-
a. ``php bin/bumpRelease 5`` (or ``php bin/bumpRelease 4`` for PHP4)
188+
a. ``php bin/bumpRelease 5`` to create the release file (releases/x_y_z.php)
189+
The release announcement file should list in detail security fixes and
190+
changes in behavior (whether due to a bug fix or not).
189191

190192
b. In case multiple PHP minor versions are in active development you have
191193
to manually copy the old information to include/releases.inc
@@ -205,7 +207,13 @@ Getting the stable release announced
205207

206208
f. if the windows builds aren't ready yet prefix the "windows" key with a dot (".windows")
207209

208-
3. Update the ChangeLog file for the given major version
210+
3. Update phpweb/include/releases.php with the old release info
211+
(updates the download archives)
212+
213+
4. Update php-qa/include/release-qa.php and add the next version as an QARELEASE
214+
(prepare for next RC)
215+
216+
5. Update the ChangeLog file for the given major version
209217
f.e. ``ChangeLog-5.php`` from the NEWS file
210218

211219
a. go over the list and put every element on one line
@@ -225,27 +233,22 @@ f.e. ``ChangeLog-5.php`` from the NEWS file
225233
IV. ``s/Fixed PECL bug #\([0-9]\+\)/<?php peclbugfix(\1); ?>/``
226234

227235
V. ``s/FR #\([0-9]\+\)/FR <?php bugl(\1); ?>/``
236+
237+
e. You may want to try php-web/bin/news2html to automate this task
228238

229-
4. ``cp releases/5_4_0.php releases/5_4_1.php``
230-
231-
5. ``git add releases/5_4_1.php``
232-
233-
6. Update the ``releases/*.php`` file with relevant data. The release
234-
announcement file should list in detail:
235-
236-
a. security fixes,
237-
238-
b. changes in behavior (whether due to a bug fix or not)
239-
240-
7. Add a short notice to phpweb stating that there is a new release, and
239+
6. Add a short notice to phpweb stating that there is a new release, and
241240
highlight the major important things (security fixes) and when it is important
242241
to upgrade.
243242

244243
a. Call php bin/createNewsEntry in your local phpweb checkout
245244

246245
b. Add the content for the news entry
247246

248-
8. Commit all the changes.
247+
7. **Check mirrors have been synced before announcing or pushing news**
248+
Try, f.e. http://www.php.net/get/php-5.5.1.tar.bz2/from/a/mirror
249+
Try several mirrors, mirrors may update slowly (may take an hour)
250+
251+
8. Commit all the changes to their respective git repos
249252

250253
9. Wait an hour or two, then send a mail to php-announce@lists.php.net,
251254
php-general@lists.php.net and internals@lists.php.net with a text similar to

Zend/tests/bug41421.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,6 @@ Warning: feof(): wrapper::stream_eof is not implemented! Assuming EOF in %s on l
2424
Fatal error: Uncaught exception 'Exception' in %s:%d
2525
Stack trace:
2626
#0 [internal function]: wrapper->stream_eof()
27-
#1 %s(%d): feof(Resource id #6)
27+
#1 %s(%d): feof(Resource id #%d)
2828
#2 {main}
2929
thrown in %s on line %d

ext/session/tests/session_name_error.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,6 @@ string(12) "Hello World!"
231231
-- Iteration 24 --
232232

233233
Warning: session_name() expects parameter 1 to be string, resource given in %s on line %d
234-
resource(5) of type (stream)
234+
resource(%d) of type (stream)
235235
NULL
236236
Done

ext/snmp/snmp.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -533,7 +533,7 @@ static void php_snmp_error(zval *object, const char *docref TSRMLS_DC, int type,
533533
}
534534

535535
if (object && (snmp_object->exceptions_enabled & type)) {
536-
zend_throw_exception_ex(php_snmp_exception_ce, type, snmp_object->snmp_errstr TSRMLS_CC);
536+
zend_throw_exception_ex(php_snmp_exception_ce, type TSRMLS_CC, snmp_object->snmp_errstr);
537537
} else {
538538
va_start(args, format);
539539
php_verror(docref, "", E_WARNING, format, args TSRMLS_CC);

ext/standard/tests/array/each.phpt

4 Bytes
Binary file not shown.

ext/standard/tests/file/007_error.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ bool(false)
7676
Warning: fopen() expects at least 2 parameters, 0 given in %s on line %d
7777
bool(false)
7878

79-
Warning: fclose(): 5 is not a valid stream resource in %s on line %d
79+
Warning: fclose(): %d is not a valid stream resource in %s on line %d
8080
bool(false)
8181

8282
Warning: fclose() expects parameter 1 to be resource, string given in %s on line %d
@@ -85,7 +85,7 @@ bool(false)
8585
Warning: fclose() expects exactly 1 parameter, 0 given in %s on line %d
8686
bool(false)
8787

88-
Warning: feof(): 5 is not a valid stream resource in %s on line %d
88+
Warning: feof(): %d is not a valid stream resource in %s on line %d
8989
bool(false)
9090

9191
Warning: feof() expects parameter 1 to be resource, string given in %s on line %d

ext/standard/tests/file/fgetss_error.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ bool(false)
9898
Warning: fgetss() expects parameter 1 to be resource, object given in %s on line %d
9999
bool(false)
100100
-- Testing fgetss() with closed/unset file handle --
101-
Warning: fgetss(): 5 is not a valid stream resource in %s on line %d
101+
Warning: fgetss(): %d is not a valid stream resource in %s on line %d
102102
bool(false)
103103

104104
Warning: fgetss() expects parameter 1 to be resource, null given in %s on line %d

ext/standard/tests/file/ftruncate_error.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ Warning: ftruncate() expects parameter 1 to be resource, object given in %s on l
114114
bool(false)
115115
-- Testing ftruncate() with closed/unset file handle --
116116

117-
Warning: ftruncate(): 5 is not a valid stream resource in %s on line %d
117+
Warning: ftruncate(): %d is not a valid stream resource in %s on line %d
118118
bool(false)
119119
int(36)
120120

ext/standard/tests/general_functions/floatval.phpt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -157,8 +157,8 @@ float(-5000000)
157157
*** Testing floatval() on non floating types ***
158158
float(-2147483648)
159159
float(2147483648)
160-
float(5)
161-
float(6)
160+
float(%d)
161+
float(%d)
162162
float(0)
163163
float(1)
164164
float(-1300)
@@ -175,8 +175,8 @@ float(0)
175175
*** Testing doubleval() on non floating types ***
176176
float(-2147483648)
177177
float(2147483648)
178-
float(5)
179-
float(6)
178+
float(%d)
179+
float(%d)
180180
float(0)
181181
float(1)
182182
float(-1300)

0 commit comments

Comments
 (0)