Re: Moving PEAR to another Machine

From: Date: Mon, 05 Mar 2007 16:56:22 +0000
Subject: Re: Moving PEAR to another Machine
References: 1 2  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-26727@lists.php.net to get a copy of this message
Ian Warner wrote: > >> -----Original Message----- >> From: Gregory Beaver [mailto:greg@chiaraquartet.net] >> Sent: 05 March 2007 16:24 >> To: Ian Warner >> Cc: 'pear-general' >> Subject: Re: Moving PEAR to another Machine >> >> Ian Warner wrote: >>> Hi >>> >>> I just tried to move my WAMP installation from my USB drive to another >> drive >>> - the drive letter was different. I changed all the places this was >>> necessary to change. I.e. in PEAR.ini and surprisingly in the pear.bat >>> itself. >>> >>> Also in the php.ini include path >>> >>> However when I then tried to install a pear package I got an error >> saying it >>> couldn't find the PEAR.php core file. >>> >>> So where else do I need to change the pathing to allow PEAR to be easily >>> moved around? >> Hi Ian, >> >> This is a tricky thing to do. It may be easier to re-install. >> >> However, having said that dire thing :), you will need to change the >> set_include_path() call in pearcmd.php, which is hard-coded. After you >> do this, reinstall all of the packages with "pear upgrade >> --register-only --force <Packagename>-<version>" and it will update the >> drive letter in the registry. This last step is very important: full >> paths are hardcoded for every single file of every package you have >> installed, you do *not* want to fix that by hand :) >> >> As always, ask here again if you have more troubles with the move. > > Ok thanks understand that but to be honest I cannot see the paths hard coded > into any packages? look in the .registry/ directory inside your PEAR installation. There are bunch of files named package.reg (like pear.reg). These files are needed in order to upgrade packages in the future, and full paths are hardcoded into them. > I am writing a Batch file to install all the needed PEAR packages I need - > but after each PEAR call it exits. Seems it may be something in PEAR that > does not allow the commands to chain I.e. Any advice on that? > > @ECHO off > > pear -q channel-update -f -c pear.php.net > > PAUSE > > pear -q config-set preferred_state alpha > pear -q upgrade-all > > pear -q install -a HTML_QuickForm > > PAUSE pear is a batch file, try call pear -q channel-update -f -c pear.php.net etc. Greg

« previous php.pear.general (#26727) next »