site logo  PerlSetup

HomePage | Categories |* BLOG *| RecentChanges | RecentlyCommented | Login/Register

Perl Setup


I found that I needed to use perl standalone for some configuration files, so I decided to use Paul Smedley's 5.8.8 port. NOTE: A new build should be available sometime after 29 April 2007. Paul has a package in WarpIn format that requires Knut's pathrewriters package which in turn requires the klibc package. Both these are available at Netlabs, look for klibccfg.wpi and libc-0_6_1-csd1.wpi.

NOTE: I am installing perl to my D drive

Ensure both klibc and pathrewriters are installed. Next install the perl package. You should be able to open the "kLIBC Pathrewriters" located in "System Setup" and see something like this:

image
I use the following cmd file to setup the perl environment, but it could actually be placed in config.sys:


perlenv.cmd
@ECHO OFF

set PERLPATH=d:\perl

set PATH=%PATH%;%PERLPATH%\bin;
set BEGINLIBPATH=%PERLPATH%\bin
set PERL_SH_DIR=%PERLPATH%



Next, I grabbed testperl.cmd and sh.exe from the from the 5.8.0 distro which can be found on hobbes. I used the sh.exe from this archive because the script expected this version and this is why the PERL_SH_DIR is in the above cmd file. Also, here is the 5.8.0 inf file just for reference.

The test passed, now to do something with it.

FYI: here is the output from testperl.cmd -

====================================
Testing perl...  Getting version...
====================================

This is perl, v5.8.8 built for os2

Copyright 1987-2006, Larry Wall


OS/2 port Copyright (c) 1990, 1991, Raymond Chen, Kai Uwe Rommel
Version 5 port Copyright (c) 1994-2002, Andreas Kaiser, Ilya Zakharevich

Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 5 source kit.

Complete documentation for Perl, including FAQ lists, should be found on
this system using "man perl" or "perldoc perl".  If you have access to the
Internet, point your browser at http://www.perl.org/, the Perl Home Page.

====================================
We checked that Perl can be loaded.  Apparently, your PATH and LIBPATH
are set to reasonable values.  From now on the tests are coded in Perl.
Press <ENTER>:
====================================
The next step is to check that you installed shell in a location perl can
find, so that you can start external programs.
I could find your shell, its version is '@(#)PD KSH v5.2.7 96/06/04'
Press <ENTER>:
====================================
Ouph, the most frequent problem is behind...  Now testing Perl library search.
Found Perl library.  Fine...
Press <ENTER>:
====================================
The following entries in '/perl/lib/5.8.8/os2/Config.pm'
contain path settings which look suspicious:
 aphostname => 'u:/bin/hostname'
 gnupatch => 'U:/MOZTOOLS/patch.exe'
 libpth => 'U:/usr/lib U:/usr/lib/gcc-lib/i386-pc-os2-emx/3.3.5 u:/extras/lib u:/dev/qt/trunk/lib u:/openldap/lib'
 perl5 => 'u:/perl/bin/perl'
 perlpath => 'u:/perl/bin/perl'
 sysman => 'e:/usr/man/man1'
 timeincl => 'U:/USR/include/sys/time.h '
 Press <ENTER>:
====================================
Apparently you edited '/perl/lib/5.8.8/Net/Config.pm',
so I expect you know what you did.  OK...
Tests finished. Press <ENTER>:

There are no comments on this page. [Add comment]

Valid XHTML 1.0 Transitional :: Valid CSS :: Powered by Wikka Wakka Wiki 1.1.6.7
Page was generated in 0.0778 seconds