bug-gnulib
[Top][All Lists]
Advanced

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

Re: provide inet_?to? declarations in arpa_inet.h


From: Bruno Haible
Subject: Re: provide inet_?to? declarations in arpa_inet.h
Date: Wed, 30 Apr 2008 01:32:07 +0200
User-agent: KMail/1.5.4

Simon Josefsson wrote:
> diff --git a/m4/arpa_inet_h.m4 b/m4/arpa_inet_h.m4
> index 8f530c5..baddf0d 100644
> --- a/m4/arpa_inet_h.m4
> +++ b/m4/arpa_inet_h.m4
> @@ -32,4 +32,7 @@ AC_DEFUN([gl_ARPA_INET_H_DEFAULTS],
>  [
>    GNULIB_INET_NTOP=0;     AC_SUBST([GNULIB_INET_NTOP])
>    GNULIB_INET_PTON=0;     AC_SUBST([GNULIB_INET_PTON])
> +  dnl Assume proper GNU behavior unless another module says otherwise.
> +  HAVE_DECL_INET_NTOP=1;  AC_SUBST([HAVE_DECL_INET_NTOP])
> +  HAVE_DECL_INET_PTON=1;  AC_SUBST([HAVE_DECL_INET_PTON])
>  ])
> diff --git a/modules/arpa_inet b/modules/arpa_inet
> index e5934ac..8c5f3f9 100644
> --- a/modules/arpa_inet
> +++ b/modules/arpa_inet
> @@ -24,6 +24,8 @@ arpa/inet.h:
>         sed \
>             -e 's|@''GNULIB_INET_NTOP''@|$(GNULIB_INET_NTOP)|g' \
>             -e 's|@''GNULIB_INET_PTON''@|$(GNULIB_INET_PTON)|g' \
> +           -e 's|@''HAVE_DECL_INET_NTOP''@|$(HAVE_DECL_INET_NTOP)|g' \
> +           -e 's|@''HAVE_DECL_INET_PTON''@|$(HAVE_DECL_INET_PTON)|g' \
>             < $(srcdir)/arpa_inet.in.h; \
>       } > address@hidden
>       mv address@hidden $@

This cannot be correct/complete. You are initializing the two variables
to 1, never setting them to 0, and then substituting them. You also need to
set them to 0 somewhere, conditionally.

Bruno





reply via email to

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