Browse files

Polishing packaging related files.

  • Loading branch information...
1 parent 01f522c commit 2c4fe9826a5e99ee73c59e7652f6bf0dea01db7d @boenrobot boenrobot committed Aug 3, 2012
Showing with 29 additions and 24 deletions.
  1. +11 −11 extrasetup.php
  2. +12 −7 package.xml
  3. +6 −6 stub.php
View
22 extrasetup.php
@@ -1,28 +1,28 @@
<?php
$extrafiles = array();
-
-$phpDir = Pyrus\Config::current()->php_dir . DIRECTORY_SEPARATOR;
+$phpDir = Pyrus\Config::current()->php_dir;
$packages = array('PEAR2/Autoload', 'PEAR2/Cache/SHM');
+$oldCwd = getcwd();
+chdir($phpDir);
foreach ($packages as $pkg) {
- $prefix = $phpDir . $pkg;
-
- if (is_dir($prefix)) {
+ if (is_dir($pkg)) {
foreach (
new RecursiveIteratorIterator(
new RecursiveDirectoryIterator(
- $prefix,
+ $pkg,
RecursiveDirectoryIterator::UNIX_PATHS
),
RecursiveIteratorIterator::LEAVES_ONLY
) as $path
) {
- $pathname = $path->getPathname();
- $extrafiles['src/' . $pathname] = $pathname;
+ $extrafiles['src/' . $path->getPathname()] = $path->getRealPath();
}
}
- if (is_file($prefix . '.php')) {
- $extrafiles['src/' . $pkg . '.php'] = $prefix . '.php';
+ if (is_file($pkg . '.php')) {
+ $extrafiles['src/' . $pkg . '.php']
+ = $phpDir . DIRECTORY_SEPARATOR . $pkg . '.php';
}
-}
+}
+chdir($oldCwd);
View
19 package.xml
@@ -13,8 +13,8 @@ This package abstracts this away, so that when you want to get exactly N amount
<email>boen.robot@gmail.com</email>
<active>yes</active>
</lead>
- <date>2012-07-11</date>
- <time>00:15:41</time>
+ <date>2012-08-03</date>
+ <time>02:47:16</time>
<version>
<release>1.0.0a3</release>
<api>1.0.0</api>
@@ -112,11 +112,16 @@ This package abstracts this away, so that when you want to get exactly N amount
</pearinstaller>
</required>
<optional>
- <package>
- <name>PEAR2_Cache_SHM</name>
- <channel>pear2.php.net</channel>
- <min>0.1.0</min>
- </package>
+ <package>
+ <name>PEAR2_Autoload</name>
+ <channel>pear2.php.net</channel>
+ <min>0.2.4</min>
+ </package>
+ <package>
+ <name>PEAR2_Cache_SHM</name>
+ <channel>pear2.php.net</channel>
+ <min>0.1.0</min>
+ </package>
</optional>
</dependencies>
<phprelease>
View
12 stub.php
@@ -11,7 +11,7 @@
if ($isNotCli) {
header('Content-Type: text/plain;charset=UTF-8');
}
- echo "PEAR2_Net_Transmitter @PACKAGE_VERSION@\n";
+ echo "@PACKAGE_NAME@ @PACKAGE_VERSION@\n";
if (version_compare(phpversion(), '5.3.0', '<')) {
echo "\nThis package requires PHP 5.3.0 or later.";
@@ -26,15 +26,15 @@
if (function_exists('stream_socket_client')) {
echo <<<HEREDOC
-The stream_socket_client() function is enabled.\n
+The stream_socket_client() function is enabled.
If you can't connect to a host, this means one
-of the following:\n
+of the following:
1. You've mistyped the IP and/or port. Check the IP and port you've specified
-are the one you intended.\n
+are the one you intended.
2. The host is not reachable from your web server. Try to reach the host
from the web server by other means (e.g. ping) using the same IP, and if
-you're unable to reach it, check your network's settings.\n
-2. Your web server is configured to forbid that outgoing connection. If you're
+you're unable to reach it, check your network's settings.
+3. Your web server is configured to forbid that outgoing connection. If you're
the web server administrator, check your firewall's settings. If you're on a
hosting plan... Typically, shared hosts block all outgoing connections, but it's
also possible that only connections to that port are blocked. If the remote host

0 comments on commit 2c4fe98

Please sign in to comment.