Subject: | Imager::File::GIF are hidden from PAR |
PAR uses Module::ScanDeps to find all dependencies and zip them up in a
par file. M::SD uses crude static analysis to find these dependencies.
Imager::File::GIF, ::JPEG, ::PNG are automagically loaded only when needed.
However, the following bit of code, when added to Imager.pm, will make
the sub-modules visible to Module::ScanDeps. They are each wrapped in
eval {} because we don't care if they can be loaded or not.
if( $INC{ 'Module/ScanDeps.pm' } ) {
eval { require Imager::File::GIF };
eval { require Imager::File::JPEG };
eval { require Imager::File::PNG };
eval { require Imager::File::SGI };
eval { require Imager::File::TIFF };
}
Confirm with:
scandeps.pl Imager.pm
Note that scandeps.pl does static analysis. So the
$INC{'Module/ScanDeps.pm'} should (nearly) always be false.