Page 1 of 1

Installing PEAR under XAMPP problem and probably solution...

PostPosted: 02. July 2005 05:52
by alucard01
Hi all.

I have a problem installing PEAR under XAMPP as follow:

Problem:

Once I extract XAMPP and run go-pear.php, the following error occur:

Starting installation ...
Loading zlib: ok
Using local package: PEAR.............ok
Downloading package: Archive_Tar......ok
Downloading package: Console_Getopt....ok
Downloading package: XML_RPC..........ok
Downloading package: Pager............ok
Downloading package: HTML_Template_IT....ok
Downloading package: Net_UserAgent_Detect....ok
Downloading package: PEAR_Frontend_Web....ok
Bootstrapping: PEAR...................(local) ok
Bootstrapping: Archive_Tar............(local) ok
Bootstrapping: Console_Getopt.........(local) ok
Downloading package: DB...............ok
Downloading package: Net_Socket.......ok
Downloading package: Net_SMTP.........ok
Downloading package: Mail.............ok
Downloading package: XML_Parser.......ok
Downloading package: PHPUnit..........ok
Extracting installer.................. Invalid checksum for file " Warning: unlink(C:\DOCUME~1\lap\LOCALS~1\Temp/gop20.tmp\PEAR.php) [function.unlink]: Permission denied in C:\xampp\php\pear\go-pear.php on line 1081

Warning: rmdir(C:\DOCUME~1\lap\LOCALS~1\Temp/gop20.tmp) [function.rmdir]: Directory not empty in C:\xampp\php\pear\go-pear.php on line 1085

And the installation stop, PEAR cannot be used.


Probably solution:

- download PHP 5.0.4 from www.php.net
- extract and copy folder PEAR and go-pear.bat
- rename folder PEAR > PEAR.old and go-pear.bat > go-pear.bat.old as a backup in XAMPP
- paste folder PEAR and go-pear.bat from PHP 5.0.4 to x:\xampp\php.
- run go-pear.bat

And it works!!!

I just think if it is a bug in XAMPP. So I hope apachefriends can fix this.

Thank you and correct me if I am wrong.

PostPosted: 02. July 2005 14:29
by alucard01
Yes, you're right. XAMPP include PEAR.
However, when I run either go-pear.php or go-pear.bat, it produced same error...I dunno why...

BTW, I am not quite understand what you mean by:

In "\xampp\php", copy "php.exe" to "phpcli.exe"....

Can you please explain more?

Thank you

PostPosted: 02. July 2005 15:03
by bobbyallen
alucard01 wrote:Yes, you're right. XAMPP include PEAR.
However, when I run either go-pear.php or go-pear.bat, it produced same error...I dunno why...

BTW, I am not quite understand what you mean by:

In "\xampp\php", copy "php.exe" to "phpcli.exe"....

Can you please explain more?

Thank you


I think he means copy php.exe from your xampp directory for example:

C:\XAMPP\PHP\PHP.EXE and then COPY AND RENAME PHP.EXE to the same directory, so: C:\XAMPP\PHP\PHPCLI.EXE

So now you should have php.exe and phpcli.exe in the same directory:

x:\xampp\php\

Hope that helps :)

PostPosted: 02. July 2005 20:55
by Wiedmann
Sorry, i have take back my last post for some more tests...

1)
It is a bad idea to run "go-pear.bat". We should delete this file in the next XAMPP release. This file is only for the first initial installation off PEAR. Only use "pear.bat" (but that one in XAMPP is brocken).

2)
There are some other issues. So, copy "php.exe" will not do the complete trick.

--> If you have the original PEAR-folder from your installation, you can have an updated "pear.bat".

Download this file and copy it over the existing "pear.bat".

After that, you can for example update your PEAR with:
Code: Select all
pear upgrade-all -n -B

PostPosted: 03. July 2005 15:55
by alucard01
Thank you.

Althogh PEAR is by default "inside" XAMPP, I dunno if it is by default "installed". i.e. do we need to manually install it, or is it already installed so that we just use it immediately? (The fact seems to be:"manually install")

I hope that in next version of XAMPP can solve this problem.

Thanks again for your response.

PostPosted: 03. July 2005 16:04
by Wiedmann
No. PEAR is allready included in XAMPP. You must not install it and you can use it in your scripts. Only the console tool "pear.bat" ist not working without the updated file.

(That's true for XAMPP, but not for XAMPP Light. In XAMPP Light there is no PEAR)

PostPosted: 03. July 2005 16:35
by alucard01
Oh, sorry for misunderstanding.

Thank you.