downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

Our source is open

The syntax highlighted source is automatically generated by PHP from the plaintext script. If you're interested in what's behind the several functions we used, you can always take a look at the source of the following files:

Of course, if you want to see the source of this page, we have it available. You can also browse the SVN repository for this website on svn.php.net.

Source of: /manual/en/install.pecl.pear.php

<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$PARENTS = array();
include_once
dirname(__FILE__) ."/toc/install.pecl.inc";
$setup = array (
 
'home' =>
  array (
   
0 => 'index.php',
   
1 => 'PHP Manual',
  ),
 
'head' =>
  array (
   
0 => 'UTF-8',
   
1 => 'en',
  ),
 
'this' =>
  array (
   
0 => 'install.pecl.pear.php',
   
1 => 'Compiling shared PECL extensions with the pecl command',
  ),
 
'up' =>
  array (
   
0 => 'install.pecl.php',
   
1 => 'Installation of PECL extensions',
  ),
 
'prev' =>
  array (
   
0 => 'install.pecl.windows.php',
   
1 => 'Installing a PHP extension on Windows',
  ),
 
'next' =>
  array (
   
0 => 'install.pecl.phpize.php',
   
1 => 'Compiling shared PECL extensions with phpize',
  ),
);
$setup["toc"] = $TOC;
$setup["parents"] = $PARENTS;
manual_setup($setup);

manual_header();
?>
<div id="install.pecl.pear" class="sect1">
  <h2 class="title">Compiling shared PECL extensions with the pecl command</h2>
  <p class="simpara">
   PECL makes it easy to create shared PHP extensions. Using the
   <a href="http://pear.php.net/manual/en/guide.users.commandline.cli.php" class="link external">&raquo; pecl command</a>, do the following:
  </p>
  <p class="para">
   <div class="example-contents screen"><br />
$ pecl install extname<br />
   </div>
  </p>
  <p class="simpara">
   This will download the source for <em class="emphasis">extname</em>,
   compile, and install <var class="filename">extname.so</var> into your <a href="ini.core.php#ini.extension-dir" class="link">extension_dir</a>. 
   <var class="filename">extname.so</var> may then be loaded via <var class="filename">php.ini</var>
  </p>
  <p class="simpara">
   By default, the <i>pecl</i> command will not install
   packages that are marked with the <i>alpha</i> or
   <i>beta</i> state.  If no <i>stable</i> packages
   are available, you may install a <i>beta</i> package using the
   following command:
  </p>
  <p class="para">
   <div class="example-contents screen"><br />
$ pecl install extname-beta<br />
   </div>
  </p>
  <p class="para">
   You may also install a specific version using this variant:
  </p>
  <p class="para">
   <div class="example-contents screen"><br />
$ pecl install extname-0.1<br />
   </div>
  </p>
  <blockquote><p><b class="note">Note</b>:
  
    After enabling the extension in <var class="filename">php.ini</var>, restarting the web service is
    required for the changes to be picked up.
   <br />
  </p></blockquote>
 </div><?php manual_footer(); ?>
 
show source | credits | sitemap | contact | advertising | mirror sites