-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
option precedence needs to be reviewed #3
Comments
I would suggest this variant on mst's order:
|
Two big problems with all of this:
Thus, I think it's cleaner to think of two phases: configuration (Build.PL) and actions; within each we look to what options are least-specific to most-specific. For configuration: .modulebuildrc (both * and Build_PL, probably in that order from least to most specific) and PERL_MB_OPT and the command line provide inputs that determine a set of configuration outputs that are persisted to disk. For actions: the configuration outputs are the least-specific starting point, modified by action-specific options in .modulebuildrc and the action command line arguments. Taking PERL_MB_OPT out of the action phase avoids having its high-precedence intended for the configuration phase blead into the action phase where configuration results have lowest precedence. |
This is an issue, though I'm tempted to call both EBKAC.
Same can be said of Build.PL arguments. This thing should never have become as complicated as it is now.
I think you're thinking about this too much in terms of Module::Build's implementation details. In particular, M::B is currently not separating reading the input from parsing it (see a pattern?), which makes the two-stage process a mess. This approach doesn't seem cleaner to think of at all to me. |
On Thu, Feb 9, 2012 at 7:14 PM, Leon Timmermans
You may be right. However, it's the defacto standard. I think what I I'm open to something better, or even, potentially, fixing the spec if That shouldn't break modern local::lib's that use PERL_MB_OPT as long All this sounds like fodder for Paris and copious alcohol. -- David |
Thinking about it, we're missing item in the precedence list: the Module::Build constructor. Fortunately, this is the lowest precedence of them all, which is the only sensible option IMHO. |
Actually, I wouldn't mind deprecating .modulebuildrc at all. It's a lot of head-acke though no-one really uses it anymore. I don't think it really needs a replacement either, an external config file doesn't fit in well with how the rest of the toolchain works IMHO. |
c.f. discussion in 886abd6
tl;dr: precedent of options set by .moduledefaultrc, PERL_MB_OPT and the command line should be reviewed. It should most likely be as follows:
The text was updated successfully, but these errors were encountered: