bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: use of program_name


From: Karl Berry
Subject: Re: use of program_name
Date: Thu, 5 Jan 2006 16:12:36 -0600

    If we put a similar declaration in error.c, it would cause two
    different definitions of program_name, and some non-Unix linkers
    reject this.  (The C Standard allows them to reject it.)

Is it a problem in practice, ie, what are these non-Unix linkers?

How about defining it in error.c with an #ifdef:
#ifdef GNULIB_DO_NOT_DECLARE_PROGRAM_NAME
char *program_name;
#endif

Then programs could define the macro if need be.  Perhaps it could be
autoconfed.

    This will require revamping pretty much everybody that uses
    program_name, but I think it's worth the pain.  What do others
    think?

Sounds like an uphill battle to me.

Are you thinking that set_program_name will set something other than
program_name?  Because of course existing code has to continue to work
... not too clear on how old/new code will mix in this case ...




reply via email to

[Prev in Thread] Current Thread [Next in Thread]