openbsd-ports/www/pear/patches/patch-go-pear
2008-08-22 14:48:53 +00:00

131 lines
3.5 KiB
Plaintext

$OpenBSD: patch-go-pear,v 1.2 2008/08/22 14:48:53 robert Exp $
--- go-pear.orig Mon Sep 10 19:21:57 2007
+++ go-pear Tue May 20 15:51:12 2008
@@ -308,6 +308,7 @@ if (WEBINSTALLER) {
$install_pfc = $_SESSION['go-pear']['install_pfc'];
}
+/*
if (!WEBINSTALLER) {
$tty = WINDOWS ? @fopen('\con', 'r') : @fopen('/dev/tty', 'r');
@@ -351,6 +352,7 @@ If you wish to abort, press Control-C now, or press En
$http_proxy = $tmp;
}
}
+*/
$origpwd = getcwd();
@@ -423,6 +425,7 @@ we strongly recommand to use it.
}
}
+/*
while (!WEBINSTALLER) {
print "
Below is a suggested file layout for your new PEAR installation. To
@@ -505,6 +508,7 @@ If you have a CLI (or CGI) php.exe available, we stron
}
}
}
+*/
foreach ($config_vars as $n => $var) {
for ($m = 1; $m <= count($config_vars); $m++) {
@@ -574,6 +578,7 @@ Run this script as $root or pick another location.\n")
}
}
+/*
if (!WEBINSTALLER) {
$msg = "The following PEAR packages are bundled with PHP: " .
implode(', ', $pfc_packages);
@@ -582,6 +587,7 @@ if (!WEBINSTALLER) {
$install_pfc = !stristr(fgets($tty, 1024), "n");
print "\n";
}
+*/
####
# Download
@@ -593,6 +599,7 @@ if (function_exists('set_include_path')) {
ini_set('include_path', $ptmp);
}
+/*
if (!extension_loaded('zlib') && !WEBINSTALLER) { // In Web context we could be in multithread env which makes dl() end up with a fatal error.
if (WINDOWS) {
@dl('php_zlib.dll');
@@ -617,6 +624,7 @@ print "Loading zlib: ".($have_gzip ? 'ok' : 'failed').
if (!$have_gzip) {
print "Downloading uncompressed packages\n";
};
+*/
if ($install_pfc) {
$to_install = array_merge($installer_packages, $pfc_packages);
@@ -776,7 +784,7 @@ include_once "PEAR/Registry.php";
if (WEBINSTALLER || isset($_SERVER['argv'][1]) && $_SERVER['argv'][1] == 'local') {
$config = &PEAR_Config::singleton($prefix."/pear.conf", '');
} else {
- $config = &PEAR_Config::singleton();
+ $config = &PEAR_Config::singleton($prefix."/etc/pear.conf", '');
}
@@ -812,6 +820,7 @@ displayHTMLProgress($progress = 99);
// Base installation finished
+/*
ini_restore("include_path");
if (!WEBINSTALLER) {
@@ -969,6 +978,7 @@ if ( WINDOWS ) {
if (WINDOWS && !WEBINSTALLER) {
win32CreateRegEnv();
}
+*/
// Set of functions following
/**
* Parse the given dirname
@@ -1403,17 +1413,17 @@ function detect_install_dirs($_prefix = null) {
}
} else {
if ($_prefix === null) {
- $prefix = dirname(PHP_BINDIR);
+ $prefix = "%%PREFIX%%";
} else {
$prefix = $_prefix;
}
$bin_dir = '$prefix/bin';
- $php_dir = '$prefix/share/pear';
- $doc_dir = '$php_dir/docs';
- $data_dir = '$php_dir/data';
- $test_dir = '$php_dir/tests';
- $temp_dir = '$prefix/temp';
-
+ $php_dir = '$prefix/pear/lib';
+ $doc_dir = '$prefix/share/doc/pear';
+ $data_dir = '$prefix/pear/data';
+ $test_dir = '$prefix/pear/tests';
+ $temp_dir = '/tmp';
+/*
// check if the user has installed PHP with PHP or GNU layout
if (@is_dir("$prefix/lib/php/.registry")) {
$php_dir = '$prefix/lib/php';
@@ -1425,6 +1435,7 @@ function detect_install_dirs($_prefix = null) {
} elseif (@is_dir("$prefix/share/php/.registry")) {
$php_dir = '$prefix/share/php';
}
+*/
}
}
@@ -2530,3 +2541,4 @@ php.ini <$pathIni> include_path updated.
}
return true;
}
+?>