No, I understand it now. I think the unique value you are after is the path to httpd, including httpd (for those distros moving it to /usr/bin).
Though you are going to have a hard time maintaining several configs in one file. Instead it's probably better to abstract those into separate files, so when you add a new build you don't need to update that file but only install new build. I was thinking to use an approach taken by Inline, when it builds the shared library. It uses an MD5 hash of the C source as a part of the filename. So when the source changes it knows to rebuild it. We could take an MD5 hash of the path to httpd. Then create:
BuildConfig-16128e67ad092a739842b82295820e31.pm BuildConfig-938883be41ad5efc6c9c0d7affdae8e9.pm
where the hash is httpd run through md5? sick.
I like it :)
oh, you understood it as if I was suggesting to run md5sub on the actual binary? No, no, it's a bad idea. It's perfectly OK to rebuild httpd, without rebuilding mod_perl and suddently your hash won't match (if httpd has changed a bit) and you will have no config at all. I've suggested to md5sum the full path to httpd.
for each build (2 builds above).
Next, when Apache::BuildConfig loads, it could optionally get the http argument, calculate its md5 hash and pick the right BuildConfig file above.
We also need:
BuildConfig-default.pm
which will store the first build, in case the path to httpd is not passed (that's what most users will want: "just use my mp2 build data".
what might work is installing both BuildConfig.pm and BuildConfig-$hash.pm. BuildConfig would work as it does presently (containing the most-recent install data) and would be there for back compat (new WriteMakefile vs old mod_perl).
+1
The problem is that MD5 modules aren't in the core.
they are in 5.8.0. not sure about 5.6.x. but I thought we made the decision to move to 5.8.0 once 5.8.1 came out. I can't remember, though.
since it's a maintainer feature we should make this requirement transparent to the normal user (i.e. do this extra work only for MP_MAINTAINER=1)
may be keeping Apache::BuildConfig as it is now, but instrument it to optionally check for these special files, which will be useful for developers.
optional both at mod_perl build time and an 3rd party module build time? I'd like to think that we can make this work so that mod_perl does the right thing - if mod_perl was built with the md5 versioning, then WriteMakefile does the right thing (or as close as we can get).
You forget that you need to pass the locaion of httpd so it'll choose the right md5sum. Otherwise it's a chiken and an egg problem.
Users should have an exact same behavior as it is now. Only if the special mode is used, and a path to httpd is passed and there is a matching md5sum, then use the other config.
how about MP_VERSIONED_BUILD=1 for the mod_perl end?
+0. I'd stick to MP_MAINTAINER=1 and only add new features if we really have a need for it. So far I don't see normal users installing 2.1 on their machines along with 2.0. We can always add it later if the need arises.
__________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
