Re: How to have perl on a CD (windows)
- From: "Veli-Pekka Tätilä" <vtatila@xxxxxxxxxxxxxxxxxxxx>
- Date: Fri, 2 Sep 2005 08:33:59 +0300
News KF wrote:
> I want to have a perl-application, that could reside on a CD or USB
> memory stick and could run on any windows computer.
Hi,
I think the only difference between the two is that CD's are read-only
usually, so you'd need to have the program write its files and extract any
temporary modules to some writable location. I've been succesfully using two
solutions.
Firstly, Tiny Perl is able to run Perl programs, say from a floppy, with
know needd to run a Windows installer first:
http://tinyperl.sourceforge.net/
There are not too many libraries but you can usually copy any of the more
special one's from an active state distro. The procedure is finding the lib
pm files either under site/lib or lib. You should also copy any related DLLs
under the .\auto directory. As moduiles may require each other, you can
either try running the module manually adding stuff until it works or find
out the dependencies with a CPAN util called scandeps..
Example hash::Util
Checking the lib.zip file under Tiny Perl reveals that no hash modules have
been installed. But Active State has got the files. Most of the stuff you
add with ppm goes under site\lib but Hash is core enough to be in the lib
directory directly, that is:
C:\Perl\lib\Hash
It only contains the file Util.pm that you'll need but you need to maintain
the directory hierarchy so grab the whole hash directory. As to where it
should be copied, regardless of whether the file came from site\lib or lib,
it goes in a directory called lib under Tiny Perl.
Looking for DLLs in the auto directory at:
C:\Perl\lib\auto
There's no sub-dir called hash so you should be done now provided that
Hash::Util doesn't depend on anything that Tiny perl doesn't already have.
The other app I've been using is called perl2exe and has a 30-day trial
version:
http://www.indigostar.com/perl2exe.htm
It is able to resolve all dependencies and link in all ordinarily named pm
and dll files for you based on the source code. It will create one, big,
nice self-contained exe file which extracts the libraries in some readable
temporary directory when you run it. It seems to be one of the Windows temp
directories by default.
Hope this can be of help,
--
With kind regards Veli-Pekka Tätilä (vtatila@xxxxxxxxxxxxxxxxxxxx)
Accessibility, game music, synthesizers and programming:
http://www.student.oulu.fi/~vtatila/
.
- References:
- How to have perl on a CD (windows)
- From: News KF
- How to have perl on a CD (windows)
- Prev by Date: Re: Access Log reports -- Top entry and Exit pages
- Next by Date: Re: problems with unpack() in Linux, Perl v5.8.0
- Previous by thread: Re: How to have perl on a CD (windows)
- Next by thread: Perl Cookies
- Index(es):
Relevant Pages
|