rfc:pickle

This is an old revision of the document!


PHP RFC: Pickle

  • Version: 0.1
  • Date: 2014-06-11 (use today's date here)
  • Author: Pierre Joye, pierre.php@gmail.com
  • Status: Under Discussion
  • First Published at: http://wiki.php.net/rfc/pickle

Proposes a new extension manager

https://github.com/pierrejoye/pickle

Introduction

This RFC proposes a new installer for the PHP extension.

Proposal

Main goals:

  • Make extension packaging and installing less errors prone.
  • Composer compatibitily
  • Windows Support

The current PEAR/PECL installer is not used anymore. BC could be kept by converting the package.xml before running the installer. However there is no plan yet to support PEAR/PECL channels support.

A packagist-like system will be implemented in pecl.php.net. We are still discussing this with the composer developers.

Concept

One of the main goal is to reduce meta data duplication, making the whole extension release process less error prone.

To achieve that, the existing information will be used. package.xml won't be used anymore (except if conversion is required). New files are introduced for the release changelogs. The naming format of the release changelog is RELEASE-x.y.z, where x.y.z is the actual version (should work fine with the TZ package, 20140611). Other existing files wil be used for the rest of the meta information:

  • Use of CREDITS file to generate authors
  • Use of the PHP header to generate the version information for the package

(API information still need to be done manually, but we could drop this info as it is only used by PEAR so far)

  • Include automatically all files in the release, relying on .gitignore for the ignore list

The CREDITS file will require some changes, email and the actual pecl/php.net handle as well as the homepage. We may implement something to fetch this information at packaging time from php.net, but that will prevent offline packaging.

A minimal json definition:

{
    "name": "apcu",
    "type": "extension",
    "extra": {
        "configure-options": {
            "enable-apc-bc": {
                "default": "yes",
                "prompt": "Enable full APC compatibility"
            },
            "enable-apcu-debug": {
                "default": "no",
                "prompt": "Enable internal debugging in APCu"
            }
        }
    }
}

Any other information will be added automatically on packaging:

{
    "name": "apcu",
    "type": "extension",
    "extra": {
        "configure-options": {
            "enable-apc-bc": {
                "default": "yes",
                "prompt": "Enable full APC compatibility"
            },
            "enable-apcu-debug": {
                "default": "no",
                "prompt": "Enable internal debugging in APCu"
            }
        }
    },
    "version": "4.0.4",
    "state": "beta",
    "authors": [
        {
            "name": "Joe",
            "handle": "Watkins",
            "email": "krakjoe",
            "homepage": "krakjoe@php.net"
        },
        {
            "name": "Anatol",
            "handle": "Belski",
            "email": "ab",
            "homepage": "ab@php.net"
        }
    ]
}

Backward Incompatible Changes

Everyone relying on the pecl command will have to migrate to pickle.

Proposed PHP Version(s)

next PHP release once the new system is stable enough (TBD).

RFC Impact

No impact in the core, but to bundle pickle.phar on release.

Open Issues

Make sure there are no open issues when the vote starts!

Implementation

After the project is implemented, this section should contain

  1. the version(s) it was merged to
  2. a link to the git commit(s)
  3. a link to the PHP manual entry for the feature

References

Links to external references, discussions or RFCs

Rejected Features

Keep this updated with features that were discussed on the mail lists.

rfc/pickle.1402494322.txt.gz · Last modified: 2017/09/22 13:28 (external edit)