[nas] Gcc 4.0 fixes for nas 1.7

Jon Trulson jon at radscan.com
Thu Dec 30 14:33:19 MST 2004


On Sun, 26 Dec 2004, Steve McIntyre wrote:

> Hi Jon,
>
> Gcc 4.0 is much pickier about function prototypes. It throws lots of
> warnings when compiling nas 1.7, and one error in auutil.c. The
> attached patch fixes them for me (mainly by simply including standard
> headers!).
>

 	Hello Steve,

 	Unfortunately the issue with this is that not all systems provide 
stdlib.h.  I added an autoconf confgure script in config/ (run during the 
make includes phase) to try to figure out this stuff on a per system basis 
in v1.7.  John Wehle provided some of these stdlib.h includes for FreeBSD 
in 1.7, prompting the addition of this simple autoconf script in config/. 
I will need to go through the patch, wrapping the #includes with:

 	#if defined(HAVE_STDLIB_H)
 	...
 	#endif

 	same for string.h/strings.h .

 	The one thing I'm not sure about is the socklen_t changes... How 
portable is this?  It seems like every system has a different idea about 
it :)  Maybe I need an autoconf rule to detect when this typedef is 
available as well?

> I'm also seeing (on AMD64) several warnings about invalid pointer <->
> int conversions. These seem benign so far, but you should be
> aware. I've grepped a build log for these (also attached).

 	Ok, Thanks.

-- 
Jon Trulson    mailto:jon at radscan.com
ID: 1A9A2B09, FP: C23F328A721264E7 B6188192EC733962
PGP keys at http://radscan.com/~jon/PGPKeys.txt
#include <std/disclaimer.h>
"I am Nomad." -Nomad




More information about the Nas mailing list