build.info: Introduce special syntax for dependencies on script modules
authorRichard Levitte <levitte@openssl.org>
Fri, 2 Jun 2023 12:32:07 +0000 (14:32 +0200)
committerRichard Levitte <levitte@openssl.org>
Thu, 8 Jun 2023 05:53:10 +0000 (07:53 +0200)
commitb684ee2ce4bbf2c877d2cdc39e095d52ea3fe2a3
treeffac760438fbbe091d921e0637029b43b78d8715
parentb8fa5be5506e43b405c9a3ecc3d65c77044777be
build.info: Introduce special syntax for dependencies on script modules

The DEPEND statement, when applied on files generated with GENERATE, may
be used to specify script modules that the template to be generated from
depends on.  In short, this sort of depend:

    DEPEND[generated]=util/perl/OpenSSL/something.pm

... would generate a perl run that has the inclusion directory
'util/perl/OpenSSL' and 'something' as the module to be loaded.  However,
the package name for this module is 'OpenSSL::something', so to load it the
way it's expected, the inclusion directory should be 'util/perl', and the
module to be loaded should be specified as 'OpenSSL/something' (to be
massaged into a proper module name by the build file template).

To allow this, we introduce a file syntax, where a single '|' is used as a
directory separator, to delineate what part should be used as the inclustion
directory, and which part the module name to be loaded should be derived
from:

    DEPEND[generated]=util/perl|OpenSSL/something.pm

Fixes #21112

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/21117)
Configurations/descrip.mms.tmpl
Configurations/unix-Makefile.tmpl
Configurations/windows-makefile.tmpl
Configure
build.info
doc/internal/man7/build.info.pod