Include <errno.h> and declare errno if necessary.
# include <stddef.h> /* For the definition of size_t on windows w/MSVC. */
#endif
#include <sys/types.h>
-#include <quotearg.h>
-#include <xalloc.h>
#include <ctype.h>
+#include <errno.h>
+#ifndef errno
+extern int errno;
+#endif
#if ENABLE_NLS
# include <libintl.h>
# endif
#endif
+#include "quotearg.h"
+#include "xalloc.h"
+
#define INT_BITS (sizeof (int) * CHAR_BIT)
#if defined (STDC_HEADERS) || (!defined (isascii) && !defined (HAVE_ISASCII))