[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
autoconf 2.56: <resolv.h> detection
From: |
Dimitri PAPADOPOULOS-ORFANOS |
Subject: |
autoconf 2.56: <resolv.h> detection |
Date: |
Tue, 19 Nov 2002 11:56:52 +0100 (MET) |
Hi,
There's a problem with <resolv.h> detection on Solaris and
most probably on other UNIX systems.
I can reproduce the bug with autoconf 2.54 and autoconf 2.56.
It hit me while trying to build libxml2 on Solaris:
[...]
configure: WARNING: resolv.h: present but cannot be compiled
configure: WARNING: resolv.h: check for missing prerequisite headers?
configure: WARNING: resolv.h: proceeding with the preprocessor's result
configure: WARNING: ## ------------------------------------ ##
configure: WARNING: ## Report this to address@hidden ##
configure: WARNING: ## ------------------------------------ ##
[...]
See also:
http://bugzilla.gnome.org/show_bug.cgi?id=98880
And indeed configure.in contains:
AC_CHECK_HEADERS(stdlib.h sys/socket.h netinet/in.h arpa/inet.h)
AC_CHECK_HEADERS(sys/timeb.h signal.h arpa/nameser.h resolv.h)
This used to work with autoconf 2.13 but doesn't work with
autoconf 2.54 and better. The problem is that the above
macros expand to a test for <resolv.h> that does not include
<netinet/in.h> and <arpa/nameser.h>. However most UNIX systems
need both <netinet/in.h> and <arpa/nameser.h> to be included
before <resolv.h>. See for example:
http://www.sas.com/service/library/onlinedoc/sasc/doc700/html/lr2/zr2bsdhf.htm
<resolv.h>
This header file contains global definitions for the
resolver. [...] You must include the <sys/types.h>,
<netinet/in.h>, and <arpa/nameser.h> header files
before this header file.
Best Regards,
--
Dimitri
- autoconf 2.56: <resolv.h> detection,
Dimitri PAPADOPOULOS-ORFANOS <=