gri6507 has asked for the wisdom of the Perl Monks concerning the following question:
I just ran into a path problem with PAR. I have a program which is delivered as a PAR executable. My program refers to some additional file which is packaged up into the executable with pp --output=executable --addfile=myfile myprog.pl. When my program runs, I need to run that additional file (myfile) via qx(). However, before I can do that, I need to chmod that file, and in order to do that, I need to get the full path to this file. Is there a PAR variable or method which will let me get the path to my file?
Many thanks, Hoping for a prompt response, because this is scheduled to ship in the next few hours :-)
Update I think I found that $ENV{PAR_TEMP} contains the path to par cache. However, I now seem to have an entirely different, albeit very strange problem. It seems that if I run my par'ed up program from the directory where the file resides, I get one cache directory, and if I run my program from any other directory (my program is in my $PATH) then I get a different cache directory. Even stranger is that my additional file is only in the first cache directory and not the second! Is this a bug in PAR or am I missing something?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: PAR cache path
by rinceWind (Monsignor) on Feb 22, 2006 at 15:45 UTC |