From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18101 invoked from network); 17 Feb 2004 11:37:53 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 17 Feb 2004 11:37:53 -0000 Received: (qmail 29901 invoked by alias); 17 Feb 2004 11:37:41 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 19428 Received: (qmail 29891 invoked from network); 17 Feb 2004 11:37:41 -0000 Received: from localhost (HELO sunsite.dk) (127.0.0.1) by localhost with SMTP; 17 Feb 2004 11:37:41 -0000 X-MessageWall-Score: 0 (sunsite.dk) Received: from [62.189.58.19] by sunsite.dk (MessageWall 1.0.8) with SMTP; 17 Feb 2004 11:37:41 -0000 Received: from MAILSWEEPER01.csr.com (mailhost1.csr.com [62.189.183.235]) by lhuumrelay3.lnd.ops.eu.uu.net (8.11.0/8.11.0) with ESMTP id i1HBbev11081 for ; Tue, 17 Feb 2004 11:37:40 GMT Received: from EXCHANGE02.csr.com (unverified [192.168.137.45]) by MAILSWEEPER01.csr.com (Content Technologies SMTPRS 4.3.12) with ESMTP id for ; Tue, 17 Feb 2004 11:37:22 +0000 Received: from csr.com ([192.168.144.127]) by EXCHANGE02.csr.com with Microsoft SMTPSVC(5.0.2195.5329); Tue, 17 Feb 2004 11:38:37 +0000 To: zsh-workers@sunsite.dk (Zsh hackers list) Subject: PATCH: fix configure warning. Date: Tue, 17 Feb 2004 11:37:39 +0000 Message-ID: <18953.1077017859@csr.com> From: Peter Stephenson X-OriginalArrivalTime: 17 Feb 2004 11:38:37.0787 (UTC) FILETIME=[954EF2B0:01C3F54A] This fixes a warning from configure 2.59 about trying to compile sys/ptem.h. The header is present but won't compile. This causes configure to execute AC_SOMETHING_ROTTEN_IN_THE_STATE_OF_DENMARK (or equivalent). The corresponding section of system.h uses the test to #include both sys/stream.h and sys/ptem.h. According to the name, we are looking for struct winsize. So a better test would seem to be to #include both files and see if we can compile a reference to struct winsize. This passes without a grumble both with and without streams support. (Actually, at least on Solaris 8, winsize isn't defined inside ptem.h, so the old message was fallacious.) Next stop is curses. Index: configure.ac =================================================================== RCS file: /cvsroot/zsh/zsh/configure.ac,v retrieving revision 1.4 diff -u -r1.4 configure.ac --- configure.ac 14 Feb 2004 18:50:16 -0000 1.4 +++ configure.ac 17 Feb 2004 11:17:53 -0000 @@ -562,8 +562,17 @@ fi AH_TEMPLATE([WINSIZE_IN_PTEM], -[Define if your system defines `struct winsize' in sys/ptem.h.]) -AC_CHECK_HEADER([sys/ptem.h], AC_DEFINE(WINSIZE_IN_PTEM)) +[Define if your should include sys/stream.h and sys/ptem.h.]) +AC_CACHE_CHECK(for streams headers including struct winsize, +ac_cv_winsize_in_ptem, +[AC_TRY_COMPILE([#include +#include ], +[struct winsize wsz], +ac_cv_winsize_in_ptem=yes, +ac_cv_winsize_in_ptem=no)]) +if test $ac_cv_winsize_in_ptem = yes; then + AC_DEFINE(WINSIZE_IN_PTEM) +fi dnl ------------------- dnl CHECK FOR LIBRARIES -- Peter Stephenson Software Engineer CSR Ltd., Science Park, Milton Road, Cambridge, CB4 0WH, UK Tel: +44 (0)1223 692070 ********************************************************************** This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This footnote also confirms that this email message has been swept by MIMEsweeper for the presence of computer viruses. www.mimesweeper.com **********************************************************************