From: Scott Wood Date: Tue, 5 Oct 2010 19:28:17 +0000 (-0500) Subject: configure: include stddef.h for NULL X-Git-Tag: TizenStudio_2.0_p2.3.2~208^2~7102 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=832ce9c286a907be8e6aab43fb0ae0037268476a;p=sdk%2Femulator%2Fqemu.git configure: include stddef.h for NULL This fixes an observed failure to detect madvise() on Linux. To avoid similar issues, all other tests that use NULL but don't already have stddef.h (or another header that is defined to provide NULL, such as stdio.h, unistd.h, or time.h) are also fixed. Signed-off-by: Scott Wood Signed-off-by: Blue Swirl --- diff --git a/configure b/configure index 9e65de0..4f57054 100755 --- a/configure +++ b/configure @@ -1329,6 +1329,7 @@ if test "$vnc_png" != "no" ; then cat > $TMPC < #include +#include int main(void) { png_structp png_ptr; png_ptr = png_create_write_struct(PNG_LIBPNG_VER_STRING, NULL, NULL, NULL); @@ -1513,6 +1514,7 @@ if test "$brlapi" != "no" ; then brlapi_libs="-lbrlapi" cat > $TMPC << EOF #include +#include int main( void ) { return brlapi__openConnection (NULL, NULL, NULL); } EOF if compile_prog "" "$brlapi_libs" ; then @@ -1747,6 +1749,7 @@ if test "$linux_aio" != "no" ; then cat > $TMPC < #include +#include int main(void) { io_setup(0, NULL); io_set_eventfd(NULL, 0); eventfd(0, 0); return 0; } EOF if compile_prog "" "-laio" ; then @@ -2127,6 +2130,7 @@ madvise=no cat > $TMPC << EOF #include #include +#include int main(void) { return madvise(NULL, 0, MADV_DONTNEED); } EOF if compile_prog "" "" ; then @@ -2139,6 +2143,7 @@ fi posix_madvise=no cat > $TMPC << EOF #include +#include int main(void) { return posix_madvise(NULL, 0, POSIX_MADV_DONTNEED); } EOF if compile_prog "" "" ; then