[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug-gnulib] Re: Argp compilation failure with _GNU_SOURCE and optimizat
[Bug-gnulib] Re: Argp compilation failure with _GNU_SOURCE and optimization
Sun, 12 Sep 2004 14:32:34 +0200
Gnus/5.110003 (No Gnus v0.3) XEmacs/21.4 (Security Through Obscurity, linux)
"Soeren D. Schulze" <address@hidden> writes:
> In context, I use the Argp gnulib module in my project and call gl_ARGP
> in configure.ac. I had been surprised about m4/argp.m4 anyway, because
> it does not even check if Argp is present.
The checks for argp.h and argp_parse was removed recently. It seems
the argp gnulib module will always be built, now, even if the system
has argp (i.e., glibc systems).
> mempcpy.h itself contains a check for HAVE_MEMPCPY and strndup.h checks
> for HAVE_STRNDUP, but neither gl_FUNC_MEMPCPY nor gl_FUNC_STRNDUP are
> required by gl_ARGP.
The argp module depend on those modules (see modules/argp), so those
macros should be invoked. Aren't they for you? mempcpy nor strndup
aren't needed by gl_ARGP, so requiring them is probably overkill.
OTOH, it might make things more clear.
> Checking if `mempcpy' is defined as a macro is inappropriate because
> this is implementation-specific. Moreover, you forgot strndup.h.
> Better include something like AC_REQUIRE([gl_FUNC_MEMPCPY]) and
> AC_REQUIRE([gl_FUNC_STRNDUP]) in argp.m4. (You know better how to do
> this exactly, probably.)
> Then HAVE_MEMPCPY in mempcpy.h and HAVE_STRNDUP in strndup.h will work.
Again, gl_FUNC_STRNDUP and gl_FUNC_MEMPCPY should both be invoked if
you use 'gnulib-tool' to set up the module in your project. If you
don't, you have to mimic what it does.
Sorry if I misunderstood something, I didn't follow this thread from