MacBook – Perl blunders lead to OS X Reinstall

Well, I got a little daring last night and decided to compile Postgresql and Apache with mod_ssl and mod_perl on the MacBook so that I can get back to working on The Manusya Project. I got as far as compiling and installing Postgres. Once I was done with Postgres, I decided to get the various Perl components necessary for connecting to Postgres installed.

Here is where I royally screwed up. I configure CPAN to use a bunch of FTP sites. Apparently, there’s some problem with FTP sessions on OS X via CPAN. It’s quirky and doesn’t always work. I was able to install the DBI packages in /usr/local/lib bit I couldn’t download DBD::Pg from any of the mirrors. I decided to download libwww-perl manually and installed it into the /System area of OS X. It was about midnight and this is where I really started screwing up. I had installed some modules into the operating system specific location and other modules in /usr/local – no consistency.

At this point I had libwww-perl and DBI installed but I couldn’t install DBD::Pg manually because it couldn’t find DBI. Hmmmmm. Well, for some reason, I decided to upgrade Bundle-CPAN since the version that comes with OS X 10.4.6 was out of date. This is where everything went to hell. Some things were being installed in /System, others were being installed in /usr/local/lib/perl, others in /usr/local/lib/perl5 and others in /usr/local/System. This was getting too crazy, so I said, let’s clean it all out.

I deleted everything in /usr/local/lib/perl, /usr/local/lib/perl5 and /usr/local/System. I then deleted the CPAN Config.pm in /System and tried to start from scratch. Oh boy. Every Perl script I run now complains that Cwd.pm or File/Spec can’t be found. I got PathTools but even PathTools complains about File/Spec.

I spent quite a bit of time last night looking around on Apple’s site for a fresh download of the whole Perl distribution that they package with OS X. Unfortunately, I couldn’t find anything. I will be reinstalling OS X from scratch this evening to fix any potential instability I might have caused. It also gives me a good opportunity to install BootCamp and get Linux installed on my MacBook

technorati tags: , , ,


Posted

in

, ,

by

Tags: