Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

How to configure CPAN in perl under WinXp??

Posted on 2006-06-29
6
Medium Priority
?
876 Views
Last Modified: 2008-01-09
How do I configure CPAN in perl under WinXp ? please respone as soon as possible...

thanks,
0
Comment
Question by:arijit_rebaca
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 
LVL 39

Expert Comment

by:Adam314
ID: 17011119
Are you using activestate perl?  If so, you can use ppm to get packages.

If you want to be able to download source code from CPAN, you need to have a compiler.  Do you have one?
0
 
LVL 28

Accepted Solution

by:
FishMonger earned 150 total points
ID: 17011224
First you need to download Microsoft's nmake15.exe program (compiler); it's a self-extracting zip file. When it's executed, it will create 3 files on your disk (nmake.exe, nmake.err, and readme.txt). Move nmake.* to c:\perl\bin, which should be on the path.

ftp://ftp.microsoft.com/softlib/mslfiles/nmake15.exe

This next step isn't required, but I recommend it because it installs several utilities that aide cpan in the installation of modules; utilities such as;
gzip.EXE
lynx.EXE
less.EXE
tar.exe
unzip.exe
wget.exe

Download/install Cygwin.
http://www.cygwin.com/

Next, start the cpan shell

perl -MCPAN -e shell

The first time you enter the shell, it will ask if you're ready to start the manual configuration.  Answer "yes" and it will "walk" you through its configuration.  Just accept the defaults to most of the settings, but you may need to supply some path info if it can't find some of the utilities.
0
 
LVL 28

Expert Comment

by:FishMonger
ID: 17011250
If it helps, here's my config that you can use as a guide.

cpan> o conf
CPAN::Config options from C:/Perl/lib/CPAN/Config.pm:
    commit             [Commit changes to disk]
    defaults           [Reload defaults from disk]
    help               [Short help about 'o conf' usage]
    init               [Interactive setting of all options]

    build_cache        [10]
    build_dir          [C:\.cpan\build]
    bzip2              []
    cache_metadata     [1]
    cpan_home          [C:\.cpan]
    curl               []
    dontload_hash
    ftp                [C:\WINDOWS\system32\ftp.EXE]
    ftp_passive        [1]
    ftp_proxy          []
    getcwd             [cwd]
    gpg                []
    gzip               [C:\Cygwin\bin\gzip.EXE]
    histfile           [C:\.cpan\histfile]
    histsize           [100]
    http_proxy         []
    inactivity_timeout [0]
    index_expire       [1]
    inhibit_startup_message [0]
    keep_source_where  [C:\.cpan\sources]
    lynx               [C:\Cygwin\bin\lynx.EXE]
    make               [C:\perl\bin\nmake.exe]
    make_arg           []
    make_install_arg   [UNINST=1]
    makepl_arg         []
    mbuild_arg         []
    mbuild_install_arg [--uninst 1]
    mbuildpl_arg       []
    ncftpget           [C:\Cygwin\bin\ncftpget]
    no_proxy           []
    pager              [C:\Cygwin\bin\less.EXE]
    prefer_installer   [EUMM]
    prerequisites_policy [follow]
    scan_cache         [atstart]
    shell              [C:\WINNT\system32\cmd.exe]
    show_upload_date   [1]
    tar                [C:\Cygwin\bin\tar.exe]
    term_is_latin      [1]
    unzip              [C:\Cygwin\bin\unzip.exe]
    urllist
        [ftp://theoryx5.uwinnipeg.ca/pub/CPAN/]
        [ftp://cpan.sunsite.ualberta.ca/pub/CPAN/]
        [ftp://ftp.nrc.ca/pub/CPAN/]
        [ftp://cpan.chebucto.ns.ca/pub/CPAN/]
    wget               [C:\Cygwin\bin\wget.exe]
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:arijit_rebaca
ID: 17015523
Hi  FishMonger ,


up to
Download/install Cygwin.
http://www.cygwin.com/

it has done. But from then I con't the cpan shell. How I do it?

thanks,
0
 

Author Comment

by:arijit_rebaca
ID: 17015527
I con't start the CPAN shell. How I do it?
0
 
LVL 28

Expert Comment

by:FishMonger
ID: 17016301
You start the cpan shell by executing the perl command I showed from the command prompt, like this.

C:\>perl -MCPAN -e shell
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I've just discovered very important differences between Windows an Unix formats in Perl,at least 5.xx.. MOST IMPORTANT: Use Unix file format while saving Your script. otherwise it will have ^M s or smth likely weird in the EOL, Then DO NOT use m…
There are many situations when we need to display the data in sorted order. For example: Student details by name or by rank or by total marks etc. If you are working on data driven based projects then you will use sorting techniques very frequently.…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Six Sigma Control Plans

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question