Hello Monks,
I'm trying to understand how PAR works.
First of all, I'm expecting it creates an executable file, with all dependencies resolved, but it seems it isn't so.
So I tried to do a simple code, like this one, just to test how PAR works:
use strict;
use warnings;
use Switch;
my $mode='network';
print "\n\n";
switch ($mode) {
case ('alternative') {
print 'alternative';
}
case 'network' {
print 'network';
}
else { # local value or not specified
print 'default';
}
}
print "\n\n";
And I'm trying to have an executable file, with all dependencies ("use switch") solved.
I'm tring:
pp -o hello.exe hello.pl
But the switch is not in the executable libraries.
En fact I have:
Can't locate deprecate.pm in @INC (@INC contains: CODE(0x140
lf\IMPOST~1\Temp\par-wolf\cache-a6a07c4c8edef3f3831fbe053938
C:\DOCUME~1\wolf\IMPOST~1\Temp\par-wolf\cache-a6a07c4c8edef
af3a550\inc CODE(0x124b304) CODE(0x124b604)) at if.pm line 1
BEGIN failed--compilation aborted at Switch.pm line 7.
Compilation failed in require at script/ciao.pl line 3.
BEGIN failed--compilation aborted at script/ciao.pl line 3.
I have also read the documentation and tried -B option, but without result.
How can I build an executable file with deprecate.pm (or switch.pm) builded in it?
Thank you
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.