# Always build with prototypes
AC_DEFINE([HAVE_PROTOTYPES], 1, [Define if your compiler supports prototypes])
-# Don't use undefined types
-AC_DEFINE([INCOMPLETE_TYPES_BROKEN], 1, [Define if you want use complete types])
# Checks for programs.
SAVED_CFLAGS=${CFLAGS}
AC_PROG_LIBTOOL
AC_PROG_LN_S
+# Check whether compiler supports pointers to undefined structures
+AC_MSG_CHECKING(whether compiler supports pointers to undefined structures)
+AC_TRY_COMPILE([ typedef struct undefined_structure * undef_struct_ptr; ], ,
+AC_MSG_RESULT(yes),
+[AC_MSG_RESULT(no)
+AC_DEFINE([INCOMPLETE_TYPES_BROKEN],[1],[Compiler does not support pointers to undefined structures.])])
+
if test "x${GCC}" = "xyes"; then
if test "x${SAVED_CFLAGS}" = "x"; then
CFLAGS=-O3