Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
General
GeneralPortable MacsHardwareNetworking
Applications
Mac ApplicationsEudoraFirefox / MozillaInternet ExplorerOutlook ExpressMS OfficeEntourageExcelPowerPointWordVirtual PCMedia PlayerOther MS Products
Programming
Mac ProgrammingCodeWarriorPerl
Country Specific
Australian Mac GroupUK Mac Group

Mac Forum / Programming / Perl / June 2005



Tip: Looking for answers? Try searching our database.

Frickin' CPAN

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
John Mercer - 08 Jun 2005 21:14 GMT
Hi all,

CPAN is being a pain in the a.s, and I don't know what the problem  
is. Here's an error message when I run "install Bundle::XML".

Can't exec "/usr/bin": Permission denied at /System/Library/Perl/
5.8.6/darwin-thread-multi-2level/IO/File.pm line 176, <FIN> line 1.
Could not pipe[/usr/bin --decompress --stdout /var/root/.cpan/sources/
authors/01mailrc.txt.gz |]: Permission denied at /System/Library/Perl/
5.8.6/CPAN.pm line 5727, <FIN> line 1.

When I try to run "install XML::XPath" I get about 20 repetitions of

Subroutine AUTOLOAD redefined at /sw/lib/perl5/5.8.6/darwin-thread-
multi-2level/Compress/Zlib.pm line 84, <FIN> line 2

Regarding the first error, I don't see how I can have a permissions  
error when I'm running CPAN as the root user. Root has--I checked--
read, write, execute permissions in that directory (/System/Library/
etc, etc). Regarding the second error, I have no idea what that's  
about. Could fink have somehow messed up my perl installation.

In case this helps, I'm running Perl 5.8.6 under OSX 10.4 on Macmini.  
I'm running all the install scripts as root.

Any help would really be appreciated. Thanks.

--John M
Jan Dubois - 09 Jun 2005 02:00 GMT
> When I try to run "install XML::XPath" I get about 20 repetitions of
>
[quoted text clipped - 11 lines]
>
> Any help would really be appreciated. Thanks.

Well, you could install ActivePerl, add it to your PATH, and then type

   ppm install XML-XPath

and you should be all set. :)

Cheers,
-Jan
Ken Williams - 09 Jun 2005 02:56 GMT
Hi John,

The permissions thing is a red herring.

Look more closely at the error message.  It's trying to run a program
called "/usr/bin".  Look at your CPAN configuration ("o conf" in the
CPAN shell) to figure out why.

 -Ken

> Hi all,
>
[quoted text clipped - 27 lines]
>
> --John M
John Mercer - 09 Jun 2005 16:04 GMT
Hi guys,

Firewall problems? Or config problems? Or both?

I've found that CPAN works when I run "sudo perl -MCPAN etc", but not  
when I run as root: "macbox:/ root# perl -MCPAN". I find that very  
strange, but hey, if it works as sudo, it works and that's all I need.

However, it doesn't work very well. When I run CPAN it take FOREVER  
to download modules, but then installs them pretty quickly (at least  
when there aren't any errors--and I often have plenty). Could my  
firewall by interfering with CPAN? I don't have anything fancy: just  
the OSX Tiger firewall and a Netgear router on a home-office network.  
Do I need to tweak some obscure config file so that CPAN can get in  
and out of the firewall.

PPM also takes forever to download, if it downloads at all.

In case it help, I've appended the sudo/root config file below.  
Please let me know if anything's wrong w/ it.

Many thanks,

John Mercer

/System/Library/Perl/5.8.6/CPAN/Config.pm

    build_cache        20
    build_dir          /var/root/.cpan/build
    cache_metadata     1
    cpan_home          /var/root/.cpan
    dontload_hash
    ftp                /usr/bin/ftp
    ftp_proxy
    getcwd             cwd
    gpg
    gzip               /usr/bin
    histfile           /var/root/.cpan/histfile
    histsize           100
    http_proxy
    inactivity_timeout 0
    index_expire       1
    inhibit_startup_message 0
    keep_source_where  /var/root/.cpan/sources
    lynx               /sw/bin
    make               /usr/bin/make
    make_arg
    make_install_arg
    makepl_arg
    ncftpget           /usr/bin/ncftpget
    no_proxy
    pager              /usr/bin/less
    prerequisites_policy ask
    scan_cache         atstart
    shell              /bin/sh
    tar                /usr/bin
    term_is_latin      1
    unzip              /usr/bin
    urllist
        ftp://ftp.sunsite.utk.edu/pub/CPAN/
        ftp://ftp.theshell.com/pub/CPAN/
        ftp://ftp.uwsg.iu.edu/pub/perl/CPAN/
        ftp://linux.cs.lewisu.edu/pub/CPAN
        ftp://mirror.candidhosting.com/pub/CPAN
        ftp://mirror.cc.columbia.edu/pub/software/cpan/
        ftp://mirror.datapipe.net/pub/CPAN/
        ftp://mirror.hiwaay.net/CPAN/
        ftp://mirror.sg.depaul.edu/pub/CPAN/
        ftp://mirror.sit.wisc.edu/pub/CPAN/
        ftp://mirror.xmission.com/CPAN/
        ftp://mirrors.ibiblio.org/pub/mirrors/CPAN
        ftp://mirrors.jtlnet.com/CPAN/
        ftp://mirrors.kernel.org/pub/CPAN
        ftp://mirrors.phenominet.com/pub/CPAN/
        ftp://mirrors.rcn.net/pub/lang/CPAN/
        ftp://perl.secsup.org/pub/perl/
        http://cpan.belfry.net/
        http://cpan.binarycompass.org
        http://cpan.mirrors.hoobly.com/
        http://cpan.mirrors.nks.net/
    wget               /sw/bin/wget

> Hi John,
>
[quoted text clipped - 35 lines]
>>
>> --John M
Larry Prall - 09 Jun 2005 16:08 GMT
You might want to take a look at that URL list.  Try going to each  
site by hand and see how long it takes to connect.  Move your fastest  
sites to the top of the list.

- Larry

>     urllist
>         ftp://ftp.sunsite.utk.edu/pub/CPAN/
[quoted text clipped - 19 lines]
>         http://cpan.mirrors.nks.net/
>     wget               /sw/bin/wget
Ken Williams - 09 Jun 2005 19:49 GMT
I feel like nobody's listening...

Look at your 'tar', 'unzip', 'lynx', and 'gzip' entries.  They don't
actually include the name of the program.

Here are the equivalent ones from my config:

  'gzip' => q[/usr/bin/gzip],
  'lynx' => q[],
  'tar' => q[/usr/bin/tar],
  'unzip' => q[/usr/bin/unzip],

 -Ken

> Hi guys,
>
[quoted text clipped - 120 lines]
>>>
>>> --John M
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.