summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorrofl0r <retnyg@gmx.net>2016-12-21 20:45:03 +0000
committerrofl0r <retnyg@gmx.net>2016-12-21 20:45:06 +0000
commit39c92a3f70bb15003540ed5ab277db893a1c707e (patch)
tree6018f21c3c181547aa5bb4f4e18a474387d5094b
parent90df51093209b33629d939d1e1f4fcc9a40a8124 (diff)
configure: do not check for standard C headers
addresses #65
-rw-r--r--configure.ac4
-rw-r--r--src/common.h38
2 files changed, 16 insertions, 26 deletions
diff --git a/configure.ac b/configure.ac
index fe19787..3161620 100644
--- a/configure.ac
+++ b/configure.ac
@@ -164,8 +164,8 @@ AC_HEADER_SYS_WAIT
AC_CHECK_HEADERS([sys/ioctl.h sys/mman.h sys/resource.h \
sys/select.h sys/socket.h sys/time.h sys/uio.h \
sys/un.h arpa/inet.h netinet/in.h \
- assert.h ctype.h errno.h fcntl.h grp.h io.h libintl.h \
- netdb.h pwd.h regex.h signal.h stdarg.h stddef.h stdio.h \
+ assert.h errno.h fcntl.h grp.h io.h libintl.h \
+ netdb.h pwd.h regex.h signal.h stdarg.h \
sysexits.h syslog.h time.h wchar.h wctype.h \
values.h])
diff --git a/src/common.h b/src/common.h
index 89a054f..7f5ce9b 100644
--- a/src/common.h
+++ b/src/common.h
@@ -32,6 +32,16 @@
/*
* Include standard headers which are used through-out tinyproxy
*/
+
+/* standard C headers - we can safely assume they exist. */
+#include <stddef.h>
+#include <stdint.h>
+#include <ctype.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+
#ifdef HAVE_SYS_TYPES_H
# include <sys/types.h>
#endif
@@ -41,12 +51,6 @@
#ifdef HAVE_INTTYPES_H
# include <inttypes.h>
#endif
-#ifdef HAVE_STDDEF_H
-# include <stddef.h>
-#endif
-#ifdef HAVE_STDINT_H
-# include <stdint.h>
-#endif
#ifdef HAVE_SYS_IOCTL_H
# include <sys/ioctl.h>
@@ -97,9 +101,6 @@
#ifdef HAVE_ASSERT_H
# include <assert.h>
#endif
-#ifdef HAVE_CTYPE_H
-# include <ctype.h>
-#endif
#ifdef HAVE_ERRNO_H
# include <errno.h>
#endif
@@ -127,19 +128,11 @@
#ifdef HAVE_STDARG_H
# include <stdarg.h>
#endif
-#ifdef HAVE_STDIO_H
-# include <stdio.h>
-#endif
-#ifdef HAVE_STDLIB_H
-# include <stdlib.h>
-#else
-# ifdef HAVE_MALLOC_H
-# include <malloc.h>
-# endif
-#endif
-#ifdef HAVE_STRING_H
-# include <string.h>
+
+#ifdef HAVE_MALLOC_H
+# include <malloc.h>
#endif
+
#ifdef HAVE_STRINGS_H
# include <strings.h>
#endif
@@ -149,9 +142,6 @@
#ifdef HAVE_SYSLOG_H
# include <syslog.h>
#endif
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif
#ifdef HAVE_WCHAR_H
# include <wchar.h>
#endif