summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTomas V.V.Cox <cox@php.net>2003-09-19 16:50:17 +0000
committerTomas V.V.Cox <cox@php.net>2003-09-19 16:50:17 +0000
commit926cfa307cc797152a31c2bf70ad395e953718bf (patch)
treebcae9f7f6352009fcde90231089b9b7c0451d617
parentace85c9015fc70af36a94249acdd8f9360ab75c0 (diff)
downloadphp-git-926cfa307cc797152a31c2bf70ad395e953718bf.tar.gz
RFC about PECL binary creation and distribution
-rw-r--r--pear/docs/rfc01_PEAR_pecl-binaries.txt88
1 files changed, 88 insertions, 0 deletions
diff --git a/pear/docs/rfc01_PEAR_pecl-binaries.txt b/pear/docs/rfc01_PEAR_pecl-binaries.txt
new file mode 100644
index 0000000000..767a486503
--- /dev/null
+++ b/pear/docs/rfc01_PEAR_pecl-binaries.txt
@@ -0,0 +1,88 @@
+Author: Tomas V.V.Cox <cox@idecnet.com>
+Revision: $Id$
+Abstract: Open discussion on how to handle PECL binary packages
+
+
+pecl package name
+-----------------
+
+The name of the extension would be:
+
+peclfoo-bin-<OS>-<ARCH>-3.1.2.tgz
+
+The os (Operating system) and arch (CPU type), would be the value
+returned by the OS_Guess class.
+
+package creation
+----------------
+
+pear package [-t <type>] <package>
+
+-t <type> The type of package you want to generate (pear, rpm,
+msi, src, etc)
+
+Without args it will package the extension as it does nowadays (the
+same as "-t src").
+
+We have now native pear packages, rpm, msi is planned and others
+will surely come. Additionally of generating the native package description
+file, we could perhaps also call the tools for generating the whole package.
+
+An idea would be to create in addition a BUILDINFO.txt file with some data about
+the env where the extension was compiled at, like the
+php version, the php_uname(), the extra libs versions, os vendor
+version, pear version, etc.
+
+package.xml
+-----------
+
+As a binary release shares the same release data with the source
+distrib, the same package.xml file could be used for all kind of
+distribs. Let's say something like:
+
+<release>
+ <version>...
+ <date>
+ <notes>
+ <filelist>..
+ <file role="ext" platform="">
+ </filelist>
+</release>
+
+A package may contain many compiled extensions for different platforms,
+one single extension or the sources.
+
+
+Installation
+------------
+
+pear install -t bin peclfoo (download and install the binary distrib of
+peclfoo for your current OS-ARCH)
+
+pear install peclfoo (download, build and install peclfoo)
+
+All the files with role="ext" would be installed
+in "ext_dir" (pear cmd setting). The user can config it with "pear config-set ext_dir=XXX".
+If this var is not explicitly set, the following will be used for
+finding a default location:
+
+if (getenv('PHP_PEAR_EXTENSION_DIR')) {
+ define('PEAR_CONFIG_DEFAULT_EXT_DIR', getenv('PHP_PEAR_EXTENSION_DIR'));
+ } else {
+ if (ini_get('extension_dir')) {
+ define('PEAR_CONFIG_DEFAULT_EXT_DIR', ini_get('extension_dir'));
+ } elseif (defined('PEAR_EXTENSION_DIR') && @is_dir(PEAR_EXTENSION_DIR)) {
+ define('PEAR_CONFIG_DEFAULT_EXT_DIR', PEAR_EXTENSION_DIR);
+ } elseif (defined('PHP_EXTENSION_DIR')) {
+ define('PEAR_CONFIG_DEFAULT_EXT_DIR', PHP_EXTENSION_DIR);
+ } else {
+ define('PEAR_CONFIG_DEFAULT_EXT_DIR', '.');
+ }
+}
+
+Listing in the web
+------------------
+
+A new column "Type" should be added to the release listing under the
+package home page at pear.php.net, saying that the package is a binary
+distrib compiled for OS X and ARCH Y or sources.