The module with_fallback.pm was kind of clunky and required a transfer
module. This change replaces if with a much more generic pragma type
module, which simply appends given directories to @INC (as opposed to
the 'lib' pragma, which prepends the directories to @INC).
This also supports having a file MODULES.txt with sub-directories to
modules. This ensures that we don't have to spray individual module
paths throughout our perl code, but can have them collected in one
place.
(do note that there is a 'fallback' module on CPAN. However, it isn't
part of the core perl, and it has no support the any MODULES.txt kind
of construct)
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/9826)
On VMS, periods in directory names weren't allowed. To counter that,
unpackers such as VMSTAR convert periods in directory names to
underscores. We need to count that in and add an alternative library
path for Text::Template.
Reviewed-by: Rich Salz <rsalz@openssl.org>
This is an important move if scripts want to refer to the loaded
module without having perl think it needs to be loaded (again).
Reviewed-by: Rich Salz <rsalz@openssl.org>
Because we're using Text::Template and we know it's a non core Perl
module, we choose to bundle it into our source, for convenience.
external/perl/Downloaded.txt document what modules we choose to bundle
this way and exactly where we downloaded it from.
With this changes comes the transfer module for with_fallback.
Reviewed-by: Rich Salz <rsalz@openssl.org>