[CLEANUP] included common/version.h everywhere
diff --git a/include/common/appsession.h b/include/common/appsession.h
index 2c39e46..eb9ba2d 100644
--- a/include/common/appsession.h
+++ b/include/common/appsession.h
@@ -7,6 +7,7 @@
 #include <sys/time.h>
 
 #include <common/chtbl.h>
+#include <common/config.h>
 #include <common/hashpjw.h>
 #include <common/list.h>
 
diff --git a/include/common/base64.h b/include/common/base64.h
index 3948962..bd77c68 100644
--- a/include/common/base64.h
+++ b/include/common/base64.h
@@ -14,6 +14,8 @@
 #ifndef _COMMON_BASE64_H
 #define _COMMON_BASE64_H
 
+#include <common/config.h>
+
 int a2base64(char *in, int ilen, char *out, int olen);
 extern const char base64tab[];
 
diff --git a/include/common/cfgparse.h b/include/common/cfgparse.h
index 35302b3..591f172 100644
--- a/include/common/cfgparse.h
+++ b/include/common/cfgparse.h
@@ -22,6 +22,8 @@
 #ifndef _COMMON_CFGPARSE_H
 #define _COMMON_CFGPARSE_H
 
+#include <common/config.h>
+
 /* configuration sections */
 #define CFG_NONE	0
 #define CFG_GLOBAL	1
diff --git a/include/common/chtbl.h b/include/common/chtbl.h
index 38b495f..cddb207 100644
--- a/include/common/chtbl.h
+++ b/include/common/chtbl.h
@@ -20,7 +20,8 @@
 
 #include <stdlib.h>
 
-#include "list.h"
+#include <common/config.h>
+#include <common/list.h>
 
 /*****************************************************************************
 *                                                                            *
diff --git a/include/common/compat.h b/include/common/compat.h
index a605da1..58908d7 100644
--- a/include/common/compat.h
+++ b/include/common/compat.h
@@ -24,6 +24,7 @@
 
 /* This is needed on Linux for Netfilter includes */
 #include <sys/socket.h>
+#include <common/config.h>
 
 /* INTBITS
  * how many bits are needed to code the size of an int on the target platform.
diff --git a/include/common/config.h b/include/common/config.h
index f9145c5..c1cf098 100644
--- a/include/common/config.h
+++ b/include/common/config.h
@@ -31,4 +31,13 @@
  */
 #define SCHEDULER_RESOLUTION    9
 
+/* CONFIG_HAP_MEM_OPTIM
+ * This enables use of memory pools instead of malloc()/free(). There
+ * is no reason to disable it, except perhaps for rare debugging.
+ */
+#ifndef   CONFIG_HAP_NO_MEM_OPTIM
+#  define CONFIG_HAP_MEM_OPTIM
+#endif /* CONFIG_HAP_NO_MEM_OPTIM */
+
+
 #endif /* _COMMON_CONFIG_H */
diff --git a/include/common/defaults.h b/include/common/defaults.h
index 449fc5f..e44a64c 100644
--- a/include/common/defaults.h
+++ b/include/common/defaults.h
@@ -22,15 +22,6 @@
 #ifndef _COMMON_DEFAULTS_H
 #define _COMMON_DEFAULTS_H
 
-
-/* CONFIG_HAP_MEM_OPTIM
- * This enables use of memory pools instead of malloc()/free(). There
- * is no reason to disable it, except perhaps for rare debugging.
- */
-#ifndef   CONFIG_HAP_NO_MEM_OPTIM
-#  define CONFIG_HAP_MEM_OPTIM
-#endif /* CONFIG_HAP_NO_MEM_OPTIM */
-
 /*
  * BUFSIZE defines the size of a read and write buffer. It is the maximum
  * amount of bytes which can be stored by the proxy for each session. However,
diff --git a/include/common/epoll.h b/include/common/epoll.h
index 865a3e1..56eef7e 100644
--- a/include/common/epoll.h
+++ b/include/common/epoll.h
@@ -29,8 +29,10 @@
 #ifndef _COMMON_EPOLL_H
 #define _COMMON_EPOLL_H
 
-#include <linux/unistd.h>
 #include <stdint.h>
+#include <linux/unistd.h>
+
+#include <common/config.h>
 
 /* epoll_ctl() commands */
 #ifndef EPOLL_CTL_ADD
diff --git a/include/common/hashpjw.h b/include/common/hashpjw.h
index 99a3ad7..8d3998c 100644
--- a/include/common/hashpjw.h
+++ b/include/common/hashpjw.h
@@ -19,6 +19,8 @@
 #ifndef _COMMON_HASHPJW_H
 #define _COMMON_HASHPJW_H
 
+#include <common/config.h>
+
 /*****************************************************************************
 *                                                                            *
 *  Define a table size for demonstration purposes only.                      *
diff --git a/include/common/list.h b/include/common/list.h
index 4537d8d..91a5084 100644
--- a/include/common/list.h
+++ b/include/common/list.h
@@ -19,6 +19,7 @@
 #define _COMMON_LIST_H
 
 #include <stdlib.h>
+#include <common/config.h>
 
 /*****************************************************************************
  *                                                                            *
diff --git a/include/common/mini-clist.h b/include/common/mini-clist.h
index 47b004d..cf472ba 100644
--- a/include/common/mini-clist.h
+++ b/include/common/mini-clist.h
@@ -7,6 +7,8 @@
 #ifndef _COMMON_MINI_CLIST_H
 #define _COMMON_MINI_CLIST_H
 
+#include <common/config.h>
+
 /* these are circular or bidirectionnal lists only. Each list pointer points to
  * another list pointer in a structure, and not the structure itself. The
  * pointer to the next element MUST be the first one so that the list is easily
diff --git a/include/common/regex.h b/include/common/regex.h
index d9510bf..c7f1c21 100644
--- a/include/common/regex.h
+++ b/include/common/regex.h
@@ -22,7 +22,7 @@
 #ifndef _COMMON_REGEX_H
 #define _COMMON_REGEX_H
 
-#include <common/defaults.h>
+#include <common/config.h>
 
 #ifdef USE_PCRE
 #include <pcre.h>
diff --git a/include/common/standard.h b/include/common/standard.h
index bde42e3..0b2ea8d 100644
--- a/include/common/standard.h
+++ b/include/common/standard.h
@@ -23,9 +23,7 @@
 #define _COMMON_STANDARD_H
 
 #include <netinet/in.h>
-#include <common/defaults.h>
-#include <common/compat.h>
-
+#include <common/config.h>
 
 /****** string-specific macros and functions ******/
 /* if a > max, then bound <a> to <max>. The macro returns the new <a> */
diff --git a/include/common/template.h b/include/common/template.h
index 431274f..c9e48bf 100644
--- a/include/common/template.h
+++ b/include/common/template.h
@@ -22,6 +22,7 @@
 #ifndef _COMMON_TEMPLATE_H
 #define _COMMON_TEMPLATE_H
 
+#include <common/config.h>
 
 #endif /* _COMMON_TEMPLATE_H */
 
diff --git a/include/common/time.h b/include/common/time.h
index b258466..7661aac 100644
--- a/include/common/time.h
+++ b/include/common/time.h
@@ -24,6 +24,7 @@
 
 #include <stdlib.h>
 #include <sys/time.h>
+#include <common/config.h>
 
 #define TIME_ETERNITY		-1
 
diff --git a/include/common/uri_auth.h b/include/common/uri_auth.h
index ddfa56b..bb25ac1 100644
--- a/include/common/uri_auth.h
+++ b/include/common/uri_auth.h
@@ -12,6 +12,9 @@
 
 #ifndef _COMMON_URI_AUTH_H
 #define _COMMON_URI_AUTH_H
+
+#include <common/config.h>
+
 /* here we find a very basic list of base64-encoded 'user:passwd' strings */
 struct user_auth {
 	struct user_auth *next;		/* next entry, NULL if none */
diff --git a/include/common/version.h b/include/common/version.h
index c1ae43b..14d68a2 100644
--- a/include/common/version.h
+++ b/include/common/version.h
@@ -22,17 +22,23 @@
 #ifndef _COMMON_VERSION_H
 #define _COMMON_VERSION_H
 
+#include <common/config.h>
+
 #ifdef  CONFIG_PRODUCT_NAME
-#define PRODUCT_NAME CONFIG_PRODUCT_NAME
+#define PRODUCT_NAME    CONFIG_PRODUCT_NAME
 #else
-#define PRODUCT_NAME "HAProxy"
+#define PRODUCT_NAME    "HAProxy"
 #endif
 
-#ifndef HAPROXY_VERSION
+#ifdef CONFIG_HAPROXY_VERSION
+#define HAPROXY_VERSION CONFIG_HAPROXY_VERSION
+#else
 #define HAPROXY_VERSION "1.3.0"
 #endif
 
-#ifndef HAPROXY_DATE
+#ifdef CONFIG_HAPROXY_DATE
+#define HAPROXY_DATE    CONFIG_HAPROXY_DATE
+#else
 #define HAPROXY_DATE    "2006/06/26"
 #endif
 
diff --git a/include/proto/backend.h b/include/proto/backend.h
index 5f24be6..cc25a6f 100644
--- a/include/proto/backend.h
+++ b/include/proto/backend.h
@@ -22,6 +22,7 @@
 #ifndef _PROTO_BACKEND_H
 #define _PROTO_BACKEND_H
 
+#include <common/config.h>
 
 #include <types/backend.h>
 #include <types/session.h>
diff --git a/include/proto/buffers.h b/include/proto/buffers.h
index b332a4b..29a2abc 100644
--- a/include/proto/buffers.h
+++ b/include/proto/buffers.h
@@ -22,7 +22,7 @@
 #ifndef _PROTO_BUFFERS_H
 #define _PROTO_BUFFERS_H
 
-#include <common/defaults.h>
+#include <common/config.h>
 #include <types/buffers.h>
 
 /* returns 1 if the buffer is empty, 0 otherwise */
diff --git a/include/proto/checks.h b/include/proto/checks.h
index d16a288..6ac32a1 100644
--- a/include/proto/checks.h
+++ b/include/proto/checks.h
@@ -23,6 +23,7 @@
 #define _PROTO_CHECKS_H
 
 #include <types/task.h>
+#include <common/config.h>
 
 int process_chk(struct task *t);
 
diff --git a/include/proto/client.h b/include/proto/client.h
index e119dca..3065b61 100644
--- a/include/proto/client.h
+++ b/include/proto/client.h
@@ -22,9 +22,9 @@
 #ifndef _PROTO_CLIENT_H
 #define _PROTO_CLIENT_H
 
+#include <common/config.h>
 #include <types/client.h>
 
-
 int event_accept(int fd);
 
 
diff --git a/include/proto/fd.h b/include/proto/fd.h
index 699047b..879205b 100644
--- a/include/proto/fd.h
+++ b/include/proto/fd.h
@@ -26,6 +26,7 @@
 #include <sys/types.h>
 #include <unistd.h>
 
+#include <common/config.h>
 #include <types/fd.h>
 
 /* Deletes an FD from the fdsets, and recomputes the maxfd limit.
diff --git a/include/proto/log.h b/include/proto/log.h
index 5cc568a..7a74c82 100644
--- a/include/proto/log.h
+++ b/include/proto/log.h
@@ -26,6 +26,7 @@
 #include <stdio.h>
 #include <syslog.h>
 
+#include <common/config.h>
 #include <types/log.h>
 #include <types/proxy.h>
 #include <types/session.h>
diff --git a/include/proto/polling.h b/include/proto/polling.h
index 6b349c6..179c654 100644
--- a/include/proto/polling.h
+++ b/include/proto/polling.h
@@ -22,6 +22,7 @@
 #ifndef _PROTO_POLLING_H
 #define _PROTO_POLLING_H
 
+#include <common/config.h>
 #include <types/polling.h>
 
 /*
diff --git a/include/proto/proto_http.h b/include/proto/proto_http.h
index e9cd4f3..205b0ee 100644
--- a/include/proto/proto_http.h
+++ b/include/proto/proto_http.h
@@ -22,6 +22,7 @@
 #ifndef _PROTO_PROTO_HTTP_H
 #define _PROTO_PROTO_HTTP_H
 
+#include <common/config.h>
 #include <types/proto_http.h>
 #include <types/session.h>
 #include <types/task.h>
diff --git a/include/proto/proxy.h b/include/proto/proxy.h
index 4a3d67c..968495f 100644
--- a/include/proto/proxy.h
+++ b/include/proto/proxy.h
@@ -22,7 +22,7 @@
 #ifndef _PROTO_PROXY_H
 #define _PROTO_PROXY_H
 
-
+#include <common/config.h>
 #include <types/proxy.h>
 
 int start_proxies(int verbose);
diff --git a/include/proto/queue.h b/include/proto/queue.h
index 6909cbe..6732ba9 100644
--- a/include/proto/queue.h
+++ b/include/proto/queue.h
@@ -22,6 +22,7 @@
 #ifndef _PROTO_QUEUE_H
 #define _PROTO_QUEUE_H
 
+#include <common/config.h>
 #include <common/memory.h>
 #include <common/mini-clist.h>
 
diff --git a/include/proto/server.h b/include/proto/server.h
index b79b970..2df0763 100644
--- a/include/proto/server.h
+++ b/include/proto/server.h
@@ -24,6 +24,7 @@
 
 #include <unistd.h>
 
+#include <common/config.h>
 #include <types/proxy.h>
 #include <types/queue.h>
 #include <types/server.h>
diff --git a/include/proto/session.h b/include/proto/session.h
index 6c84f4c..e3e5234 100644
--- a/include/proto/session.h
+++ b/include/proto/session.h
@@ -22,7 +22,7 @@
 #ifndef _PROTO_SESSION_H
 #define _PROTO_SESSION_H
 
-
+#include <common/config.h>
 #include <types/session.h>
 
 void session_free(struct session *s);
diff --git a/include/proto/stream_sock.h b/include/proto/stream_sock.h
index 14d90cf..31184b1 100644
--- a/include/proto/stream_sock.h
+++ b/include/proto/stream_sock.h
@@ -26,7 +26,6 @@
 #include <sys/socket.h>
 #include <sys/types.h>
 
-#include <common/defaults.h>
 #include <common/config.h>
 
 
diff --git a/include/proto/task.h b/include/proto/task.h
index 72fd1f1..70abb82 100644
--- a/include/proto/task.h
+++ b/include/proto/task.h
@@ -24,8 +24,10 @@
 
 
 #include <sys/time.h>
-#include <types/task.h>
+
+#include <common/config.h>
 #include <common/memory.h>
+#include <types/task.h>
 
 
 /* puts the task <t> in run queue <q>, and returns <t> */
diff --git a/include/proto/template.h b/include/proto/template.h
index 868634f..f7f9e55 100644
--- a/include/proto/template.h
+++ b/include/proto/template.h
@@ -22,7 +22,7 @@
 #ifndef _PROTO_TEMPLATE_H
 #define _PROTO_TEMPLATE_H
 
-
+#include <common/config.h>
 #include <types/template.h>
 
 
diff --git a/include/types/backend.h b/include/types/backend.h
index 7a6a640..9fa179f 100644
--- a/include/types/backend.h
+++ b/include/types/backend.h
@@ -22,6 +22,8 @@
 #ifndef _TYPES_BACKEND_H
 #define _TYPES_BACKEND_H
 
+#include <common/config.h>
+
 /* bits for proxy->options */
 #define PR_O_REDISP     0x00000001      /* allow reconnection to dispatch in case of errors */
 #define PR_O_TRANSP     0x00000002      /* transparent mode : use original DEST as dispatch */
diff --git a/include/types/buffers.h b/include/types/buffers.h
index 1bbea69..b5bd661 100644
--- a/include/types/buffers.h
+++ b/include/types/buffers.h
@@ -22,7 +22,7 @@
 #ifndef _TYPES_BUFFERS_H
 #define _TYPES_BUFFERS_H
 
-#include <common/defaults.h>
+#include <common/config.h>
 #include <common/memory.h>
 
 /* describes a chunk of string */
diff --git a/include/types/capture.h b/include/types/capture.h
index e531b54..d0271a2 100644
--- a/include/types/capture.h
+++ b/include/types/capture.h
@@ -22,6 +22,8 @@
 #ifndef _TYPES_CAPTURE_H
 #define _TYPES_CAPTURE_H
 
+#include <common/config.h>
+
 struct cap_hdr {
     struct cap_hdr *next;
     char *name;				/* header name, case insensitive */
diff --git a/include/types/client.h b/include/types/client.h
index d19e100..24f405f 100644
--- a/include/types/client.h
+++ b/include/types/client.h
@@ -22,6 +22,8 @@
 #ifndef _TYPES_CLIENT_H
 #define _TYPES_CLIENT_H
 
+#include <common/config.h>
+
 /*
  * FIXME: break this into HTTP state and TCP socket state.
  * See server.h for the other end.
diff --git a/include/types/fd.h b/include/types/fd.h
index 1b24be3..d0219dc 100644
--- a/include/types/fd.h
+++ b/include/types/fd.h
@@ -1,5 +1,5 @@
 /*
-  include/fd.h
+  include/types/fd.h
   File descriptors states.
 
   Copyright (C) 2000-2006 Willy Tarreau - w@1wt.eu
diff --git a/include/types/global.h b/include/types/global.h
index 4a2e895..681ac05 100644
--- a/include/types/global.h
+++ b/include/types/global.h
@@ -24,6 +24,7 @@
 
 #include <netinet/in.h>
 
+#include <common/config.h>
 #include <types/task.h>
 
 /* modes of operation (global.mode) */
diff --git a/include/types/httperr.h b/include/types/httperr.h
index 3a40a23..c594048 100644
--- a/include/types/httperr.h
+++ b/include/types/httperr.h
@@ -22,6 +22,8 @@
 #ifndef _TYPES_HTTPERR_H
 #define _TYPES_HTTPERR_H
 
+#include <common/config.h>
+
 /* various data sources for the responses */
 #define DATA_SRC_NONE	0
 #define DATA_SRC_STATS	1
diff --git a/include/types/log.h b/include/types/log.h
index 9aeb11e..dc04e65 100644
--- a/include/types/log.h
+++ b/include/types/log.h
@@ -22,6 +22,7 @@
 #ifndef _TYPES_LOG_H
 #define _TYPES_LOG_H
 
+#include <common/config.h>
 
 #define MAX_SYSLOG_LEN          1024
 #define NB_LOG_FACILITIES       24
diff --git a/include/types/proto_http.h b/include/types/proto_http.h
index 2ccee06..3cedc1e 100644
--- a/include/types/proto_http.h
+++ b/include/types/proto_http.h
@@ -22,6 +22,7 @@
 #ifndef _TYPES_PROTO_HTTP_H
 #define _TYPES_PROTO_HTTP_H
 
+#include <common/config.h>
 
 /*
  * FIXME: break this into HTTP state and TCP socket state.
diff --git a/include/types/proxy.h b/include/types/proxy.h
index d699bc1..306c31d 100644
--- a/include/types/proxy.h
+++ b/include/types/proxy.h
@@ -28,6 +28,7 @@
 
 #include <common/appsession.h>
 #include <common/chtbl.h>
+#include <common/config.h>
 #include <common/mini-clist.h>
 #include <common/regex.h>
 
diff --git a/include/types/queue.h b/include/types/queue.h
index 1e45b28..a8e7d8b 100644
--- a/include/types/queue.h
+++ b/include/types/queue.h
@@ -22,6 +22,7 @@
 #ifndef _TYPES_QUEUE_H
 #define _TYPES_QUEUE_H
 
+#include <common/config.h>
 #include <common/mini-clist.h>
 
 #include <types/server.h>
diff --git a/include/types/server.h b/include/types/server.h
index 7c62a3d..37b8af1 100644
--- a/include/types/server.h
+++ b/include/types/server.h
@@ -25,6 +25,7 @@
 #include <netinet/in.h>
 #include <arpa/inet.h>
 
+#include <common/config.h>
 #include <common/mini-clist.h>
 
 #include <types/buffers.h>
diff --git a/include/types/session.h b/include/types/session.h
index 8a5d0a4..477c425 100644
--- a/include/types/session.h
+++ b/include/types/session.h
@@ -28,6 +28,7 @@
 #include <netinet/in.h>
 #include <arpa/inet.h>
 
+#include <common/config.h>
 #include <common/mini-clist.h>
 
 #include <types/buffers.h>
diff --git a/include/types/task.h b/include/types/task.h
index 560a2fc..6b1df22 100644
--- a/include/types/task.h
+++ b/include/types/task.h
@@ -22,9 +22,9 @@
 #ifndef _TYPES_TASK_H
 #define _TYPES_TASK_H
 
-
 #include <sys/time.h>
 
+#include <common/config.h>
 
 /* values for task->state */
 #define TASK_IDLE	0
diff --git a/include/types/template.h b/include/types/template.h
index 8fa1ce5..e4292e7 100644
--- a/include/types/template.h
+++ b/include/types/template.h
@@ -22,6 +22,7 @@
 #ifndef _TYPES_TEMPLATE_H
 #define _TYPES_TEMPLATE_H
 
+#include <common/config.h>
 
 #endif /* _TYPES_TEMPLATE_H */
 
diff --git a/src/appsession.c b/src/appsession.c
index 58145e1..a63116d 100644
--- a/src/appsession.c
+++ b/src/appsession.c
@@ -15,6 +15,7 @@
 
 #include <common/appsession.h>
 #include <common/chtbl.h>
+#include <common/config.h>
 #include <common/list.h>
 #include <common/time.h>
 
diff --git a/src/backend.c b/src/backend.c
index df920a0..ff91ee3 100644
--- a/src/backend.c
+++ b/src/backend.c
@@ -17,6 +17,7 @@
 #include <syslog.h>
 
 #include <common/compat.h>
+#include <common/config.h>
 #include <common/time.h>
 
 #include <types/buffers.h>
diff --git a/src/base64.c b/src/base64.c
index d730328..005c486 100644
--- a/src/base64.c
+++ b/src/base64.c
@@ -11,6 +11,7 @@
  */
 
 #include <common/base64.h>
+#include <common/config.h>
 
 const char base64tab[64]="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
 
diff --git a/src/buffers.c b/src/buffers.c
index bbc1f28..5e71b53 100644
--- a/src/buffers.c
+++ b/src/buffers.c
@@ -11,6 +11,8 @@
  */
 
 #include <string.h>
+
+#include <common/config.h>
 #include <proto/buffers.h>
 
 void **pool_buffer   = NULL;
diff --git a/src/capture.c b/src/capture.c
index 3a7c2c6..c0c4a75 100644
--- a/src/capture.c
+++ b/src/capture.c
@@ -11,6 +11,8 @@
  */
 
 #include <stdlib.h>
+
+#include <common/config.h>
 #include <types/capture.h>
 
 void **pool_capture  = NULL;
diff --git a/src/chtbl.c b/src/chtbl.c
index 7773d40..08eebb8 100644
--- a/src/chtbl.c
+++ b/src/chtbl.c
@@ -18,6 +18,7 @@
 #include <stdlib.h>
 #include <string.h>
 
+#include <common/config.h>
 #include <common/list.h>
 #include <common/chtbl.h>
 
diff --git a/src/client.c b/src/client.c
index 31da594..f4f02e3 100644
--- a/src/client.c
+++ b/src/client.c
@@ -21,6 +21,7 @@
 #include <sys/types.h>
 
 #include <common/compat.h>
+#include <common/config.h>
 #include <common/time.h>
 
 #include <types/backend.h>
diff --git a/src/hashpjw.c b/src/hashpjw.c
index 69fa1b9..17ef3a2 100644
--- a/src/hashpjw.c
+++ b/src/hashpjw.c
@@ -16,6 +16,7 @@
 *                                                                            *
 *****************************************************************************/
 
+#include <common/config.h>
 #include <common/hashpjw.h>
 #include <common/appsession.h>
 
diff --git a/src/list.c b/src/list.c
index ae79a0c..f23686a 100644
--- a/src/list.c
+++ b/src/list.c
@@ -18,6 +18,7 @@
 #include <stdlib.h>
 #include <string.h>
 
+#include <common/config.h>
 #include <common/list.h>
 
 /*****************************************************************************
diff --git a/src/log.c b/src/log.c
index 34cf525..a9b0eff 100644
--- a/src/log.c
+++ b/src/log.c
@@ -20,6 +20,7 @@
 
 #include <sys/time.h>
 
+#include <common/config.h>
 #include <common/standard.h>
 
 #include <types/backend.h>
diff --git a/src/proxy.c b/src/proxy.c
index 19273db..c869be2 100644
--- a/src/proxy.c
+++ b/src/proxy.c
@@ -18,6 +18,7 @@
 
 #include <common/defaults.h>
 #include <common/compat.h>
+#include <common/config.h>
 #include <common/time.h>
 
 #include <types/global.h>
diff --git a/src/queue.c b/src/queue.c
index a12f313..3528537 100644
--- a/src/queue.c
+++ b/src/queue.c
@@ -10,6 +10,7 @@
  *
  */
 
+#include <common/config.h>
 #include <common/time.h>
 
 #include <types/proxy.h>
diff --git a/src/regex.c b/src/regex.c
index 9db3d10..7d6b30d 100644
--- a/src/regex.c
+++ b/src/regex.c
@@ -14,6 +14,7 @@
 #include <stdlib.h>
 #include <string.h>
 
+#include <common/config.h>
 #include <common/regex.h>
 #include <common/standard.h>
 #include <proto/log.h>
diff --git a/src/server.c b/src/server.c
index 50c025d..5b33d11 100644
--- a/src/server.c
+++ b/src/server.c
@@ -10,6 +10,7 @@
  *
  */
 
+#include <common/config.h>
 #include <types/backend.h>
 #include <types/proxy.h>
 #include <types/server.h>
diff --git a/src/session.c b/src/session.c
index e057b15..9a59e28 100644
--- a/src/session.c
+++ b/src/session.c
@@ -11,6 +11,8 @@
  */
 
 #include <stdlib.h>
+
+#include <common/config.h>
 #include <common/memory.h>
 
 #include <types/backend.h>
diff --git a/src/standard.c b/src/standard.c
index 7ddb88a..64357a2 100644
--- a/src/standard.c
+++ b/src/standard.c
@@ -16,6 +16,7 @@
 #include <netinet/in.h>
 #include <arpa/inet.h>
 
+#include <common/config.h>
 #include <common/standard.h>
 #include <proto/log.h>
 
diff --git a/src/stream_sock.c b/src/stream_sock.c
index d8a99bf..1c7fa59 100644
--- a/src/stream_sock.c
+++ b/src/stream_sock.c
@@ -20,6 +20,7 @@
 #include <sys/types.h>
 
 #include <common/compat.h>
+#include <common/config.h>
 #include <common/time.h>
 
 #include <types/backend.h>
diff --git a/src/time.c b/src/time.c
index e573b9d..5abfcc4 100644
--- a/src/time.c
+++ b/src/time.c
@@ -11,6 +11,8 @@
  */
 
 #include <sys/time.h>
+
+#include <common/config.h>
 #include <common/time.h>
 
 struct timeval now;             /* the current date at any moment */
diff --git a/src/uri_auth.c b/src/uri_auth.c
index 661419a..f666c0d 100644
--- a/src/uri_auth.c
+++ b/src/uri_auth.c
@@ -14,6 +14,7 @@
 #include <string.h>
 
 #include <common/base64.h>
+#include <common/config.h>
 #include <common/uri_auth.h>