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

Bug#614734: libc6.1-dev: #include <math.h> from gcc on a DEC Alpha does not declare function `round'



Hi Wayne,

Wayne Rossberg wrote:

> #include <math.h>
[...]
> test.c:5: warning: incompatible implicit declaration of built-in function `round'

When I check with "man 3 round", I see:

   Feature Test Macro Requirements for glibc (see feature_test_macros(7)):

	round(), roundf(), roundl():
	   _XOPEN_SOURCE >= 600 || _ISOC99_SOURCE || _POSIX_C_SOURCE >= 200112L;
	   or cc -std=c99

Are you compiling with -std=c99?  If not, I'd suggest putting
"#define _GNU_SOURCE" at the top of the program and seeing if that
helps.  See feature_test_macros(7) for details.

(That said, the warning does seem weird.  I'm not sure what would
cause it.)

Hope that helps,
Jonathan



Reply to: