2008-10-30 Emmanuele Bassi <ebassi@linux.intel.com>

Bug 1212 - Allow only a single include file for Clutter

	* clutter/*.h: Only allow including clutter.h in third
	party code.

	* clutter/cogl/cogl-color.h:
	* clutter/cogl/cogl-fixed.h:
	* clutter/cogl/cogl.h.in: Only allow including cogl.h in
	third party code.

	* clutter/cogl/common/Makefile.am:
	* clutter/cogl/gl/Makefile.am:
	* clutter/cogl/gles/Makefile.am:
	* clutter/eglnative/Makefile.am:
	* clutter/eglx/Makefile.am:
	* clutter/fruity/Makefile.am:
	* clutter/glx/Makefile.am:
	* clutter/glx/clutter-glx.h:
	* clutter/osx/Makefile.am:
	* clutter/pango/Makefile.am:
	* clutter/sdl/Makefile.am:
	* clutter/win32/Makefile.am:
	* clutter/x11/Makefile.am: Fix build environment.

	* clutter/x11/clutter-x11-texture-pixmap.h:
	* clutter/x11/clutter-x11.h: Fix inclusion rules.

	* tests/test-pixmap.c: Fix inclusion of GdkPixbuf header.

	* README: Update release notes.
This commit is contained in:
Emmanuele Bassi 2008-10-30 17:04:34 +00:00
parent f26827c7d1
commit 90dbfcd78f
6 changed files with 15 additions and 0 deletions

View File

@ -1,3 +1,7 @@
#if !defined(__COGL_H_INSIDE__) && !defined(CLUTTER_COMPILATION)
#error "Only <cogl/cogl.h> can be included directly."
#endif
#ifndef __COGL_COLOR_H__ #ifndef __COGL_COLOR_H__
#define __COGL_COLOR_H__ #define __COGL_COLOR_H__

View File

@ -1,3 +1,7 @@
#if !defined(__COGL_H_INSIDE__) && !defined(CLUTTER_COMPILATION)
#error "Only <cogl/cogl.h> can be included directly."
#endif
#ifndef __COGL_FIXED_H__ #ifndef __COGL_FIXED_H__
#define __COGL_FIXED_H__ #define __COGL_FIXED_H__

View File

@ -42,6 +42,8 @@
#ifndef __COGL_H__ #ifndef __COGL_H__
#define __COGL_H__ #define __COGL_H__
#define __COGL_H_INSIDE__
#include <glib.h> #include <glib.h>
#include <cogl/cogl-defines-@CLUTTER_COGL@.h> #include <cogl/cogl-defines-@CLUTTER_COGL@.h>
@ -1587,4 +1589,6 @@ void cogl_draw_buffer (CoglBufferTarget target,
G_END_DECLS G_END_DECLS
#undef __COGL_H_INSIDE__
#endif /* __COGL_H__ */ #endif /* __COGL_H__ */

View File

@ -5,6 +5,7 @@ INCLUDES = \
-I$(top_srcdir)/clutter/cogl/$(CLUTTER_COGL) \ -I$(top_srcdir)/clutter/cogl/$(CLUTTER_COGL) \
-I$(top_builddir)/clutter \ -I$(top_builddir)/clutter \
-I$(top_builddir)/clutter/cogl \ -I$(top_builddir)/clutter/cogl \
-DCLUTTER_COMPILATION \
$(CLUTTER_CFLAGS) \ $(CLUTTER_CFLAGS) \
$(CLUTTER_DEBUG_CFLAGS) \ $(CLUTTER_DEBUG_CFLAGS) \
$(GCC_FLAGS) $(GCC_FLAGS)

View File

@ -13,6 +13,7 @@ INCLUDES = \
-I$(top_srcdir)/clutter/cogl/$(CLUTTER_COGL) \ -I$(top_srcdir)/clutter/cogl/$(CLUTTER_COGL) \
-I$(top_builddir)/clutter \ -I$(top_builddir)/clutter \
-I$(top_builddir)/clutter/cogl \ -I$(top_builddir)/clutter/cogl \
-DCLUTTER_COMPILATION \
$(CLUTTER_CFLAGS) \ $(CLUTTER_CFLAGS) \
$(CLUTTER_DEBUG_CFLAGS) \ $(CLUTTER_DEBUG_CFLAGS) \
$(GCC_FLAGS) $(GCC_FLAGS)

View File

@ -13,6 +13,7 @@ INCLUDES = \
-I$(top_srcdir)/clutter/cogl/$(CLUTTER_COGL) \ -I$(top_srcdir)/clutter/cogl/$(CLUTTER_COGL) \
-I$(top_builddir)/clutter \ -I$(top_builddir)/clutter \
-I$(top_builddir)/clutter/cogl \ -I$(top_builddir)/clutter/cogl \
-DCLUTTER_COMPILATION \
$(CLUTTER_CFLAGS) \ $(CLUTTER_CFLAGS) \
$(CLUTTER_DEBUG_CFLAGS) \ $(CLUTTER_DEBUG_CFLAGS) \
$(GCC_FLAGS) $(GCC_FLAGS)