[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

lynx-dev Lynx , gcc, curses on HP-UX 10.20

From: David Balazic
Subject: lynx-dev Lynx , gcc, curses on HP-UX 10.20
Date: Thu, 08 Jun 2000 10:06:46 +0200


I compiled lynx 2.8.3 on HP-UX 10.20 ( uname -a output :
HP-UX superman B.10.20 C 9000/782 2009332812 32-user license )
using "B.10.20.02     HP C/ANSI C Developer's Bundle for HP-UX 10.20
and it was OK.
Then I compiled it on the same machine , but this time with gcc-2.95.2.
It was built, but the look of lynx was really lame.
It was some problem with curses. I discovered that the configure
script got confused about the curses library and didn't use most of
the features.
The problem : the short test programs during the configure process
that involve curses ( they include curses.h ) fail to compile.
Reason : the curses.h file ( the one in
there is another at /usr/include/curses.h, but is not used ) uses
va_list but does not include varargs.h (*).

Solution (it worked for me) : in the configure script include
varargs.h ( or stdarg.h ) before including curses.h ( at each occurrence

This is not a problem whet using the HP C compiler, because it doesn't
define __STDC__, while gcc does.

* - The part from /usr/include/curses_colr/curses.h is interesting;
    note that on my system stdarg.h just includes varargs.h ! :

#ifdef __STDC__
                /* in the following 2 functions 'void *' is really
va_list */
                /* however, we cannot include <stdarg.h> in
curses.h,      */
                /* because some applications may be using <varargs.h>
that */
                /* conflicts with
<stdarg.h>                               */

#ifdef __hpux
extern  int     vwprintw(WINDOW *, char *, va_list),
                vwscanw(WINDOW *, char *, va_list);
#else /* !__hpux */
extern  int     vwprintw(WINDOW *, char *, void *),
                vwscanw(WINDOW *, char *, void *);
#endif /* __hpux */

#else /* __STDC__ */
extern  int     mvprintw(), mvscanw(), mvwprintw(), mvwscanw(),
                printw(), scanw(), wprintw(), wscanw(), vwprintw(),
#endif /* __STDC__ */

David Balazic

; To UNSUBSCRIBE: Send "unsubscribe lynx-dev" to address@hidden

reply via email to

[Prev in Thread] Current Thread [Next in Thread]