There are many ways to install perl modules. The following are a few methods I use often -
| Login Type | Package Type | Possible Action |
| SSH, telnet, Unix, no internet access from server | Source Package | scp or ftp source package (*.tar.gz) onto remote server, then unpack in a work directory -
tar -zxvf pkg.tar.gz
Change into the package directory and
make Makefile.PL
make
make install
make test
|
| SSH, telnet, Windows, no internet access from server | Binary Package (ppm) | scp or ftp the ppm package onto remote server, set ppm repository to point to work directory on remote server, and ppm --install package. Be sure to read the ppm documentation on ActiveState website here |
| SSH, telnet, Windows, has internet on remote server | Binary Package (ppm) | Log onto the remote server and ppm --install package. |
| SSH, telnet, Unix or Windows, Remote server has no compiler | Source Package with XS components |
Install package by hand -
- Compile the source package on local machine first (assume of the same architecture)
- 'Tar' up the compiled binaries
- ftp/scp onto the remote server
- Log onto the remote server and unpack the package
- make install on the remote server (or drop the perl .pm files under perl/site/lib, and XS binaries under perl/lib/auto/...)
|
| [reply] [d/l] [select] |
| [reply] |
Hi bradcathey, thanks. ;-) But I would certainly wait a bit longer to see what other more experienced monks think about remote module installation first.
By the way, tachyon (another Australian? :-D) has written an excellent guide on module installation earlier - A Guide to Installing Modules. I recommend you to read it if you haven't.
| [reply] |
I'm surprised no one has voted for
perl -MCPAN -e shell
I don't think this will work on a windows machine though.
| [reply] [d/l] |
CPAN.pm does in fact work in Windows. It seems to me that CPAN.pm will successfully figure out how to open up and install most (if not all) pure perl packages on Win32. For modules that have compilable pieces, however, you will need Visual C++ and the appropriate INCLUDE, LIB, and PATH set up.
Since ActiveState's ppm repository is a little stale, this is a very good way to get modules if you already have a copy of Visual C++. I wish CPAN modules were more compatible with MinGW instead though -- at least that is free :)
| [reply] |
C:\Data\Scripts>perl -mCPAN -e "shell"
C:\Data\Scripts>perl -mCPAN -e "shell"
C:\Data\Scripts>
Ed
| [reply] [d/l] |
The same way you install them locally. | [reply] |