diff options
author | Ran Benita <ran234@gmail.com> | 2012-04-06 03:12:50 +0300 |
---|---|---|
committer | Daniel Stone <daniel@fooishbar.org> | 2012-04-09 14:16:17 +0100 |
commit | 8fbd44fde6c54e5f646e619e51a6e846e3c6f95b (patch) | |
tree | b780b16194a7b10b3ea532d2721e9f60acfec9c4 | |
parent | 5df53e494423cecff14d3773405b4d2d28130485 (diff) | |
download | xorg-lib-libxkbcommon-8fbd44fde6c54e5f646e619e51a6e846e3c6f95b.tar.gz |
Implicitly include config.h in all files
The definitions in config.h should be available in all files an
implementation detail; it can be included through the build system
instead of having each file pull it every time.
This is especially helpful with AC_USE_SYSTEM_EXTENSIONS, as _GNU_SOURCE
and friends can have an effect by merely being defined, which can lead
to some confusion if its effective for only half the files.
And we don't really support a build _without_ config.h; so, one less
thing to worry about.
Signed-off-by: Ran Benita <ran234@gmail.com>
-rw-r--r-- | Makefile.am | 3 | ||||
-rw-r--r-- | src/alloc.c | 3 | ||||
-rw-r--r-- | src/atom.c | 3 | ||||
-rw-r--r-- | src/context.c | 4 | ||||
-rw-r--r-- | src/keysym.c | 3 | ||||
-rw-r--r-- | src/map.c | 4 | ||||
-rw-r--r-- | src/maprules.c | 3 | ||||
-rw-r--r-- | src/misc.c | 6 | ||||
-rw-r--r-- | src/state.c | 4 | ||||
-rw-r--r-- | src/text.c | 3 | ||||
-rw-r--r-- | src/utils.h | 4 | ||||
-rw-r--r-- | src/xkb.c | 3 |
12 files changed, 2 insertions, 41 deletions
diff --git a/Makefile.am b/Makefile.am index 6aa5b8e..0564a7c 100644 --- a/Makefile.am +++ b/Makefile.am @@ -22,7 +22,8 @@ AM_CPPFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/src \ -I$(top_srcdir)/src/xkbcomp \ - -Isrc/xkbcomp + -Isrc/xkbcomp/ \ + -include $(top_srcdir)/src/config.h AM_CFLAGS = \ $(BASE_CFLAGS) \ diff --git a/src/alloc.c b/src/alloc.c index a2a1330..91b010b 100644 --- a/src/alloc.c +++ b/src/alloc.c @@ -23,9 +23,6 @@ OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif #include "utils.h" #include "xkballoc.h" #include "xkbcommon/xkbcommon.h" @@ -70,9 +70,6 @@ SOFTWARE. ********************************************************/ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif #include "xkbmisc.h" #include "xkbcommon/xkbcommon.h" #include "XKBcommonint.h" diff --git a/src/context.c b/src/context.c index 8878b16..9acb416 100644 --- a/src/context.c +++ b/src/context.c @@ -23,10 +23,6 @@ * Author: Daniel Stone <daniel@fooishbar.org> */ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include <sys/types.h> #include <sys/stat.h> #include <stdio.h> diff --git a/src/keysym.c b/src/keysym.c index 8f6515d..5079419 100644 --- a/src/keysym.c +++ b/src/keysym.c @@ -25,9 +25,6 @@ sale, use or other dealings in this Software without prior written authorization from the authors. */ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif #include <stdlib.h> #include <stdio.h> #include <string.h> @@ -49,10 +49,6 @@ * * ********************************************************/ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include "utils.h" #include "xkbcommon/xkbcommon.h" #include "XKBcommonint.h" diff --git a/src/maprules.c b/src/maprules.c index 6a6e616..dd80bd3 100644 --- a/src/maprules.c +++ b/src/maprules.c @@ -24,9 +24,6 @@ ********************************************************/ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif #include "utils.h" #include "xkbrules.h" #include "xkbcommon/xkbcommon.h" @@ -24,12 +24,6 @@ THE USE OR PERFORMANCE OF THIS SOFTWARE. ********************************************************/ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - -#include <X11/X.h> - #include "xkballoc.h" #include "xkbmisc.h" #include "xkbcommon/xkbcommon.h" diff --git a/src/state.c b/src/state.c index 2feaeb5..45820b6 100644 --- a/src/state.c +++ b/src/state.c @@ -58,10 +58,6 @@ THE USE OR PERFORMANCE OF THIS SOFTWARE. * - messages (very unlikely) */ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include <assert.h> #include "xkbcommon/xkbcommon.h" @@ -24,9 +24,6 @@ ********************************************************/ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif #include "xkbmisc.h" #include "xkbcommon/xkbcommon.h" #include "XKBcommonint.h" diff --git a/src/utils.h b/src/utils.h index 630fa48..01c6ba4 100644 --- a/src/utils.h +++ b/src/utils.h @@ -33,10 +33,6 @@ #include <X11/Xdefs.h> #include <X11/Xfuncproto.h> -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - extern void * recalloc(void *ptr, size_t old_size, size_t new_size); @@ -24,9 +24,6 @@ THE USE OR PERFORMANCE OF THIS SOFTWARE. ********************************************************/ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif #include <stdio.h> #include "xkbmisc.h" |