rfc:peclversioning
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
rfc:peclversioning [2008/04/02 11:31] – pajoye | rfc:peclversioning [2008/07/16 13:00] – Fix URLs scottmac | ||
---|---|---|---|
Line 1: | Line 1: | ||
===== Request for Comments: PECL Versioning ===== | ===== Request for Comments: PECL Versioning ===== | ||
- | * **Author:** Steph Fox, Pierre A. Joye | ||
- | * **Status:** Work in progress | ||
=== The Problem === | === The Problem === | ||
- | Currently, PECL versioning is fairly anarchic. | + | Currently, PECL versioning is fairly anarchic. |
- | === Requirements === | + | There are actually two RFCs (proposals) to deal with version numbering in PECL and for core PHP extensions in general. |
- | Each PECL package has to follow the following requirements: | + | * [[rfc:peclversioning/ |
+ | * [[rfc: | ||
- | * Declare PHP_EXTNAME_VERSION in php_extname.h | ||
- | * Use PHP_EXTNAME_VERSION in every place where the version information is used, for example in both the zend_module_entry declaration and PHP_MINFO() (the phpinfo() source) | ||
- | * The " | ||
- | * Use a recognized versioning structure (so that version_compare() can be useful and users can easily see which version they have). See [[|Version naming]] for a detailed explaination. | ||
- | |||
- | === Optional version information === | ||
- | |||
- | * The cvs $Revision$ or $Id$ (or their equivalent in other source control system) placeholder can be used without restriction but it can't be used as a version number | ||
- | |||
- | |||
- | === Version Naming === | ||
- | |||
- | |||
- | There is two kind of packages in PECL, a normal PHP extension providing a set of APIs (http, enchant, fileinfo)and extension providing only data (timezonedb). Normal extensions have to use the standard version number defined below as the data package can use a date time version: | ||
- | |||
- | * Standard version: 2.2.11 Major | ||
- | * Date time version: 2008.2 (for february 2008) or 2008.04.4 (April 4th, 2008) | ||
- | |||
- | |||
- | == Detailed version number explanation == | ||
- | * A version number must include a major, a minor and a patch level version number. Please note that all are version numbers are mandatory. | ||
- | * A package version has a " | ||
- | * //PEAR doesn' | ||
- | * A backwards-compatability break may include feature additions | ||
- | * A feature addition may include bug fixes | ||
- | * The version name is always computed on the version name of the release, on which the new release is based, if one exists. | ||
- | * The version number must be greater or equal than 0.1.0 | ||
- | * All initial releases of a package with states " | ||
- | * The first release with state " | ||
- | * There may not be a stable release unless there has been at least one release before with the same major version. | ||
- | * BC may only be broken in releases that have a version number of " | ||
- | * Features may only be added in releases that have a version number of " | ||
- | * For releases that only fix bugs the version number should be " | ||
- | * The state should always be added as a suffix unless the state is " | ||
- | * In the lifecycle of a package each major version increase it is only once (once from major version number 0 to 1, from 1 to 2 etc.). | ||
- | |||
- | |||
- | == Example: Lifecycle of a package == | ||
- | ^ Release type ^ Changes ^ Version ^ Notes ^ | ||
- | | development release | initial release | 0.1.0dev1 | initial version | | ||
- | | development release | features added | 0.2.0dev1 | BC break allowed | | ||
- | | alpha release | features added | 0.9.0alpha1 | BC break allowed - but discouraged | | ||
- | | beta release | bug fixes | 0.9.0beta1 | BC break allowed - but discouraged | | ||
- | | beta release | bug fixes | 0.9.0beta2 | BC break allowed - but discouraged | | ||
- | | RC release | bug fixes | 1.0.0RC1 | BC break allowed - but heavily discouraged | | ||
- | | stable release | no changes | 1.0.0 | BC break is not allowed | | ||
- | | stable release | bug fixes | 1.0.1 | BC break is not allowed | | ||
- | | development release | features added | 1.1.0dev1 BC break is not allowed | | ||
- | | beta release | bug fixes | 1.1.0beta1 | BC break is not allowed | | ||
- | | stable release | bug fixes | 1.1.0 | BC break is not allowed | | ||
- | | stable release | features added | 1.2.0 | BC break is not allowed | | ||
- | | development release | major changes | 2.0.0dev1 | BC break is allowed | | ||
- | | alpha release | major changes | 2.0.0alpha1 | BC break is allowed - but discouraged | | ||
- | | beta release | bug fixes | 2.0.0beta1 | BC break is allowed - but discouraged | | ||
- | | RC release | features added | 2.0.0RC1 | BC break is allowed - but heavily discouraged | | ||
- | | RC release | bug fixes | 2.0.0RC2 | BC break is allowed - but heavily discouraged | | ||
- | | stable release | bug fixes | 2.0.0 | BC break is not allowed | | ||
- | | stable release | bug fixes | 2.0.1 | BC break is not allowed | | ||
- | |||
- | |||
- | |||
- | === Some Facts and Figures === | ||
- | There are currently 214 modules in PECL. Of these: | ||
- | |||
- | * 1 is written in PHP | ||
- | * 3 are SAPIs | ||
- | * 2 are no longer hosted in PECL (and should be deleted) | ||
- | * 1 doesn' | ||
- | * 1 doesn' | ||
- | * 1 was a CVS error (and should be deleted) | ||
- | * 1 is the timezone library for ext/date, and probably has non-standard versioning requirements | ||
- | |||
- | Of the remaining 204: | ||
- | |||
- | * 13 already use PHP_EXTNAME_VERSION declared in php_extname.h, | ||
- | * 25 already declare and use a versioning macro in php_extname.h, | ||
- | * 27 already declare and use a versioning macro somewhere in the source | ||
- | * 3 do the whole thing in reverse and use the release version from package.xml | ||
- | * 136 either hard-code the version, use $Id alone, use $Revision alone or ignore the whole thing | ||
- | |||
- | === Update 22/3/08 === | ||
- | I committed a change to the Windows build script to enable independent versioning for PECL modules in DLL properties. | ||
- | |||
- | === Update 24/3/08 === | ||
- | Following discussion, it was agreed that use of $Id/ | ||
- | |||
- | === Update 25/3/08 === | ||
- | Open items: | ||
- | |||
- | * The problem of PHP version-specific PECL builds | ||
- | * The problem of core module versioning | ||
- | * Labelling core modules as such on the pecl.php.net project homepage | ||
- | * Labelling PECL releases with their target PHP branches on the pecl.php.net project homepage | ||
- | |||
- | === Update 2/4/08 === | ||
- | Most of the modules in PECL now comply fully with the following rules: | ||
- | |||
- | * use x.x.x numbers for versioning | ||
- | * tag the version with ' | ||
- | * declare the macro PHP_EXTNAME_VERSION in php_extname.h | ||
- | * use the macro in zend_module_entry (so phpversion(' | ||
- | * use the macro in PHP_MINFO (so phpinfo() will include module versioning information) | ||
- | * express alpha, beta or RC using the format: 1.0.1a2, 1.0.0RC3, 2.5.3b1 | ||
- | |||
- | The seven ' | ||
- | |||
- | Two modules (maxdb and timezonedb) use a versioning structure based on third-party code that can't sensibly be altered. | ||
- | |||
- | One module (APC) already uses the proposed versioning structure, but declares a non-standard macro in a non-standard header. A handful of other modules (less than a dozen) declare their standard macro in a non-standard file. I'll do what I can to bring all modules fully into line, since a reliable convention potentially allows the declaration to have uses beyond populating Windows DLL properties. We could remove the hard-coded lists from our snaps scripts, for one... | ||
- | |||
- | One standard module (wxWidgets) doesn' | ||
- | |||
- | Obvious CVS errors and any modules containing no code have been deleted from PECL. As a side-effect, | ||
- | |||
- | Hartmut Holzgraefe has updated PECL_Gen to reflect the new versioning requirements. | ||
- | |||
- | === Core modules === | ||
- | Johannes Schlueter - as Release Master of the PHP 5.3 series - made it known early in the proceedings that he has concerns over -dev, -alpha or -beta tags appearing in PHP core module versions. There' | ||
- | |||
- | The idea of using the tag ' | ||
- | |||
- | **// | ||
- | |||
- | === Please comment on the pecl-dev mailing list === |
rfc/peclversioning.txt · Last modified: 2017/09/22 13:28 by 127.0.0.1