2 +++ configure.in 2006/09/01 12:30:00
5 AC_CONFIG_HEADER(src/config.h)
7 -dnl DPKG_CACHED_TRY_COMPILE(<description>,<cachevar>,<include>,<program>,<ifyes>,<ifno>)
8 -define([DPKG_CACHED_TRY_COMPILE],[
9 +AC_DEFUN([DPKG_CACHED_TRY_COMPILE],[
12 AC_TRY_COMPILE([$3],[$4],[$2=yes],[$2=no])
20 + * Copyright (C) 1997-2000 Ian Jackson <ian@davenant.greenend.org.uk>
22 + * It is part of adns, which is
23 + * Copyright (C) 1997-2000 Ian Jackson <ian@davenant.greenend.org.uk>
24 + * Copyright (C) 1999-2000 Tony Finch <dot@dotat.at>
26 + * This program is free software; you can redistribute it and/or modify
27 + * it under the terms of the GNU General Public License as published by
28 + * the Free Software Foundation; either version 2, or (at your option)
29 + * any later version.
31 + * This program is distributed in the hope that it will be useful,
32 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
33 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
34 + * GNU General Public License for more details.
36 + * You should have received a copy of the GNU General Public License
37 + * along with this program; if not, write to the Free Software Foundation,
38 + * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
42 +AH_TEMPLATE([HAVE_INLINE],
43 + [Define if inline functions a la GCC are available.])
44 +AH_TEMPLATE([HAVE_GNUC25_ATTRIB],
45 + [Define if function attributes a la GCC 2.5 and higher are available.])
46 +AH_TEMPLATE([HAVE_GNUC25_CONST],
47 + [Define if function attributes a la GCC 2.5 and higher are available.])
48 +AH_TEMPLATE([HAVE_GNUC25_NORETURN],
49 + [Define if nonreturning functions a la GCC 2.5 and higher are available.])
50 +AH_TEMPLATE([HAVE_GNUC25_PRINTFFORMAT],
51 + [Define if printf-format argument lists a la GCC are available.])
52 +AH_TEMPLATE([HAVEUSE_RPCTYPES_H],
53 + [Define if we want to include rpc/types.h. Crap BSDs put INADDR_LOOPBACK there.])
56 +/* Use the definitions: */
63 +#include <sys/poll.h>
66 +struct pollfd { int fd; short events; short revents; };
72 +/* GNU C attributes. */
74 +#ifdef HAVE_GNUC25_ATTRIB
75 +#define FUNCATTR(x) __attribute__(x)
81 +/* GNU C printf formats, or null. */
83 +#ifdef HAVE_GNUC25_PRINTFFORMAT
84 +#define ATTRPRINTF(si,tc) format(printf,si,tc)
86 +#define ATTRPRINTF(si,tc)
90 +#define PRINTFFORMAT(si,tc) FUNCATTR((ATTRPRINTF(si,tc)))
93 +/* GNU C nonreturning functions, or null. */
95 +#ifdef HAVE_GNUC25_NORETURN
96 +#define ATTRNORETURN noreturn
101 +#ifndef NONRETURNING
102 +#define NONRETURNING FUNCATTR((ATTRNORETURN))
105 +/* Combination of both the above. */
106 +#ifndef NONRETURNPRINTFFORMAT
107 +#define NONRETURNPRINTFFORMAT(si,tc) FUNCATTR((ATTRPRINTF(si,tc),ATTRNORETURN))
110 +/* GNU C constant functions, or null. */
112 +#ifdef HAVE_GNUC25_CONST
113 +#define ATTRCONST const
119 +#define CONSTANT FUNCATTR((ATTRCONST))
122 +#ifdef HAVEUSE_RPCTYPES_H
123 +#include <rpc/types.h>
128 ADNS_C_GETFUNC(socket,socket)
129 ADNS_C_GETFUNC(inet_ntoa,nsl)