Re: Packaging a "bin" dir correctly?
| From: | Brett Bieber | Date: | Mon, 15 Sep 2008 16:22:30 +0000 |
| Subject: | Re: Packaging a "bin" dir correctly? | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-50758@lists.php.net to get a copy of this message | ||
On Mon, Sep 15, 2008 at 9:37 AM, Paul M Jones <pmjones88@gmail.com> wrote:
> Hi all,
>
> I am working with PEAR_PackageFileManger2, and am attempting to get the
> files in my "bin" dir to get installed to the pear/bin dir.
>
> I have tried setting the role (via an 'exceptions' rule) to "bin" and
> "script", but the files still get installed to pear/php (the default role).
>
> The release script is here:
> <http://svn.solarphp.com/core/release>
>
> The relevant lines appear to be:
>
> $opts = array(
> 'baseinstalldir' => '/',
> 'packagefile' => 'package2.xml',
> 'packagedirectory' => dirname(__FILE__) . '/trunk/',
> 'filelistgenerator' => 'file',
> 'roles' => array(
> '*' => 'php',
> ),
> 'exceptions' => array(
> 'bin/*' => 'script',
> 'tests/*' => 'test',
> 'docs/*' => 'doc',
> ),
> );
>
> The resulting package2.xml file shows this role for the bin/solar file:
>
> <file baseinstalldir="/" md5sum="555a08764f80d7436578de32c64459cf"
> name="bin/solar" role="php">
>
> The exception rules on "tests" and "docs" *do* get installed to pear/test
> and pear/doc respectively.
>
> Anybody have some insight here, either as to the correct role name, or an
> alternative way to structure the build options?
The standard layout should automatically set the role="doc" and
role="test" on the docs and tests dirs, so I don't think you need
those and I believe the exceptions array should reference individual
files. Maybe try something like this?
ucommbieber:core bbieber$ svn diff release
Index: release
===================================================================
--- release (revision 3394)
+++ release (working copy)
@@ -140,9 +140,7 @@
'*' => 'php',
),
'exceptions' => array(
- 'bin/*' => 'script',
- 'tests/*' => 'test',
- 'docs/*' => 'doc',
+ 'bin/solar' => 'script',
),
);
--
Brett Bieber
http://saltybeagle.com/