bug-gnulib
[Top][All Lists]
Advanced

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

Re: use of PATH_MAX in *.m4 files


From: Jim Meyering
Subject: Re: use of PATH_MAX in *.m4 files
Date: Thu, 22 Sep 2011 11:30:53 +0200

Bruno Haible wrote:
> Hi Jim,
>
> Here's another prososed patch
>
> On MSVC, I got a link error because save-cwd.c was compiled to invoke the
> chdir_long() function, but lib/chdir-long.c was not compiled.
>
> The reason is that while save-cwd.c uses pathmax.h to define PATH_MAX when
> it makes sense and bases its decisions on the 'pathmax' module, the 3 .m4 
> files
>   m4/chdir-long.m4
>   m4/getcwd-abort-bug.m4
>   m4/getcwd-path-max.m4
> use their own way of getting PATH_MAX. On MSVC, it thus happens that
> m4/chdir-long.m4 considers PATH_MAX to be undefined, while save-cwd.c then
> considers it as defined.
>
> Here's a patch that moves all logic regarding PATH_MAX to the 'pathmax' module
> and the m4/pathmax.m4 file.
>
>
> 2011-09-21  Bruno Haible  <address@hidden>
>
>       Consolidate all uses of PATH_MAX in *.m4 files.
>       * m4/pathmax.m4 (gl_PATHMAX_SNIPPET, gl_PATHMAX_SNIPPET_PREREQ): New 
> macros.
>       * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Use gl_PATHMAX_SNIPPET_PREREQ 
> and
>       gl_PATHMAX_SNIPPET.
>       * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Likewise.
>       * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
>       * modules/chdir-long (Files): Add m4/pathmax.m4.
>       * modules/getcwd (Files): Likewise.

Hi Bruno,

That sounds like a fine improvement.
It looks fine, too.
Thank you.



reply via email to

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