Re: Compiling error macro `va_start' used with just one arg

From: Rainer Perske <perske@dont-contact.us>
Date: Mon, 4 Oct 1999 10:01:24 +0200 (MES)

-----BEGIN PGP SIGNED MESSAGE-----

Hi, Duane,

> > Maybe. The problem is that both stdarg.h and varargs.h are included
> > because configure demands to do so on AIX systems - not a good idea.
> >
> > My solution to this problem: Inhibit inclusion of varargs.h by setting
> > export CC='cc_r -D_H_VARARGS=1 -qlanglvl=ansi'
> > export CFLAGS='-O'
> > prior to running config (this works with 2.1.PATCH2 on AIX 4.2.1)
>
> My guess is that AIX's /usr/include/syslog.h includes varargs.h.
> There is a little hack that used to prevent it:
>
> #if STDC_HEADERS
> #include <stdarg.h>
> #else
> #include <varargs.h>
> #endif
>
> /* Make sure syslog goes after stdarg/varargs */
> #ifdef HAVE_SYSLOG_H
> #ifdef _SQUID_AIX_
> #define _XOPEN_EXTENDED_SOURCE
> #endif
> #include <syslog.h>
> #endif
>
> Apparently defining _XOPEN_EXTENDED_SOURCE doesn't help for all
> versions of AIX. Maybe there is another magic symbol?

Currently I'm holding lectures, thus I've not the time to look for it.
But symbols like _H_VARARGS are defined and tested in each header
file to avoid duplicate inclusion.

cul8er
- --
Rainer Perske (Webmaster/News/System/PGP-Admin)
WWU Münster Zentrum für Informationsverarbeitung (Uni-Rechenzentrum)
http://www.uni-muenster.de/ZIV/Mitarbeiter/RainerPerske.html (Beruf)
http://www.muenster.de/~perske (Privat/Sport) (darf geDUzt werden)

-----BEGIN PGP SIGNATURE-----
Version: 2.6.3ia
Charset: latin1

iQDVAwUBN/he189UbnbjB8C5AQGqBAYAkz1/V7Rtag6Izbi1fEFL2d4JETvVIBS1
JVSuRTEGwOW58dmbSHNQKsgEYPGniGmwMFhAx7Tzrl7orK2dOKoiScGVNr4elAMS
8jsSPQYEmxLDA7XWXMyx8Te/o4U0xXa1zndSMALtUKXwjPP0yZ166B36oJ4ppBHU
SV8WcYV352mJbMPKDrl97FRXpzfzfOYcRlPpaPuidAOFL9O3DE7XxMYbpCZNx1HW
y5dcdPie0200y/uBfp3gixoimmc8rdPV
=poE1
-----END PGP SIGNATURE-----
Received on Mon Oct 04 1999 - 02:13:30 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:48:42 MST