From: Sven Panne Date: Mon, 3 Jan 2005 11:35:18 +0000 (+0000) Subject: autoconf'd handling and removed an unused '#include ' X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?a=commitdiff_plain;h=585c48d614d2b7e22c18fb1ee998a303f9e7fdf3;p=freeglut autoconf'd handling and removed an unused '#include ' git-svn-id: svn+ssh://svn.code.sf.net/p/freeglut/code/trunk/freeglut/freeglut@553 7f0cb862-5218-0410-a997-914c9d46530a --- diff --git a/ChangeLog b/ChangeLog index 1f13223..bb25827 100644 --- a/ChangeLog +++ b/ChangeLog @@ -886,3 +886,5 @@ default. *************************************************************************** (230) Removed acconfig.h, it is deprecated and we don't need it. + +(231) Cleaned up and autoconf'd the header inclusion story a bit. diff --git a/configure.ac b/configure.ac index 63c2cb8..aa4e304 100644 --- a/configure.ac +++ b/configure.ac @@ -23,7 +23,7 @@ AC_SUBST([LIBXXF86VM]) # Checks for header files. AC_HEADER_STDC -AC_CHECK_HEADERS([GL/gl.h GL/glu.h GL/glx.h fcntl.h limits.h sys/ioctl.h sys/param.h sys/time.h]) +AC_CHECK_HEADERS([GL/gl.h GL/glu.h GL/glx.h errno.h fcntl.h limits.h sys/ioctl.h sys/param.h sys/time.h]) AC_HEADER_TIME save_CFLAGS="$CFLAGS" diff --git a/src/freeglut_joystick.c b/src/freeglut_joystick.c index 781d0dd..3a1e325 100644 --- a/src/freeglut_joystick.c +++ b/src/freeglut_joystick.c @@ -73,6 +73,9 @@ # if HAVE_FCNTL_H # include # endif +# if HAVE_ERRNO_H +# include +# endif # if defined(__FreeBSD__) || defined(__NetBSD__) /* XXX The below hack is done until freeglut's autoconf is updated. */ # define HAVE_USB_JS 1 @@ -93,8 +96,6 @@ # define JS_RETURN (sizeof(struct JS_DATA_TYPE)) # endif -# include - # if defined(__linux__) # include diff --git a/src/freeglut_main.c b/src/freeglut_main.c index 6f4bcec..61731cb 100644 --- a/src/freeglut_main.c +++ b/src/freeglut_main.c @@ -27,12 +27,11 @@ #include #include "freeglut_internal.h" +#if HAVE_ERRNO_H +# include +#endif -#if TARGET_HOST_UNIX_X11 -#include -#include -#elif TARGET_HOST_WIN32 -#elif TARGET_HOST_WINCE +#if TARGET_HOST_WINCE typedef struct GXDisplayProperties GXDisplayProperties; typedef struct GXKeyList GXKeyList;