From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12926 invoked from network); 19 Feb 2009 10:26:29 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=AWL,BAYES_00,URIBL_SBL autolearn=no version=3.2.5 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 19 Feb 2009 10:26:29 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 27499 invoked from network); 19 Feb 2009 10:26:26 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 19 Feb 2009 10:26:26 -0000 Received: (qmail 15244 invoked by alias); 19 Feb 2009 10:26:21 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 26584 Received: (qmail 15233 invoked from network); 19 Feb 2009 10:26:21 -0000 Received: from bifrost.dotsrc.org (130.225.254.106) by sunsite.dk with SMTP; 19 Feb 2009 10:26:21 -0000 Received: from cluster-d.mailcontrol.com (cluster-d.mailcontrol.com [85.115.60.190]) by bifrost.dotsrc.org (Postfix) with ESMTPS id B06A38028ACA for ; Thu, 19 Feb 2009 11:26:14 +0100 (CET) Received: from dalamsexb02.AMERICAS.ROOT.PRI ([65.208.56.47]) by rly12d.srv.mailcontrol.com (MailControl) with ESMTP id n1JAPZeP015920 for ; Thu, 19 Feb 2009 10:26:07 GMT Received: from cameurexb01.EUROPE.ROOT.PRI ([10.100.137.61]) by dalamsexb02.AMERICAS.ROOT.PRI with Microsoft SMTPSVC(6.0.3790.1830); Thu, 19 Feb 2009 04:24:52 -0600 Received: from news01.csr.com ([10.103.143.38]) by cameurexb01.EUROPE.ROOT.PRI with Microsoft SMTPSVC(6.0.3790.3959); Thu, 19 Feb 2009 10:16:24 +0000 Received: from news01.csr.com (localhost.localdomain [127.0.0.1]) by news01.csr.com (8.14.2/8.13.4) with ESMTP id n1JAGOIp014499 for ; Thu, 19 Feb 2009 10:16:25 GMT Received: from csr.com (pws@localhost) by news01.csr.com (8.14.2/8.14.2/Submit) with ESMTP id n1JAGOug014495 for ; Thu, 19 Feb 2009 10:16:24 GMT X-Authentication-Warning: news01.csr.com: pws owned process doing -bs To: zsh-workers@sunsite.dk (Zsh hackers list) Subject: PATCH: use bind/netdb.h where appropriate X-Mailer: MH-E 8.0.3; nmh 1.3; GNU Emacs 22.1.1 Date: Thu, 19 Feb 2009 10:16:23 +0000 Message-ID: <14494.1235038583@csr.com> From: Peter Stephenson X-OriginalArrivalTime: 19 Feb 2009 10:16:24.0966 (UTC) FILETIME=[1EA6F260:01C9927B] X-Scanned-By: MailControl A_08_51_00 (www.mailcontrol.com) on 10.68.0.122 X-Virus-Scanned: ClamAV 0.92.1/9002/Wed Feb 18 12:16:50 2009 on bifrost X-Virus-Status: Clean I'm not sure how long this has been going on, but I'm getting warnings from using some network utility functions. It seems that at least on Fedora when linked against the bind libraries we should be including bind/netdb.h instead of netdb.h. This will probably unleash a new tsunami of knock-on incompatibilities. Index: configure.ac =================================================================== RCS file: /cvsroot/zsh/zsh/configure.ac,v retrieving revision 1.117 diff -u -r1.117 configure.ac --- configure.ac 15 Jan 2009 14:49:51 -0000 1.117 +++ configure.ac 19 Feb 2009 10:12:53 -0000 @@ -755,6 +755,12 @@ AC_CHECK_LIB(socket, socket) AC_CHECK_LIB(bind, gethostbyname2) +case $LIBS in + *-lbind*) + AC_CHECK_HEADERS(bind/netdb.h) + ;; +esac + dnl --------------- dnl CHECK FOR ICONV dnl --------------- Index: Src/Modules/tcp.h =================================================================== RCS file: /cvsroot/zsh/zsh/Src/Modules/tcp.h,v retrieving revision 1.8 diff -u -r1.8 tcp.h --- Src/Modules/tcp.h 28 Apr 2003 15:06:31 -0000 1.8 +++ Src/Modules/tcp.h 19 Feb 2009 10:12:54 -0000 @@ -37,7 +37,16 @@ #include #include + +#ifdef HAVE_BIND_NETDB_H +/* + * On systems where we're using -lbind, this has more definitions + * than the standard header. + */ +#include +#else #include +#endif /* * For some reason, configure doesn't always detect netinet/in_systm.h. -- Peter Stephenson Software Engineer CSR PLC, Churchill House, Cambridge Business Park, Cowley Road Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070