It seems -d is effected as well.  I may be able to get away without -d, but
in my previous testing on NT 4 it caused problems.  Also I noticed some
loping problems, where the exec'ed pp built program would run over and over
again, not sure what caused them, but deleting the cache seemed to help.

Autrijus I kind of need -d, do you have any ideas?

E:\test>pp -d -o bar.exe bar.pl

E:\test>pp -d -o foo.exe foo.pl

E:\1LinkMedia>bar
BAR
Permission denied at C:/Perl/site/lib/PAR/Heavy.pm line 127.
Compilation failed in require at script/bar.pl line 2.
BEGIN failed--compilation aborted at script/bar.pl line 2.
exit code= 13

E:\test>pp -o bar.exe bar.pl

E:\test>pp -o foo.exe foo.pl

E:\1LinkMedia>bar
BAR
FOO
exit code= 0

E:\test>pp -V
Perl Packager, version 0.05 (PAR version 0.79_97)
Copyright 2002, 2003, 2004 by Autrijus Tang <[EMAIL PROTECTED]>

Neither this program nor the associated "parl" program impose any
licensing restrictions on files generated by their execution, in
accordance with the 8th article of the Artistic License:

    "Aggregation of this Package with a commercial distribution is
    always permitted provided that the use of this Package is embedded;
    that is, when no overt attempt is made to make this Package's
    interfaces visible to the end user of the commercial distribution.
    Such use shall not be construed as a distribution of this Package."

Therefore, you are absolutely free to place any license on the resulting
executable, as long as the packed 3rd-party libraries are also available
under the Artistic License.

This program is free software; you can redistribute it and/or modify it
under the same terms as Perl itself.  There is NO warranty; not even for
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-----Original Message-----
From: Alan Stewart [mailto:[EMAIL PROTECTED]
Sent: Monday, February 16, 2004 10:27 PM
To: Jesse Schoch; [EMAIL PROTECTED]
Subject: Re: exec problems


On 16 Feb 2004 at 21:47, Jesse Schoch wrote:

> Here is a simple test.  Let me know if anyone gets the same results.
>
>
> E:\test>bar
> BAR
> Permission denied at -e line 640.
> exit code= 13
>
> E:\test>perl bar.pl
> BAR
> FOO
> exit code= 0
>
> _____________bar.pl___________________
>
> #!/usr/bin/perl
> use Win32::Process;
> print "BAR\n";
> Win32::Process::Create($ProcessObj,
>                                 "e:/test/foo.exe",
>                                 "foo",
>                                 0,
>                                 NORMAL_PRIORITY_CLASS,
>                                 ".")|| die &Error;
> $ProcessObj->Wait(INFINITE )|| die &Error;
> $ProcessObj->GetExitCode($exitcode)|| die &Error;
> print "exit code= $exitcode\n";
> sub Error
>         {
>         print Win32::FormatMessage( Win32::GetLastError() );
>         }
>
>
> ____________foo.pl____________________
>
> #!/usr/bin/perl -w
>
> print "FOO\n";
>
> ____________build_____________________
>
> pp -C -o bar.exe bar.pl
>

You don't say how foo.exe was built, but I get the same error if either
bar.exe or
foo.exe has the -C option. If neither one was built with -C, it works for
me.

Alan Stewart



Reply via email to