Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Problem compiling 3.1.9 under HP-UX 10.20
- X-seq: zsh-workers 12190
 
- From: Gene Cohler <gene@xxxxxxxx>
 
- To: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxxxxxxxxx>
 
- Subject: Re: Problem compiling 3.1.9 under HP-UX 10.20
 
- Date: Fri, 7 Jul 2000 09:28:08 -0400
 
- Cc: zsh-workers@xxxxxxxxxxxxxx
 
- In-reply-to: <1000707053849.ZM28504@xxxxxxxxxxxxxxxxxxxxxxx>; from schaefer@xxxxxxxxxxxxxxxxxxxxxxx on Fri, Jul 07, 2000 at 05:38:49AM +0000
 
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
 
- References: <0FX4007G6UV5CT@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx> <1000707053849.ZM28504@xxxxxxxxxxxxxxxxxxxxxxx>
 
HPUX 10.20:
----------
I bumped into this earlier - under HPUX 10.20 and I 'fixed' the problem
by adding -D_XOPEN_SOURCE_EXTENDED. This is not defined it seems
using -Ae compiler flag (which does define _XOPEN_SOURCE)
The reason, quite obviously, is this code frag in /usr/include/netdb.h:
/*
 * Error return codes from gethostbyname() and gethostbyaddr()
 * (left in extern int h_errno).
 */
#ifdef _XOPEN_SOURCE_EXTENDED
extern int h_errno;
#endif
HPUX 11.00 
----------
 A brief glance suggests it may be different - but I haven't had a chance 
 yet to look into it properly. I will report back when I do.
On Fri, Jul 07, 2000 at 05:38:49AM +0000, Bart Schaefer wrote:
> On Jul 3,  6:49pm, Peter Stephenson wrote:
> } Subject: Re: Problem compiling 3.1.9 under HP-UX 10.20
> }
> } > Hi,
> } > 
> } > I've gotten zsh-3.1.9 to compile on my workstation, but only by
> } > excluding zftp.  The etc/MACHINES file doesn't state anything special
> } > about HP-UX.
> } > zftp.c:211: `h_errno' undeclared (first use in this function)
> } 
> } Finally I made some time to look at this.  From the information above,
> } this is the best I can do.
> 
> This patch has been bothering me ever since it appeared.
> 
> } +dnl Check for h_errno external variable
> } +AC_CACHE_CHECK(if we need our own h_errno,
> } +  zsh_cv_decl_h_errno_use_local,
> } +  [AC_TRY_LINK( ,[extern int h_errno; h_errno = 0;],
> } +  zsh_cv_decl_h_errno_use_local=no,
> } +  zsh_cv_decl_h_errno_use_local=yes)])
> 
> That's testing whether it's possible to *link with* h_errno; if it is,
> then we conclude that we need not declare it locally.
> 
> But the problem in zftp.c is that h_errno is not *declared* at compile
> time, not that it's not *defined* at link time.  That would indicate to
> me that zftp.c hasn't #included the correct header file.
> 
> So I don't understand how this patch could possibly solve the problem
> that was reported.  Has anybody actually tried it yet, *on HP-UX*?
> 
> -- 
> Bart Schaefer                                 Brass Lantern Enterprises
> http://www.well.com/user/barts              http://www.brasslantern.com
> 
> Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net   
-- 
  Gene Cohler
  Bear Stearns & Co.
***********************************************************************
Bear Stearns is not responsible for any recommendation, solicitation, 
offer or agreement or any information about any transaction, customer 
account or account activity contained in this communication.
***********************************************************************
Messages sorted by:
Reverse Date,
Date,
Thread,
Author