Hi Philippe
Thanks very much for this pointer; that's a great reference! I learned a
lot by reading it, and read the part about addfile. I'll admit that I'm
worried about using this option. First, it's seems that the files end up in
different places, depending on whether the --clean option is used or not.
Second, I'm worried that a Perl program that is distributed inside PAR needs
to be specially modified for this purpose.
I want my main Perl program to be able to run both outside of PAR and inside
it, without modification. I don't want to have to change my Perl program to
add machinery like $ENV{PAR_TEMP}."/inc/" and
$PAR::LibCache{$ENV{PAR_PROGNAME}}.
Is there some way to put my additional files inside PAR such that my .pl
program can just read them using a normal directory structure access?
Thanks!
tl
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of Philippe Schaffnit
Sent: Friday, July 01, 2005 6:15 AM
To: [EMAIL PROTECTED]
Subject: Re: Question on --addfile
Hi!
I'm also a great fan of PAR, and use quite extensively include-d files:
I found "contrib/docs/where_is_it.txt" a must read!
http://svn.openfoundry.org/par/trunk/contrib/docs/where_is_it.txt
Good luck!
Philippe
[EMAIL PROTECTED] wrote:
>
> Hi
>
> Thanks very much for providing PAR! It is truly a blessing to my current
> project.
>
> I want to include several files in my pp-created .exe file. These files
are
> form files, used by the Perl GUI facility, Prima, at run-time to display
> forms. I specify '--addfile=welcome.fm' on the pp command line to add my
> form file. pp runs without error, and creates the .exe file. When I open
> the .exe file with WinZip, I can see that 'welcome.fm' is, indeed, part of
> the exe file.
>
> But, when I run the exe on another system, I get the error:
>
> Error in setup resource: Cannot open welcome.fm:No such file or
> directory
>
> I took a look in \Documents and Settings\Administrator\Local
>
Settings\Temp\1\par-Administrator\cache-6e56d2facfadeb68ecdf213f53f56f12647b
> 67a9\ on the target system, as that is where the exe disgorged itself when
> it began running. I see this directory tree:
>
> inc - also includes my 'welcome.fm'
> lib
> script - my main .pl, which calls 'welcome.fm'
> shlib
>
> I think the problem occurs because my main pl expects to find 'welcome.fm'
> in the same directory as itself, but pp puts the two files (the .pl and
the
> welcome.fm) in different directories.
>
> What is the best way to correct this?
>
> Thanks!
> tl
>
> Terry Lemons
> CLARiiON Applications Integration Engineering
> EMC²
> where information lives
> 4400 Computer Drive, MS D239
> Westboro MA 01580
> Phone: 508 898 7312
> Email: [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>