configure: check for program_invocation_name
For portabiliy, check for program_invocation_name during configure and define HAVE_PROGRAM_INVOCATION_NAME accordingly. Use of this symbol is now enclosed with the appropriate #ifdef block. The symbol program_invocation_name is only used for error message handling using error(), so it's safe to omit this if it is not available.
This commit is contained in:
4
pwdx.c
4
pwdx.c
@@ -74,7 +74,9 @@ int main(int argc, char *argv[])
|
||||
{NULL, 0, 0, 0}
|
||||
};
|
||||
|
||||
program_invocation_name = program_invocation_short_name;
|
||||
#ifdef HAVE_PROGRAM_INVOCATION_NAME
|
||||
program_invocation_name = program_invocation_short_name;
|
||||
#endif
|
||||
setlocale (LC_ALL, "");
|
||||
bindtextdomain(PACKAGE, LOCALEDIR);
|
||||
textdomain(PACKAGE);
|
||||
|
Reference in New Issue
Block a user