[PHP-users 32833] Re: Pearでのインストール失敗について

goungoun gounx2 @ gmail.com
2007年 11月 9日 (金) 18:07:24 JST


こんにちは。

On Thu, 8 Nov 2007 22:16:09 +0900
"石田泰規" <yasu1965 @ gmail.com> wrote:
> root @ KURO-BOX:/usr/local/bin# pear install XML_Parser
> downloading XML_Parser-1.2.8.tgz ...
> Starting to download XML_Parser-1.2.8.tgz (13,476 bytes)
> .....done: 13,476 bytes
> Could not get contents of package "/usr/local/temp/download/XML_Parser-1.2.8.tgz
> ". Invalid tgz file.

XAMPP Windows Version 1.6.2
でpearのソースを "Could not get contents of package" でgrep
してみました。

----------------------------------------
function &fromTgzFile($file, $state)
{
    if (!class_exists('Archive_Tar')) {
        require_once 'Archive/Tar.php';
    }
    $tar = new Archive_Tar($file);
    if ($this->_debug <= 1) {
        $tar->pushErrorHandling(PEAR_ERROR_RETURN);
    }
    $content = $tar->listContent();
    if ($this->_debug <= 1) {
        $tar->popErrorHandling();
    }
    if (!is_array($content)) {
        if (is_string($file) && strlen($file < 255) && !@is_file($file)) {
            $ret = PEAR::raiseError("could not open file \"$file\"");
            return $ret;
        }
        $file = realpath($file);
        $ret = PEAR::raiseError("Could not get contents of package \"$file\"".
                                 '. Invalid tgz file.');
----------------------------------------

$tar = new Archive_Tar($file);
あたりで失敗してるっぽいですね。

Archive_Tar が最新か?とか、
XML_Parser-1.2.8.tgz を Archive_Tar で解凍するミニスクリプト書いて
詳しく調べてみる。とか。


-- 
goungoun <gounx2 @ gmail.com>
http://goungoun.dip.jp/app/



PHP-users メーリングリストの案内