Hi Dmitry; I was looking over your patches for dealing with various problems handling command line issues such as not handling -e properly and appending to pattern-specific variables.
These are good patches but I'm getting more and more uneasy with the complexity around MAKEFLAGS and I wonder if there's a way to make it better. As an example, for the -e change I experimented with simply going through the variable database and switching the origin from o_env to o_env_override or vice versa. As far as I can tell there's no situation in which any variable should be o_env if -e was set, or o_env_override if -e was not set, so we don't need to worry about preserving a previous state. This works great EXCEPT that if we disable the -e option via MAKEFLAGS, it doesn't actually change the global setting back again; a switch only "enables" but the _lack_ of a switch never "disables". In order to make this work we'd need to have a way to reset the global settings to their default values. This means we'd need to reapply all the settings. So I wondered if maybe it wouldn't be worthwhile to change the handling of MAKEFLAGS so the value of MAKEFLAGS was considered the "source of truth" as to what flags were set, and every time we re-parsed it we would first reset all the global state settings back to their defaults then re-parse MAKEFLAGS as if it were the first time. Does this make sense? Have I overlooked any issues here?