Geoffrey Young <[EMAIL PROTECTED]> writes:
[...]
> ok, attached is a patch that creates $ENV{MOD_PERL_API_VERSION} based
> on some information in mod_perl2.pm.
>
> feedback welcome.
[...nice work!...]
> Index: lib/mod_perl2.pm
> ===================================================================
> --- lib/mod_perl2.pm (revision 157559)
> +++ lib/mod_perl2.pm (working copy)
> @@ -34,6 +34,16 @@
> # $VERSION : "1.099020"
> # int $VERSION : 1.09902
> # $VERSION_TRIPLET: 1.99.20
> +
> + # mod_perl equivalent of httpd module magic number
> + # basically
> + # - bump the major version for binary-incompatible
> + # - bump the minor version for API changes
> + # - if you bump the major version, reset the minor to 0
> + our $API_VERSION_MAJOR = 20050315;
> + our $API_VERSION_MINOR = 0;
> + our $API_VERSION = join '.', $API_VERSION_MAJOR,
> + $API_VERSION_MINOR/100;
> }
>
> $mod_perl::VERSION = $mod_perl2::VERSION;
>
> ---------------------------------------------------------------------
I'm curious why we want to create a "module-magic-number" like the
$API_VERSION you've got here. Does it convey any useful information
beyond what's already in $VERSION?
Hmm, perhaps you are trying to kill two birds with one stone here
(mp1-back-compat and future ABI changes in the httpd 2.x line)?
If so, I think httpd handles ABI changes all by itself, by refusing
to even load ABI-incompatible modules.
As far as CGI.pm is concerned, it doesn't need this level of detail;
it just needs to know which mod_perl module to require. An
"generation" integer would probably suffice for that (or even my old
"exists $ENV{MOD_PERL2}" idea). IOW, here's my +1 for making the
patch set $ENV{MOD_PERL_API_VERSION} = 2 (or MOD_PERL_GENERATION
if you prefer).
--
Joe Schaefer
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]