> > What would happen if such a base option (btw how do you call it when
> > other options depend on it?) may not be required if it had a default
> > value? (Or enabled/switched on by default like "flag on")
> 
> I see in dependant_option.h_skel which condition is needed to
> modify/extend:
> But I don't know how. (It was a long time ago when I made changes to the
> gengetopt source...)

Well I'm getting enjoy it:) Here is the modified version of the skeleton. 
UNfortunately I haven't time to propagate all the necessary changes in the 
source tree, so if any help and contribution is very appreciated.

if (args_info->@[EMAIL PROTECTED]
    && !(args_info->@[EMAIL PROTECTED]
@if@ dep_option_is_flag  @then@
        || args_info->@[EMAIL PROTECTED]
@elseif dep_option_has arg @then@
        || args_info->@[EMAIL PROTECTED]
@endif@
        ))

    ))
  {
    fprintf (stderr, "%s: @option_descr@ option depends on option 
'@dep_option_descr@'%s\n", @package_var_name@, (additional_error ? 
additional_error : ""));
    error = 1;
  }


_______________________________________________
Help-gengetopt mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-gengetopt

Reply via email to