Glenn Linderman wrote:
Hi,
I have a pp question. When I build a standalone .exe on a machine that has all the needed modules, they all get bundled correctly, and everything works. But if a needed module is not installed on the machine when pp is run to create the .exe, it seems that the module is silently omitted from the .exe. And then the .exe fails when executed, reporting the missing module at that point in time.
I expect PAR to only find the modules that Perl does. However, I wouldn't mind some warnings about missing modules. There are situations where one would check for a particular module in an eval block and then exit gracefully. This is especially useful for "plugin" style modules. PAR should definitely not fail if it can't find a module, but a warning would be very helpful.
Right. I don't expect PAR to find it, when it isn't there. And I wouldn't mind a switch to enable such behavior; or a switch to make such a warning fatal; or both. Or a switch to turn off the warnings, if they are on by default.
The case I have is very clear, there are no blocks or conditionals, the "use" will definitely be executed... and yet when the module is missing, there is no warning and no error, until you attempt to run the .exe just built.
I understand that "use" in an "eval", that pp wouldn't see those, or wouldn't want to do the flow analysis to try to figure out if they are actually used or not... or "require" in a conditional might not get executed... the -c and -x options are good for some of those cases... but I didn't expect to have to use them for this case.
-- Glenn -- http://nevcal.com/ =========================== The best part about procrastination is that you are never bored, because you have all kinds of things that you should be doing.
