From 8dd8fbdbdf940258ff6b5ce616534bf8f8fd356a Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Mon, 13 Sep 2010 11:30:30 +0100 Subject: [PATCH] build: Start moving to a non-recursive layout MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit *** WARNING: THIS COMMIT CHANGES THE BUILD *** Do not recurse into the backend directories to build private, internal libraries. We only recurse from clutter/ into the cogl sub-directory; from there, we don't recurse any further. All the backend-specific code in Cogl and Clutter is compiled conditionally depending on the macros defined by the configure script. We still recurse from the top-level directory into doc, clutter and tests, because gtk-doc and tests do not deal nicely with non-recursive layouts. This change makes Clutter compile slightly faster, and cleans up the build system, especially when dealing with introspection data. Ideally, we also want to make Cogl part of the top-level build, so that we can finally drop the sed trick to change the shared library from the GIR before compiling it. Currently disabled: ‣ OSX backend ‣ Fruity backend Currently enabled but untested: ‣ EGL backend ‣ Windows backend --- .gitignore | 7 +- Makefile.am | 19 +- autogen.sh | 1 - build/Makefile.am | 2 +- .../cogl/driver/gles => build}/stringify.sh | 0 clutter/Makefile.am | 521 +++++++++++++----- clutter/cally/Makefile.am | 80 --- clutter/cally/cally.pc.in | 9 +- clutter.pc.in => clutter/clutter.pc.in | 0 clutter/cogl/cogl/Makefile.am | 180 +++--- clutter/cogl/cogl/cogl-context.h | 10 +- clutter/cogl/cogl/cogl-material-arbfp.c | 9 +- clutter/cogl/cogl/cogl-material-fixed.c | 9 +- clutter/cogl/cogl/cogl-material-glsl.c | 8 +- clutter/cogl/cogl/cogl-material-opengl.c | 9 +- clutter/cogl/cogl/driver/gl/Makefile.am | 34 -- ...text-driver.c => cogl-context-driver-gl.c} | 2 +- ...text-driver.h => cogl-context-driver-gl.h} | 2 +- ...unctions.h => cogl-feature-functions-gl.h} | 0 .../cogl/cogl/driver/gl/{cogl.c => cogl-gl.c} | 4 +- .../gl/{cogl-program.c => cogl-program-gl.c} | 2 +- .../gl/{cogl-program.h => cogl-program-gl.h} | 0 ...ture-driver.c => cogl-texture-driver-gl.c} | 0 clutter/cogl/cogl/driver/gles/Makefile.am | 57 -- ...xt-driver.c => cogl-context-driver-gles.c} | 2 +- ...xt-driver.h => cogl-context-driver-gles.h} | 2 +- ...ctions.h => cogl-feature-functions-gles.h} | 0 .../cogl/driver/gles/{cogl.c => cogl-gles.c} | 2 +- .../cogl/driver/gles/cogl-gles2-wrapper.c | 1 - .../cogl/driver/gles/cogl-gles2-wrapper.h | 2 +- .../{cogl-program.c => cogl-program-gles.c} | 2 +- .../{cogl-program.h => cogl-program-gles.h} | 0 ...re-driver.c => cogl-texture-driver-gles.c} | 0 clutter/egl/Makefile.am | 46 -- clutter/glx/Makefile.am | 36 -- clutter/json/Makefile.am | 39 -- clutter/win32/Makefile.am | 38 -- clutter/win32/clutter-win32.pc.in | 16 - clutter/x11/Makefile.am | 74 --- clutter/x11/clutter-backend-x11.c | 16 +- clutter/x11/clutter-x11-enum-types.c.in | 31 -- clutter/x11/clutter-x11-enum-types.h.in | 26 - clutter/x11/clutter-x11.h | 1 - clutter/x11/clutter-x11.pc.in | 16 - configure.ac | 102 ++-- 45 files changed, 596 insertions(+), 821 deletions(-) rename {clutter/cogl/cogl/driver/gles => build}/stringify.sh (100%) delete mode 100644 clutter/cally/Makefile.am rename clutter.pc.in => clutter/clutter.pc.in (100%) delete mode 100644 clutter/cogl/cogl/driver/gl/Makefile.am rename clutter/cogl/cogl/driver/gl/{cogl-context-driver.c => cogl-context-driver-gl.c} (96%) rename clutter/cogl/cogl/driver/gl/{cogl-context-driver.h => cogl-context-driver-gl.h} (97%) rename clutter/cogl/cogl/driver/gl/{cogl-feature-functions.h => cogl-feature-functions-gl.h} (100%) rename clutter/cogl/cogl/driver/gl/{cogl.c => cogl-gl.c} (98%) rename clutter/cogl/cogl/driver/gl/{cogl-program.c => cogl-program-gl.c} (99%) rename clutter/cogl/cogl/driver/gl/{cogl-program.h => cogl-program-gl.h} (100%) rename clutter/cogl/cogl/driver/gl/{cogl-texture-driver.c => cogl-texture-driver-gl.c} (100%) delete mode 100644 clutter/cogl/cogl/driver/gles/Makefile.am rename clutter/cogl/cogl/driver/gles/{cogl-context-driver.c => cogl-context-driver-gles.c} (96%) rename clutter/cogl/cogl/driver/gles/{cogl-context-driver.h => cogl-context-driver-gles.h} (97%) rename clutter/cogl/cogl/driver/gles/{cogl-feature-functions.h => cogl-feature-functions-gles.h} (100%) rename clutter/cogl/cogl/driver/gles/{cogl.c => cogl-gles.c} (98%) rename clutter/cogl/cogl/driver/gles/{cogl-program.c => cogl-program-gles.c} (99%) rename clutter/cogl/cogl/driver/gles/{cogl-program.h => cogl-program-gles.h} (100%) rename clutter/cogl/cogl/driver/gles/{cogl-texture-driver.c => cogl-texture-driver-gles.c} (100%) delete mode 100644 clutter/egl/Makefile.am delete mode 100644 clutter/glx/Makefile.am delete mode 100644 clutter/json/Makefile.am delete mode 100644 clutter/win32/Makefile.am delete mode 100644 clutter/win32/clutter-win32.pc.in delete mode 100644 clutter/x11/Makefile.am delete mode 100644 clutter/x11/clutter-x11-enum-types.c.in delete mode 100644 clutter/x11/clutter-x11-enum-types.h.in delete mode 100644 clutter/x11/clutter-x11.pc.in diff --git a/.gitignore b/.gitignore index 7917da26a..bc37555b3 100644 --- a/.gitignore +++ b/.gitignore @@ -5,8 +5,7 @@ Makefile.in aclocal.m4 autom4te.cache compile -clutter-*.pc -clutter.pc +*.pc .deps .libs *.o @@ -22,16 +21,12 @@ stamp-marshal /clutter/gcov-report.txt /clutter/clutter-json.h /clutter/cogl/cogl/cogl-defines.h -/clutter/cogl/cogl/*.pc /clutter/cogl/cogl/cogl-enum-types.[ch] /clutter/cogl/cogl/driver/gl/cogl-defines.h /clutter/cogl/cogl/driver/gles/cogl-defines.h /clutter/cogl/cogl/driver/gles/cogl-fixed-vertex-shader.[ch] /clutter/cogl/cogl/driver/gles/cogl-fixed-fragment-shader.[ch] /clutter/egl/clutter-cex100.h -/clutter/x11/clutter-x11-enum-types.[ch] -/clutter/json/*.gir -/clutter/cally/cally*.pc /build/autotools/*.m4 !/build/autotools/introspection.m4 !/build/autotools/as-linguas.m4 diff --git a/Makefile.am b/Makefile.am index 40524ba0e..338cf3803 100644 --- a/Makefile.am +++ b/Makefile.am @@ -6,29 +6,12 @@ SUBDIRS = build clutter tests doc po ACLOCAL_AMFLAGS = -I build/autotools -pcfiles = \ - clutter-$(CLUTTER_API_VERSION).pc \ - clutter-$(CLUTTER_SONAME_INFIX)-$(CLUTTER_API_VERSION).pc \ - $(NULL) - -# clutter-..pc - for generic dependencies -clutter-$(CLUTTER_API_VERSION).pc: clutter.pc - $(QUIET_GEN)cp $< $@ - -# clutter--..pc - for backend-specific dependencies -clutter-$(CLUTTER_SONAME_INFIX)-$(CLUTTER_API_VERSION).pc: clutter.pc - $(QUIET_GEN)cp $< $@ - .PHONY: test-report full-report test-report full-report: $(MAKE) -C tests/conform $(@) -pkgconfig_DATA = $(pcfiles) -pkgconfigdir = $(libdir)/pkgconfig - -EXTRA_DIST = \ +EXTRA_DIST = \ ChangeLog.pre-git-import \ - clutter.pc.in \ $(NULL) CLEANFILES = $(pcfiles) diff --git a/autogen.sh b/autogen.sh index 58cf7eaa7..a31ce04d1 100755 --- a/autogen.sh +++ b/autogen.sh @@ -115,6 +115,5 @@ cd $ORIGDIR || exit $? if test -z "$NOCONFIGURE"; then $srcdir/configure $AUTOGEN_CONFIGURE_ARGS "$@" || exit $? - echo "Now type 'make' to compile $PROJECT." fi diff --git a/build/Makefile.am b/build/Makefile.am index d8669fd29..7ec16fcfc 100644 --- a/build/Makefile.am +++ b/build/Makefile.am @@ -1,3 +1,3 @@ SUBDIRS = autotools mingw -EXTRA_DIST = gen-gcov.pl +EXTRA_DIST = gen-gcov.pl stringify.sh diff --git a/clutter/cogl/cogl/driver/gles/stringify.sh b/build/stringify.sh similarity index 100% rename from clutter/cogl/cogl/driver/gles/stringify.sh rename to build/stringify.sh diff --git a/clutter/Makefile.am b/clutter/Makefile.am index f8e35e375..38772aeef 100644 --- a/clutter/Makefile.am +++ b/clutter/Makefile.am @@ -1,18 +1,10 @@ include $(top_srcdir)/build/autotools/Makefile.am.silent +# preamble NULL = -SUBDIRS = cogl $(CLUTTER_WINSYS_BASE) $(CLUTTER_WINSYS) cally - -if LOCAL_JSON_GLIB -SUBDIRS += json -clutter_json_include = -I$(top_srcdir)/clutter/json -clutter_json_dep = json/libclutter-json.la -clutter_json_libadd = $(top_builddir)/clutter/json/libclutter-json.la -clutter_json_gir = ClutterJson-@CLUTTER_API_VERSION@.gir -endif - -DIST_SUBDIRS = glx egl cogl json osx x11 win32 fruity cally +# we recurse only into Cogl +SUBDIRS = cogl # common definitions CLEANFILES = @@ -20,30 +12,16 @@ DISTCLEANFILES = EXTRA_DIST = BUILT_SOURCES = -if SUPPORT_WIN32 - -# Ideally this resources stuff would go in win32/ but libtool doesn't -# seem to pass on the -Wl argument when linking a convenience library -# so we need to do it here as part of linking the dll. libtool also -# won't let you link against the .o directly because it wants you to -# link against libtool objects for dynamic libraries. -.rc.o : - $(WINDRES) -I$(srcdir)/win32 $< $@ - -win32/resources.o : $(srcdir)/win32/invisible-cursor.cur - -win32_resources = win32/resources.o -win32_resources_ldflag = -Wl,win32/resources.o - -endif # SUPPORT_WIN32 +lib_LTLIBRARIES = INCLUDES = \ -I$(top_srcdir) \ - -I$(top_srcdir)/clutter/cally \ + -I$(top_srcdir)/clutter \ -I$(top_srcdir)/clutter/cogl \ -I$(top_srcdir)/clutter/cogl/pango \ - -I$(top_srcdir)/clutter \ - $(clutter_json_include) \ + -I$(top_srcdir)/clutter/$(CLUTTER_WINSYS) \ + -I$(top_srcdir)/clutter/$(CLUTTER_WINSYS_BASE) \ + -I$(top_srcdir)/clutter/cally \ -I$(top_builddir) \ -I$(top_builddir)/clutter \ -I$(top_builddir)/clutter/cogl \ @@ -66,7 +44,19 @@ AM_CPPFLAGS = \ AM_CFLAGS = $(CLUTTER_CFLAGS) $(MAINTAINER_CFLAGS) $(GCOV_CFLAGS) -# please, keep this sorted alphabetically +# these are the gir files we generate by hand +BUILT_GIRSOURCES = + +# these are the gir files we generate using g-ir-scanner +INTROSPECTION_GIRS = + +# the base include path for headers +clutter_includedir = $(includedir)/clutter-$(CLUTTER_API_VERSION)/clutter + +# pkg-config files +pc_files = + +# common sources - please, keep these sorted alphabetically source_h = \ $(srcdir)/clutter-action.h \ $(srcdir)/clutter-actor-meta.h \ @@ -146,22 +136,6 @@ source_h = \ $(srcdir)/clutter-util.h \ $(NULL) -built_source_h = \ - clutter-enum-types.h \ - clutter-marshal.h - -# glib-genmarshal rules -glib_marshal_list = clutter-marshal.list -glib_marshal_prefix = _clutter_marshal -include $(top_srcdir)/build/autotools/Makefile.am.marshal - -# glib-mkenums rules -glib_enum_h = clutter-enum-types.h -glib_enum_c = clutter-enum-types.c -glib_enum_headers = $(source_h) -include $(top_srcdir)/build/autotools/Makefile.am.enums - -# please, keep this sorted alphabetically source_c = \ $(srcdir)/clutter-action.c \ $(srcdir)/clutter-actor-meta.c \ @@ -240,16 +214,7 @@ source_c = \ $(srcdir)/clutter-util.c \ $(NULL) -source_c_priv = \ - $(srcdir)/clutter-id-pool.c \ - $(srcdir)/clutter-profile.c \ - $(srcdir)/clutter-timeout-interval.c \ - $(NULL) - -built_source_c = \ - clutter-enum-types.c \ - clutter-marshal.c - +# private headers; these should not be distributed or introspected source_h_priv = \ $(srcdir)/clutter-actor-meta-private.h \ $(srcdir)/clutter-bezier.h \ @@ -264,32 +229,341 @@ source_h_priv = \ $(srcdir)/clutter-timeout-interval.h \ $(NULL) +# private source code; these should not be introspected +source_c_priv = \ + $(srcdir)/clutter-id-pool.c \ + $(srcdir)/clutter-profile.c \ + $(srcdir)/clutter-timeout-interval.c \ + $(NULL) + +# built sources +built_source_c = \ + clutter-enum-types.c \ + clutter-marshal.c \ + $(NULL) + +# built headers +built_source_h = \ + clutter-enum-types.h \ + clutter-marshal.h \ + $(NULL) + +# version header +DISTCLEANFILES += clutter-version.h +EXTRA_DIST += clutter-version.h.in + +# key symbol update script +EXTRA_DIST += clutter-keysyms-update.pl + +pc_files += clutter-$(CLUTTER_API_VERSION).pc + +# backends source listings +# +# backend_source_c := source code +# backend_source_h := installed public headers +# backend_source_c_priv := source that should not be scanned by g-i +# backend_source_h_priv := private headers +# backend_source_built := built sources +# +backend_source_c = +backend_source_h = +backend_source_c_priv = +backend_source_h_priv = +backend_source_built = + +# X11 backend rules +if SUPPORT_X11 +x11_source_c = \ + $(srcdir)/x11/clutter-backend-x11.c \ + $(srcdir)/x11/clutter-device-manager-x11.c \ + $(srcdir)/x11/clutter-event-x11.c \ + $(srcdir)/x11/clutter-input-device-x11.c \ + $(srcdir)/x11/clutter-keymap-x11.c \ + $(srcdir)/x11/clutter-stage-x11.c \ + $(srcdir)/x11/clutter-x11-texture-pixmap.c \ + $(NULL) + +x11_source_h = \ + $(srcdir)/x11/clutter-x11.h \ + $(srcdir)/x11/clutter-x11-texture-pixmap.h \ + $(NULL) + +backend_source_h_priv += \ + $(srcdir)/x11/clutter-backend-x11.h \ + $(srcdir)/x11/clutter-device-manager-x11.h \ + $(srcdir)/x11/clutter-input-device-x11.h \ + $(srcdir)/x11/clutter-keymap-x11.h \ + $(srcdir)/x11/clutter-settings-x11.h \ + $(srcdir)/x11/clutter-stage-x11.h \ + $(NULL) + +backend_source_c_priv += \ + $(srcdir)/x11/xsettings/xsettings-client.c \ + $(srcdir)/x11/xsettings/xsettings-client.h \ + $(srcdir)/x11/xsettings/xsettings-common.c \ + $(srcdir)/x11/xsettings/xsettings-common.h \ + $(NULL) + +backend_source_h += $(x11_source_h) +backend_source_c += $(x11_source_c) + +# the list of files we want to introspect on X11 +x11_introspection = $(x11_source_c) $(x11_source_h) + +# pkg-config file for the X11 meta-backend +clutter-x11-$(CLUTTER_API_VERSION).pc: clutter-$(CLUTTER_API_VERSION).pc + $(QUIET_GEN)cp -f $< $(@F) + +pc_files += clutter-x11-$(CLUTTER_API_VERSION).pc + +clutterx11_includedir = $(clutter_includedir)/x11 +clutterx11_include_HEADERS = $(x11_source_h) +endif # SUPPORT_X11 + +# GLX backend rules +if SUPPORT_GLX +glx_source_c = \ + $(srcdir)/glx/clutter-backend-glx.c \ + $(srcdir)/glx/clutter-event-glx.c \ + $(srcdir)/glx/clutter-glx-texture-pixmap.c \ + $(srcdir)/glx/clutter-stage-glx.c \ + $(NULL) + +glx_source_h = \ + $(srcdir)/glx/clutter-glx-texture-pixmap.h \ + $(srcdir)/glx/clutter-glx.h \ + $(NULL) + +backend_source_h_priv += \ + $(srcdir)/glx/clutter-backend-glx.h \ + $(srcdir)/glx/clutter-event-glx.h \ + $(srcdir)/glx/clutter-stage-glx.h \ + $(NULL) + +backend_source_h += $(glx_source_h) +backend_source_c += $(glx_source_c) + +# XXX - this is another hack; we installed glx headers under includedir/glx +# instead of using the same directory. +clutterglx_includedir = $(clutter_includedir)/glx +clutterglx_include_HEADERS = $(glx_source_h) +endif # SUPPORT_GLX + +# Windows backend rules +if SUPPORT_WIN32 +# Ideally this resources stuff would go in win32/ but libtool doesn't +# seem to pass on the -Wl argument when linking a convenience library +# so we need to do it here as part of linking the dll. libtool also +# won't let you link against the .o directly because it wants you to +# link against libtool objects for dynamic libraries. +.rc.o : + $(WINDRES) -I$(srcdir)/win32 $< $@ + +win32/resources.o : $(srcdir)/win32/invisible-cursor.cur + +win32_resources = win32/resources.o +win32_resources_ldflag = -Wl,win32/resources.o + +win32_source_c = \ + $(srcdir)/win32/clutter-backend-win32.c \ + $(srcdir)/win32/clutter-device-manager-win32.c \ + $(srcdir)/win32/clutter-event-win32.c \ + $(srcdir)/win32/clutter-stage-win32.c \ + $(NULL) + +win32_source_h = \ + $(srcdir)/win32/clutter-win32.h \ + $(NULL) + +backend_source_h_priv += \ + $(srcdir)/win32/clutter-backend-win32.h \ + $(srcdir)/win32/clutter-device-manager-win32.h \ + $(srcdir)/win32/clutter-stage-win32.h \ + $(NULL) + +backend_source_h += $(win32_source_h) +backend_source_c += $(win32_source_c) + +clutterwin_includedir = $(clutter_includedir)/win32 +clutterwin_include_HEADERS = $(win32_source_h) + +EXTRA_DIST += invisible-cursor.cur resources.rc +endif # SUPPORT_WIN32 + +# EGL backend rules +if SUPPORT_EGL +egl_source_h = \ + $(srcdir)/egl/clutter-egl-headers.h \ + $(srcdir)/egl/clutter-egl.h \ + $(NULL) + +backend_source_c += \ + $(srcdir)/egl/clutter-backend-egl.c \ + $(srcdir)/egl/clutter-stage-egl.c \ + $(NULL) + +backend_source_h_priv += \ + $(srcdir)/egl/clutter-backend-egl.h \ + $(srcdir)/egl/clutter-stage-egl.h \ + $(NULL) + +if USE_TSLIB +backend_source_c_priv += $(srcdir)/egl/clutter-event-tslib.c +endif # SUPPORT_TSLIB + +if SUPPORT_CEX100 +backend_source_h_priv += $(srcdir)/egl/clutter-backend-cex100.h +backend_source_c_priv += $(srcdir)/egl/clutter-backend-cex100.c + +egl_source_h += $(srcdir)/egl/clutter-cex100.h +endif # SUPPORT_CEX100 + +backend_source_h += $(egl_source_h) + +clutteregl_includedir = $(clutter_includedir)/egl +clutteregl_include_HEADERS = $(egl_source_h) +endif # SUPPORT_EGL + +# OSX backend rules +if SUPPORT_OSX + +endif # SUPPORT_OSX + +# Fruity backend rules +if SUPPORT_FRUITY + +endif # SUPPORT_FRUITY + +# cally +cally_sources_h = \ + $(srcdir)/cally/cally-actor.h \ + $(srcdir)/cally/cally-clone.h \ + $(srcdir)/cally/cally-factory.h \ + $(srcdir)/cally/cally-group.h \ + $(srcdir)/cally/cally.h \ + $(srcdir)/cally/cally-main.h \ + $(srcdir)/cally/cally-rectangle.h \ + $(srcdir)/cally/cally-root.h \ + $(srcdir)/cally/cally-stage.h \ + $(srcdir)/cally/cally-text.h \ + $(srcdir)/cally/cally-texture.h \ + $(srcdir)/cally/cally-util.h \ + $(NULL) + +cally_sources_c = \ + $(srcdir)/cally/cally-actor.c \ + $(srcdir)/cally/cally.c \ + $(srcdir)/cally/cally-clone.c \ + $(srcdir)/cally/cally-group.c \ + $(srcdir)/cally/cally-rectangle.c \ + $(srcdir)/cally/cally-root.c \ + $(srcdir)/cally/cally-stage.c \ + $(srcdir)/cally/cally-text.c \ + $(srcdir)/cally/cally-texture.c \ + $(srcdir)/cally/cally-util.c \ + $(NULL) + +cally_sources_private = \ + $(srcdir)/cally/cally-actor-private.h \ + $(NULL) + +cally_includedir = $(clutter_includedir)/cally +cally_include_HEADERS = $(cally_sources_h) + +pc_files += cally/cally-$(CLUTTER_API_VERSION).pc +EXTRA_DIST += cally/cally.pc.in + +# json +if LOCAL_JSON_GLIB +json_gir = ClutterJson-@CLUTTER_API_VERSION@.gir +json_gir_include = --include-uninstalled=$(top_builddir)/clutter/ClutterJson-@CLUTTER_API_VERSION@.gir + +json_sources_h = \ + $(srcdir)/json/json-generator.h \ + $(srcdir)/json/json-glib.h \ + $(srcdir)/json/json-parser.h \ + $(srcdir)/json/json-types.h \ + $(NULL) + +json_sources_c = \ + $(srcdir)/json/json-array.c \ + $(srcdir)/json/json-node.c \ + $(srcdir)/json/json-object.c \ + $(srcdir)/json/json-parser.c \ + $(NULL) + +json_sources_priv = \ + $(srcdir)/json/json-marshal.c \ + $(srcdir)/json/json-marshal.h \ + $(srcdir)/json/json-types-private.h \ + $(NULL) + +INCLUDES += $(top_srcdir)/clutter/json +else +json_gir_include=--include=Json-1.0 +endif # LOCAL_JSON_GLIB + +# general build rules: +# you should not need to modify anything below this point + +# glib-genmarshal rules +glib_marshal_list = clutter-marshal.list +glib_marshal_prefix = _clutter_marshal +include $(top_srcdir)/build/autotools/Makefile.am.marshal + +# glib-mkenums rules +glib_enum_h = clutter-enum-types.h +glib_enum_c = clutter-enum-types.c +glib_enum_headers = $(source_h) $(backend_source_h) +include $(top_srcdir)/build/autotools/Makefile.am.enums + +# backend-specific pkg-config file +clutter-$(CLUTTER_WINSYS)-$(CLUTTER_API_VERSION).pc: clutter-$(CLUTTER_API_VERSION).pc + $(QUIET_GEN)cp -f $< $(@F) + +pc_files += clutter-$(CLUTTER_WINSYS)-$(CLUTTER_API_VERSION).pc + +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = $(pc_files) +DISTCLEANFILES += $(pc_files) + +clutter_include_HEADERS = $(source_h) $(top_srcdir)/clutter/clutter.h +nodist_clutter_include_HEADERS = \ + $(top_builddir)/clutter/clutter-json.h \ + $(top_builddir)/clutter/clutter-version.h \ + $(built_source_h) + +lib_LTLIBRARIES += libclutter-@CLUTTER_SONAME_INFIX@-@CLUTTER_API_VERSION@.la + libclutter_@CLUTTER_SONAME_INFIX@_@CLUTTER_API_VERSION@_la_LIBADD = \ $(CLUTTER_LIBS) \ - $(top_builddir)/clutter/cally/libcally.la \ $(top_builddir)/clutter/cogl/cogl/libclutter-cogl.la \ - $(top_builddir)/clutter/cogl/pango/libcoglpango.la \ - $(top_builddir)/clutter/$(CLUTTER_WINSYS)/libclutter-$(CLUTTER_WINSYS).la \ - $(clutter_json_libadd) \ - $(CLUTTER_WINSYS_BASE_LIB) - + $(top_builddir)/clutter/cogl/pango/libcoglpango.la libclutter_@CLUTTER_SONAME_INFIX@_@CLUTTER_API_VERSION@_la_DEPENDENCIES = \ - $(top_builddir)/clutter/cally/libcally.la \ $(top_builddir)/clutter/cogl/cogl/libclutter-cogl.la \ $(top_builddir)/clutter/cogl/pango/libcoglpango.la \ - $(top_builddir)/clutter/$(CLUTTER_WINSYS)/libclutter-$(CLUTTER_WINSYS).la \ - $(clutter_json_dep) \ - $(CLUTTER_WINSYS_BASE_LIB) \ $(win32_resources) libclutter_@CLUTTER_SONAME_INFIX@_@CLUTTER_API_VERSION@_la_SOURCES = \ + $(backend_source_c) \ + $(backend_source_h) \ + $(backend_source_c_priv) \ + $(backend_source_h_priv) \ $(source_c) \ $(source_h) \ $(source_c_priv) \ - $(source_h_priv) + $(source_h_priv) \ + $(cally_sources_c) \ + $(cally_sources_h) \ + $(cally_sources_private) \ + $(json_sources_c) \ + $(json_sources_h) \ + $(json_sources_priv) \ + $(NULL) nodist_libclutter_@CLUTTER_SONAME_INFIX@_@CLUTTER_API_VERSION@_la_SOURCES = \ + $(backend_source_built) \ $(built_source_c) \ $(built_source_h) @@ -303,51 +577,7 @@ libclutter_@CLUTTER_SONAME_INFIX@_@CLUTTER_API_VERSION@_la_LDFLAGS = \ $(win32_resources_ldflag) \ $(NULL) -lib_LTLIBRARIES = libclutter-@CLUTTER_SONAME_INFIX@-@CLUTTER_API_VERSION@.la - -clutterdir = $(includedir)/clutter-$(CLUTTER_API_VERSION)/clutter -clutter_HEADERS = \ - $(source_h) \ - $(top_srcdir)/clutter/clutter.h -nodist_clutter_HEADERS = \ - $(top_builddir)/clutter/clutter-json.h \ - $(top_builddir)/clutter/clutter-version.h \ - $(built_source_h) - - -DISTCLEANFILES += clutter-version.h -EXTRA_DIST += clutter-version.h.in - -# these are the gir files we generate -BUILT_GIRSOURCES = - -# these are the gir files we scan -INTROSPECTION_GIRS = - -if LOCAL_JSON_GLIB -json_gir_include=--include-uninstalled=$(top_builddir)/clutter/ClutterJson-@CLUTTER_API_VERSION@.gir - -ClutterJson-@CLUTTER_API_VERSION@.gir: libclutter-@CLUTTER_SONAME_INFIX@-@CLUTTER_API_VERSION@.la Makefile - -clutterjson_sources = $(top_srcdir)/clutter/json/*.h $(top_srcdir)/clutter/json/*.c -clutterjson_introspection_files=$(filter-out %-private.h, $(clutterjson_sources)) - -ClutterJson_@CLUTTER_API_VERSION_AM@_gir_NAMESPACE = ClutterJson -ClutterJson_@CLUTTER_API_VERSION_AM@_gir_VERSION = @CLUTTER_API_VERSION@ -ClutterJson_@CLUTTER_API_VERSION_AM@_gir_LIBS = libclutter-@CLUTTER_SONAME_INFIX@-@CLUTTER_API_VERSION@.la -ClutterJson_@CLUTTER_API_VERSION_AM@_gir_FILES = $(clutterjson_introspection_files) -ClutterJson_@CLUTTER_API_VERSION_AM@_gir_CFLAGS = $(INCLUDES) $(CLUTTER_CFLAGS) $(AM_CPPFLAGS) -DJSON_COMPILATION -ClutterJson_@CLUTTER_API_VERSION_AM@_gir_INCLUDES = GObject-2.0 -ClutterJson_@CLUTTER_API_VERSION_AM@_gir_SCANNERFLAGS = \ - --warn-all \ - --identifier-prefix=Json \ - --symbol-prefix=json - -INTROSPECTION_GIRS += ClutterJson-@CLUTTER_API_VERSION@.gir -else -json_gir_include=--include=Json-1.0 -endif # LOCAL_JSON_GLIB - +# gobject-introspection rules -include $(INTROSPECTION_MAKEFILE) if HAVE_INTROSPECTION @@ -364,13 +594,13 @@ Clutter_@CLUTTER_API_VERSION_AM@_gir_INCLUDES = GL-1.0 GObject-2.0 Atk-1.0 Pango Clutter_@CLUTTER_API_VERSION_AM@_gir_SCANNERFLAGS = \ --warn-all \ --c-include='clutter/clutter.h' \ - --pkg-export clutter-1.0 \ + --pkg-export clutter-@CLUTTER_API_VERSION@ \ $(json_gir_include) \ --include-uninstalled=$(top_builddir)/clutter/cogl/cogl/Cogl-@CLUTTER_API_VERSION@.gir # ClutterJson.gir and Cogl.gir are used included into Clutter.gir, so they # need to be built before the typelib is generated -Clutter-@CLUTTER_API_VERSION@.typelib: $(clutter_json_gir) Cogl-@CLUTTER_API_VERSION@.gir +Clutter-@CLUTTER_API_VERSION@.typelib: $(json_gir) Cogl-@CLUTTER_API_VERSION@.gir # We build Cogl.gir in the cogl/ subdir, but it needs to reference the shared # library that it's built into, so we delay compiling the gir into typelib @@ -384,62 +614,54 @@ Cogl-@CLUTTER_API_VERSION@.gir: Makefile Clutter-@CLUTTER_API_VERSION@.gir cogl/ BUILT_GIRSOURCES += Cogl-@CLUTTER_API_VERSION@.gir -# Cally depends on Clutter because it exposes Clutter types; for this reason, -# we cannot build Cally.gir under cally/ and then do the shlib trick we do -# for Cogl -cally_sources=$(top_srcdir)/clutter/cally/*.h $(top_srcdir)/clutter/cally/*.c -cally_introspection_files=$(filter-out %-private.h, $(cally_sources)) - Cally-@CLUTTER_API_VERSION@.gir: Clutter-@CLUTTER_API_VERSION@.gir Makefile Cally_@CLUTTER_API_VERSION_AM@_gir_NAMESPACE = Cally Cally_@CLUTTER_API_VERSION_AM@_gir_VERSION = @CLUTTER_API_VERSION@ Cally_@CLUTTER_API_VERSION_AM@_gir_LIBS = libclutter-@CLUTTER_SONAME_INFIX@-@CLUTTER_API_VERSION@.la -Cally_@CLUTTER_API_VERSION_AM@_gir_FILES = $(cally_introspection_files) +Cally_@CLUTTER_API_VERSION_AM@_gir_FILES = $(cally_sources_h) $(cally_sources_c) Cally_@CLUTTER_API_VERSION_AM@_gir_CFLAGS = $(INCLUDES) $(CLUTTER_CFLAGS) $(AM_CPPFLAGS) -UCLUTTER_DISABLE_DEPRECATED Cally_@CLUTTER_API_VERSION_AM@_gir_SCANNERFLAGS = \ --warn-all \ --c-include='cally/cally.h' \ - --add-include-path $(top_builddir)/clutter \ + --pkg-export=cally-@CLUTTER_API_VERSION@ \ $(json_gir_include) \ + --include-uninstalled $(top_builddir)/clutter/Cogl-@CLUTTER_API_VERSION@.gir \ --include-uninstalled $(top_builddir)/clutter/Clutter-@CLUTTER_API_VERSION@.gir INTROSPECTION_GIRS += Cally-@CLUTTER_API_VERSION@.gir +if LOCAL_JSON_GLIB +ClutterJson-@CLUTTER_API_VERSION@.gir: libclutter-@CLUTTER_SONAME_INFIX@-@CLUTTER_API_VERSION@.la + +ClutterJson_@CLUTTER_API_VERSION_AM@_gir_NAMESPACE = ClutterJson +ClutterJson_@CLUTTER_API_VERSION_AM@_gir_VERSION = @CLUTTER_API_VERSION@ +ClutterJson_@CLUTTER_API_VERSION_AM@_gir_LIBS = libclutter-@CLUTTER_SONAME_INFIX@-@CLUTTER_API_VERSION@.la +ClutterJson_@CLUTTER_API_VERSION_AM@_gir_FILES = $(json_sources_c) $(json_sources_h) +ClutterJson_@CLUTTER_API_VERSION_AM@_gir_CFLAGS = $(INCLUDES) $(CLUTTER_CFLAGS) $(AM_CPPFLAGS) +ClutterJson_@CLUTTER_API_VERSION_AM@_gir_INCLUDES = GObject-2.0 +ClutterJson_@CLUTTER_API_VERSION_AM@_gir_SCANNERFLAGS = \ + --warn-all \ + --identifier-prefix=Json \ + --symbol-prefix=json + +INTROSPECTION_GIRS += ClutterJson-@CLUTTER_API_VERSION@.gir +endif # LOCAL_JSON_GLIB + if SUPPORT_X11 - -x11_sources = \ - x11/clutter-backend-x11.c \ - x11/clutter-backend-x11.h \ - x11/clutter-device-manager-x11.c \ - x11/clutter-device-manager-x11.h \ - x11/clutter-event-x11.c \ - x11/clutter-input-device-x11.c \ - x11/clutter-input-device-x11.h \ - x11/clutter-keymap-x11.c \ - x11/clutter-keymap-x11.h \ - x11/clutter-settings-x11.h \ - x11/clutter-stage-x11.c \ - x11/clutter-stage-x11.h \ - x11/clutter-x11-enum-types.c \ - x11/clutter-x11-enum-types.h \ - x11/clutter-x11.h \ - x11/clutter-x11-texture-pixmap.c \ - x11/clutter-x11-texture-pixmap.h - -ClutterX11-@CLUTTER_API_VERSION@.gir: Makefile Clutter-@CLUTTER_API_VERSION@.gir +ClutterX11-@CLUTTER_API_VERSION@.gir: Makefile Clutter-@CLUTTER_API_VERSION@.gir Cogl-@CLUTTER_API_VERSION@.gir ClutterX11_@CLUTTER_API_VERSION_AM@_gir_SCANNERFLAGS = \ --warn-all \ --identifier-prefix=ClutterX11 \ --symbol-prefix=clutter_x11 \ $(json_gir_include) \ - --include-uninstalled=$(top_builddir)/clutter/cogl/cogl/Cogl-@CLUTTER_API_VERSION@.gir \ + --include-uninstalled=$(top_builddir)/clutter/Cogl-@CLUTTER_API_VERSION@.gir \ --include-uninstalled=$(top_builddir)/clutter/Clutter-@CLUTTER_API_VERSION@.gir ClutterX11_@CLUTTER_API_VERSION_AM@_gir_INCLUDES = xlib-2.0 ClutterX11_@CLUTTER_API_VERSION_AM@_gir_LIBS = libclutter-@CLUTTER_SONAME_INFIX@-@CLUTTER_API_VERSION@.la -ClutterX11_@CLUTTER_API_VERSION_AM@_gir_FILES = $(x11_sources) -ClutterX11_@CLUTTER_API_VERSION_AM@_gir_CFLAGS = $(INCLUDES) $(CLUTTER_CFLAGS) $(AM_CPPFLAGS) -UCLUTTER_DISABLE_DEPRECATED -L$(top_builddir)/clutter +ClutterX11_@CLUTTER_API_VERSION_AM@_gir_FILES = $(x11_introspection) +ClutterX11_@CLUTTER_API_VERSION_AM@_gir_CFLAGS = $(INCLUDES) $(CLUTTER_CFLAGS) $(AM_CPPFLAGS) -UCLUTTER_DISABLE_DEPRECATED INTROSPECTION_GIRS += ClutterX11-@CLUTTER_API_VERSION@.gir endif # SUPPORT_X11 @@ -455,7 +677,6 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib) $(INTROSPECTION_GIRS:.gir=.typ CLEANFILES += $(gir_DATA) $(typelibs_DATA) endif # HAVE_INTROSPECTION -EXTRA_DIST += clutter-keysyms-update.pl - -gcov_sources = $(source_c) +# GCov rules +gcov_sources = $(source_c) $(backend_source_c) include $(top_srcdir)/build/autotools/Makefile.am.gcov diff --git a/clutter/cally/Makefile.am b/clutter/cally/Makefile.am deleted file mode 100644 index d45a65afa..000000000 --- a/clutter/cally/Makefile.am +++ /dev/null @@ -1,80 +0,0 @@ -include $(top_srcdir)/build/autotools/Makefile.am.silent - -EXTRA_DIST = -CLEANFILES = -DISTCLEANFILES = - -# pkg-config ================================================================== -pc_files = \ - cally-$(CLUTTER_API_VERSION).pc - -cally-$(CLUTTER_API_VERSION).pc: cally.pc - $(QUIET_GEN)cp -f $< $(@F) - -pkgconfigdir = $(libdir)/pkgconfig -pkgconfig_DATA = $(pc_files) - -EXTRA_DIST += cally.pc.in -CLEANFILES += $(pc_files) - -noinst_LTLIBRARIES = libcally.la - -cally_h_sources = cally.h \ - cally-actor.h \ - cally-factory.h \ - cally-group.h \ - cally-main.h \ - cally-rectangle.h \ - cally-root.h \ - cally-stage.h \ - cally-text.h \ - cally-texture.h \ - cally-clone.h \ - cally-util.h - -cally_private_h_sources = cally-actor-private.h - -cally_c_sources = cally.c \ - cally-actor.c \ - cally-group.c \ - cally-rectangle.c \ - cally-root.c \ - cally-stage.c \ - cally-text.c \ - cally-texture.c \ - cally-clone.c \ - cally-util.c - -libcally_la_SOURCES = \ - $(cally_private_h_sources) \ - $(cally_h_sources) \ - $(cally_c_sources) - -INCLUDES = \ - -I$(top_srcdir) \ - -I$(top_srcdir)/clutter \ - -I$(top_srcdir)/clutter/cally \ - -I$(top_srcdir)/clutter/cogl \ - -I$(top_builddir)/clutter \ - -I$(top_builddir)/clutter/cogl - -AM_CPPFLAGS = \ - -DG_LOG_DOMAIN=\"Cally\" \ - -DCLUTTER_COMPILATION \ - -DVERSION=\"$(VERSION)\" \ - $(CLUTTER_DEBUG_CFLAGS) - -AM_CFLAGS = \ - $(CLUTTER_CFLAGS) \ - $(MAINTAINER_CFLAGS) - - -libcallydir=$(includedir)/clutter-@CLUTTER_API_VERSION@/cally - -# In opposit to GAIL, CALLY exports all the headers. It will very -# unlikely in any real final clutter-based application to use only raw -# CALLY. In fact, after HAIL experience, probably export GAIL -# interfaces would be a good idea -libcally_HEADERS = $(cally_h_sources) - -libcally_la_LIBADD = $(CLUTTER_LIBS) diff --git a/clutter/cally/cally.pc.in b/clutter/cally/cally.pc.in index 224668f79..16e696ce1 100644 --- a/clutter/cally/cally.pc.in +++ b/clutter/cally/cally.pc.in @@ -3,16 +3,9 @@ exec_prefix=@exec_prefix@ libdir=@libdir@ includedir=@includedir@ -apiversion=@CLUTTER_API_VERSION@ -winsys=@CLUTTER_WINSYS@ -soname_infix=@CLUTTER_SONAME_INFIX@ -cogl_driver=@COGL_DRIVER@ -requires=@CLUTTER_REQUIRES@ - Name: Cally Description: Clutter Accessibility Implementation Library Version: @VERSION@ -Requires: atk clutter-1.0 Libs: -L${libdir} -lclutter-${winsys}-${apiversion} Cflags: -I${includedir}/clutter-${apiversion} -Requires: ${requires} +Requires: atk clutter-1.0 diff --git a/clutter.pc.in b/clutter/clutter.pc.in similarity index 100% rename from clutter.pc.in rename to clutter/clutter.pc.in diff --git a/clutter/cogl/cogl/Makefile.am b/clutter/cogl/cogl/Makefile.am index 0b8ad47ac..3a4698f39 100644 --- a/clutter/cogl/cogl/Makefile.am +++ b/clutter/cogl/cogl/Makefile.am @@ -1,8 +1,10 @@ include $(top_srcdir)/build/autotools/Makefile.am.silent +# preamble + NULL = -SUBDIRS = driver +SUBDIRS = BUILT_SOURCES = @@ -12,23 +14,6 @@ DISTCLEANFILES = noinst_LTLIBRARIES = -# pkg-config ================================================================== -pc_files = \ - cogl-$(COGL_DRIVER)-$(CLUTTER_API_VERSION).pc \ - cogl-$(CLUTTER_API_VERSION).pc - -cogl-$(CLUTTER_API_VERSION).pc: cogl.pc - $(QUIET_GEN)cp -f $< $(@F) - -cogl-$(COGL_DRIVER)-$(CLUTTER_API_VERSION).pc: cogl.pc - $(QUIET_GEN)cp -f $< $(@F) - -pkgconfigdir = $(libdir)/pkgconfig -pkgconfig_DATA = $(pc_files) - -EXTRA_DIST += cogl.pc.in -CLEANFILES += $(pc_files) - INCLUDES = \ -I$(top_srcdir) \ -I$(top_srcdir)/clutter/cogl \ @@ -54,6 +39,20 @@ BUILT_SOURCES += cogl-defines.h DISTCLEANFILES += cogl-defines.h EXTRA_DIST += cogl-defines.h.in +# pkg-config +pc_files = \ + cogl-$(COGL_DRIVER)-$(CLUTTER_API_VERSION).pc \ + cogl-$(CLUTTER_API_VERSION).pc + +cogl-$(COGL_DRIVER)-$(CLUTTER_API_VERSION).pc: cogl-$(CLUTTER_API_VERSION).pc + $(QUIET_GEN)cp -f $< $(@F) + +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = $(pc_files) + +EXTRA_DIST += cogl.pc.in +DISTCLEANFILES += $(pc_files) + # public headers cogl_public_h = \ $(srcdir)/cogl-object.h \ @@ -76,6 +75,58 @@ cogl_public_h = \ $(srcdir)/cogl.h \ $(NULL) +# driver sources +cogl_driver_sources = + +if COGL_DRIVER_GL +cogl_driver_sources += \ + $(srcdir)/driver/gl/cogl-context-driver-gl.c \ + $(srcdir)/driver/gl/cogl-context-driver-gl.h \ + $(srcdir)/driver/gl/cogl-feature-functions-gl.h \ + $(srcdir)/driver/gl/cogl-gl.c \ + $(srcdir)/driver/gl/cogl-program-gl.c \ + $(srcdir)/driver/gl/cogl-program-gl.h \ + $(srcdir)/driver/gl/cogl-texture-driver-gl.c \ + $(NULL) +endif + +if COGL_DRIVER_GLES +cogl_driver_sources += \ + $(srcdir)/driver/gles/cogl-context-driver-gles.c \ + $(srcdir)/driver/gles/cogl-context-driver-gles.h \ + $(srcdir)/driver/gles/cogl-feature-functions-gles.h \ + $(srcdir)/driver/gles/cogl-gles.c \ + $(srcdir)/driver/gles/cogl-program-gles.c \ + $(srcdir)/driver/gles/cogl-program-gles.h \ + $(srcdir)/driver/gles/cogl-texture-driver-gles.c \ + $(NULL) + +if USE_GLES2_WRAPPER +cogl_driver_sources += \ + $(srcdir)/driver/gles/cogl-gles2-wrapper.c \ + $(srcdir)/driver/gles/cogl-gles2-wrapper.h \ + $(NULL) + +BUILT_SOURCES += \ + cogl-fixed-vertex-shader.h \ + cogl-fixed-vertex-shader.c \ + cogl-fixed-fragment-shader.h \ + cogl-fixed-fragment-shader.c + +%.h: $(srcdir)/driver/gles/%.glsl + /bin/sh $(top_srcdir)/build/stringify.sh -h $< > $@ +%.c: $(srcdir)/driver/gles/%.glsl + /bin/sh $(top_srcdir)/build/stringify.sh $< > $@ + +endif # USE_GLES2_WAPPER + +EXTRA_DIST += \ + $(srcdir)/driver/gles/cogl-fixed-vertex-shader.glsl \ + $(srcdir)/driver/gles/cogl-fixed-fragment-shader.glsl \ + $(NULL) + +endif # COGL_DRIVER_GLES + # winsys sources, common to all backends cogl_winsys_common_sources = \ $(srcdir)/winsys/cogl-winsys.h \ @@ -114,11 +165,13 @@ cogl_tesselator_sources = \ $(NULL) EXTRA_DIST += \ - $(srcdir)/tesselator/README \ - $(srcdir)/tesselator/priorityq-heap.c + $(srcdir)/tesselator/README \ + $(srcdir)/tesselator/priorityq-heap.c \ + $(NULL) # sources cogl_sources_c = \ + $(cogl_driver_sources) \ $(cogl_winsys_common_sources) \ $(cogl_tesselator_sources) \ $(srcdir)/cogl-debug.h \ @@ -212,6 +265,47 @@ cogl_sources_c = \ $(srcdir)/cogl-callback-list.c \ $(NULL) +if SUPPORT_XLIB +cogl_public_h += \ + $(srcdir)/winsys/cogl-texture-pixmap-x11.h + +cogl_sources_c += \ + $(srcdir)/winsys/cogl-xlib.h \ + $(srcdir)/winsys/cogl-xlib.c \ + $(srcdir)/winsys/cogl-texture-pixmap-x11.c \ + $(srcdir)/winsys/cogl-texture-pixmap-x11-private.h +endif +if SUPPORT_GLX +cogl_sources_c += \ + $(srcdir)/winsys/cogl-glx.c +endif +if SUPPORT_EGL_PLATFORM_POWERVR_X11 +cogl_sources_c += \ + $(srcdir)/winsys/cogl-egl.c +endif +if SUPPORT_EGL_PLATFORM_POWERVR_NULL +cogl_sources_c += \ + $(srcdir)/winsys/cogl-egl.c +endif +if SUPPORT_EGL_PLATFORM_POWERVR_GDL +cogl_sources_c += \ + $(srcdir)/winsys/cogl-egl.c +endif +if SUPPORT_EGL_PLATFORM_FRUITY +cogl_sources_c += \ + $(srcdir)/winsys/cogl-fruity.c +endif +if SUPPORT_WIN32 +cogl_sources_c += \ + $(srcdir)/winsys/cogl-win32.c +endif +if SUPPORT_OSX +cogl_sources_c += \ + $(srcdir)/winsys/cogl-osx.c +endif + +EXTRA_DIST += stb_image.c + # glib-mkenums rules glib_enum_h = cogl-enum-types.h glib_enum_c = cogl-enum-types.c @@ -220,54 +314,10 @@ include $(top_srcdir)/build/autotools/Makefile.am.enums noinst_LTLIBRARIES += libclutter-cogl.la -libclutter_cogl_la_LIBADD = \ - -lm $(CLUTTER_LIBS) \ - $(top_builddir)/clutter/cogl/cogl/driver/$(COGL_DRIVER)/libclutter-cogl-driver.la - +libclutter_cogl_la_LIBADD = -lm $(CLUTTER_LIBS) libclutter_cogl_la_SOURCES = $(cogl_sources_c) nodist_libclutter_cogl_la_SOURCES = $(BUILT_SOURCES) -if SUPPORT_XLIB -cogl_public_h += \ - $(srcdir)/winsys/cogl-texture-pixmap-x11.h - -libclutter_cogl_la_SOURCES += \ - $(srcdir)/winsys/cogl-xlib.h \ - $(srcdir)/winsys/cogl-xlib.c \ - $(srcdir)/winsys/cogl-texture-pixmap-x11.c \ - $(srcdir)/winsys/cogl-texture-pixmap-x11-private.h -endif -if SUPPORT_GLX -libclutter_cogl_la_SOURCES += \ - $(srcdir)/winsys/cogl-glx.c -endif -if SUPPORT_EGL_PLATFORM_POWERVR_X11 -libclutter_cogl_la_SOURCES += \ - $(srcdir)/winsys/cogl-egl.c -endif -if SUPPORT_EGL_PLATFORM_POWERVR_NULL -libclutter_cogl_la_SOURCES += \ - $(srcdir)/winsys/cogl-egl.c -endif -if SUPPORT_EGL_PLATFORM_POWERVR_GDL -libclutter_cogl_la_SOURCES += \ - $(srcdir)/winsys/cogl-egl.c -endif -if SUPPORT_EGL_PLATFORM_FRUITY -libclutter_cogl_la_SOURCES += \ - $(srcdir)/winsys/cogl-fruity.c -endif -if SUPPORT_WIN32 -libclutter_cogl_la_SOURCES += \ - $(srcdir)/winsys/cogl-win32.c -endif -if SUPPORT_OSX -libclutter_cogl_la_SOURCES += \ - $(srcdir)/winsys/cogl-osx.c -endif - -EXTRA_DIST += stb_image.c - # COGL installed headers cogl_headers = \ $(cogl_public_h) \ diff --git a/clutter/cogl/cogl/cogl-context.h b/clutter/cogl/cogl/cogl-context.h index 54815349a..028b79fa7 100644 --- a/clutter/cogl/cogl/cogl-context.h +++ b/clutter/cogl/cogl/cogl-context.h @@ -25,7 +25,15 @@ #define __COGL_CONTEXT_H #include "cogl-internal.h" -#include "cogl-context-driver.h" + +#if HAVE_COGL_GL +#include "cogl-context-driver-gl.h" +#endif + +#if HAVE_COGL_GLES || HAVE_COGL_GLES2 +#include "cogl-context-driver-gles.h" +#endif + #include "cogl-context-winsys.h" #include "cogl-primitives.h" #include "cogl-clip-stack.h" diff --git a/clutter/cogl/cogl/cogl-material-arbfp.c b/clutter/cogl/cogl/cogl-material-arbfp.c index 5c6c94871..25f4eeff1 100644 --- a/clutter/cogl/cogl/cogl-material-arbfp.c +++ b/clutter/cogl/cogl/cogl-material-arbfp.c @@ -44,8 +44,13 @@ #include "cogl-journal-private.h" #include "cogl-color-private.h" #include "cogl-profile.h" -#ifndef HAVE_COGL_GLES -#include "cogl-program.h" + +#ifdef HAVE_COGL_GL +#include "cogl-program-gl.h" +#endif + +#ifdef HAVE_COGL_GLES2 +#include "cogl-program-gles.h" #endif #include diff --git a/clutter/cogl/cogl/cogl-material-fixed.c b/clutter/cogl/cogl/cogl-material-fixed.c index 1e7870c6a..ae9c29eae 100644 --- a/clutter/cogl/cogl/cogl-material-fixed.c +++ b/clutter/cogl/cogl/cogl-material-fixed.c @@ -42,8 +42,13 @@ #include "cogl-texture-private.h" #include "cogl-blend-string.h" #include "cogl-profile.h" -#ifndef HAVE_COGL_GLES -#include "cogl-program.h" + +#ifdef HAVE_COGL_GL +#include "cogl-program-gl.h" +#endif + +#ifdef HAVE_COGL_GLES2 +#include "cogl-program-gles.h" #endif #include diff --git a/clutter/cogl/cogl/cogl-material-glsl.c b/clutter/cogl/cogl/cogl-material-glsl.c index 938427f0a..eab49f10c 100644 --- a/clutter/cogl/cogl/cogl-material-glsl.c +++ b/clutter/cogl/cogl/cogl-material-glsl.c @@ -40,8 +40,12 @@ #include "cogl-handle.h" #include "cogl-shader-private.h" -#ifndef HAVE_COGL_GLES -#include "cogl-program.h" +#ifdef HAVE_COGL_GL +#include "cogl-program-gl.h" +#endif + +#ifdef HAVE_COGL_GLES2 +#include "cogl-program-gles.h" #endif #include diff --git a/clutter/cogl/cogl/cogl-material-opengl.c b/clutter/cogl/cogl/cogl-material-opengl.c index b3d117a50..42543aeae 100644 --- a/clutter/cogl/cogl/cogl-material-opengl.c +++ b/clutter/cogl/cogl/cogl-material-opengl.c @@ -36,8 +36,13 @@ #include "cogl-material-private.h" #include "cogl-context.h" #include "cogl-texture-private.h" -#ifndef HAVE_COGL_GLES -#include "cogl-program.h" + +#ifdef HAVE_COGL_GL +#include "cogl-program-gl.h" +#endif + +#ifdef HAVE_COGL_GLES2 +#include "cogl-program-gles.h" #endif #ifdef COGL_MATERIAL_BACKEND_GLSL diff --git a/clutter/cogl/cogl/driver/gl/Makefile.am b/clutter/cogl/cogl/driver/gl/Makefile.am deleted file mode 100644 index 80c28929f..000000000 --- a/clutter/cogl/cogl/driver/gl/Makefile.am +++ /dev/null @@ -1,34 +0,0 @@ -include $(top_srcdir)/build/autotools/Makefile.am.silent - -NULL = - -INCLUDES = \ - -I$(top_srcdir) \ - -I$(srcdir) \ - -I$(srcdir)/../.. \ - -I$(srcdir)/../../.. \ - -I$(srcdir)/../../winsys \ - -I../.. \ - -I../../.. \ - -DG_DISABLE_SINGLE_INCLUDES \ - -DG_LOG_DOMAIN=\"Cogl-Driver\" \ - -DCLUTTER_COMPILATION - -noinst_LTLIBRARIES = libclutter-cogl-driver.la -libclutter_cogl_driver_la_CPPFLAGS = \ - $(CLUTTER_CFLAGS) \ - $(COGL_DEBUG_CFLAGS) \ - $(CLUTTER_DEBUG_CFLAGS) \ - $(MAINTAINER_CFLAGS) -libclutter_cogl_driver_la_SOURCES = \ - cogl.c \ - cogl-texture-driver.c \ - cogl-program.h \ - cogl-program.c \ - cogl-context-driver.h \ - cogl-context-driver.c \ - cogl-feature-functions.h \ - $(NULL) - - - diff --git a/clutter/cogl/cogl/driver/gl/cogl-context-driver.c b/clutter/cogl/cogl/driver/gl/cogl-context-driver-gl.c similarity index 96% rename from clutter/cogl/cogl/driver/gl/cogl-context-driver.c rename to clutter/cogl/cogl/driver/gl/cogl-context-driver-gl.c index 9524bbc72..0e67f15d1 100644 --- a/clutter/cogl/cogl/driver/gl/cogl-context-driver.c +++ b/clutter/cogl/cogl/driver/gl/cogl-context-driver-gl.c @@ -35,5 +35,5 @@ void _cogl_create_context_driver (CoglContext *_context) { - #include "cogl-feature-functions.h" + #include "cogl-feature-functions-gl.h" } diff --git a/clutter/cogl/cogl/driver/gl/cogl-context-driver.h b/clutter/cogl/cogl/driver/gl/cogl-context-driver-gl.h similarity index 97% rename from clutter/cogl/cogl/driver/gl/cogl-context-driver.h rename to clutter/cogl/cogl/driver/gl/cogl-context-driver-gl.h index 13cffe3ea..2d8e52138 100644 --- a/clutter/cogl/cogl/driver/gl/cogl-context-driver.h +++ b/clutter/cogl/cogl/driver/gl/cogl-context-driver-gl.h @@ -40,7 +40,7 @@ typedef struct _CoglContextDriver { /* This defines a list of function pointers */ -#include "cogl-feature-functions.h" +#include "cogl-feature-functions-gl.h" GLint gl_max_program_temoraries_arb; } CoglContextDriver; diff --git a/clutter/cogl/cogl/driver/gl/cogl-feature-functions.h b/clutter/cogl/cogl/driver/gl/cogl-feature-functions-gl.h similarity index 100% rename from clutter/cogl/cogl/driver/gl/cogl-feature-functions.h rename to clutter/cogl/cogl/driver/gl/cogl-feature-functions-gl.h diff --git a/clutter/cogl/cogl/driver/gl/cogl.c b/clutter/cogl/cogl/driver/gl/cogl-gl.c similarity index 98% rename from clutter/cogl/cogl/driver/gl/cogl.c rename to clutter/cogl/cogl/driver/gl/cogl-gl.c index 17b2fb22b..a8494fe0b 100644 --- a/clutter/cogl/cogl/driver/gl/cogl.c +++ b/clutter/cogl/cogl/driver/gl/cogl-gl.c @@ -153,7 +153,7 @@ _cogl_check_driver_valid (GError **error) #define COGL_FEATURE_END() \ { NULL, 0 }, \ }; -#include "cogl-feature-functions.h" +#include "cogl-feature-functions-gl.h" /* Define an array of features */ #undef COGL_FEATURE_BEGIN @@ -170,7 +170,7 @@ _cogl_check_driver_valid (GError **error) static const CoglFeatureData cogl_feature_data[] = { -#include "cogl-feature-functions.h" +#include "cogl-feature-functions-gl.h" }; void diff --git a/clutter/cogl/cogl/driver/gl/cogl-program.c b/clutter/cogl/cogl/driver/gl/cogl-program-gl.c similarity index 99% rename from clutter/cogl/cogl/driver/gl/cogl-program.c rename to clutter/cogl/cogl/driver/gl/cogl-program-gl.c index 20dec0a25..ecb600cbc 100644 --- a/clutter/cogl/cogl/driver/gl/cogl-program.c +++ b/clutter/cogl/cogl/driver/gl/cogl-program-gl.c @@ -29,7 +29,7 @@ #endif #include "cogl.h" -#include "cogl-program.h" +#include "cogl-program-gl.h" #include "cogl-shader-private.h" #include "cogl-internal.h" #include "cogl-handle.h" diff --git a/clutter/cogl/cogl/driver/gl/cogl-program.h b/clutter/cogl/cogl/driver/gl/cogl-program-gl.h similarity index 100% rename from clutter/cogl/cogl/driver/gl/cogl-program.h rename to clutter/cogl/cogl/driver/gl/cogl-program-gl.h diff --git a/clutter/cogl/cogl/driver/gl/cogl-texture-driver.c b/clutter/cogl/cogl/driver/gl/cogl-texture-driver-gl.c similarity index 100% rename from clutter/cogl/cogl/driver/gl/cogl-texture-driver.c rename to clutter/cogl/cogl/driver/gl/cogl-texture-driver-gl.c diff --git a/clutter/cogl/cogl/driver/gles/Makefile.am b/clutter/cogl/cogl/driver/gles/Makefile.am deleted file mode 100644 index ad22cc7c5..000000000 --- a/clutter/cogl/cogl/driver/gles/Makefile.am +++ /dev/null @@ -1,57 +0,0 @@ -include $(top_srcdir)/build/autotools/Makefile.am.silent - -NULL = - -INCLUDES = \ - -I$(top_srcdir) \ - -I$(srcdir) \ - -I$(srcdir)/../.. \ - -I$(srcdir)/../../.. \ - -I$(srcdir)/../../winsys \ - -I../.. \ - -I../../.. \ - -DG_DISABLE_SINGLE_INCLUDES \ - -DG_LOG_DOMAIN=\"Cogl-Driver\" \ - -DCLUTTER_COMPILATION - -noinst_LTLIBRARIES = libclutter-cogl-driver.la -libclutter_cogl_driver_la_CPPFLAGS = \ - $(CLUTTER_CFLAGS) \ - $(COGL_DEBUG_CFLAGS) \ - $(CLUTTER_DEBUG_CFLAGS) \ - $(MAINTAINER_CFLAGS) -libclutter_cogl_driver_la_SOURCES = \ - cogl.c \ - cogl-texture-driver.c \ - cogl-context-driver.c \ - cogl-context-driver.h \ - cogl-gles2-wrapper.h \ - cogl-program.h \ - cogl-program.c \ - cogl-feature-functions.h - -if USE_GLES2_WRAPPER -libclutter_cogl_driver_la_SOURCES += \ - cogl-gles2-wrapper.c \ - cogl-fixed-vertex-shader.h \ - cogl-fixed-vertex-shader.c \ - cogl-fixed-fragment-shader.h \ - cogl-fixed-fragment-shader.c -endif - -EXTRA_DIST = \ - stringify.sh \ - cogl-fixed-vertex-shader.glsl \ - cogl-fixed-fragment-shader.glsl - -BUILT_SOURCES = \ - cogl-fixed-vertex-shader.h \ - cogl-fixed-vertex-shader.c \ - cogl-fixed-fragment-shader.h \ - cogl-fixed-fragment-shader.c - -%.h: $(srcdir)/%.glsl - /bin/sh $(srcdir)/stringify.sh -h $< > $@ -%.c: $(srcdir)/%.glsl - /bin/sh $(srcdir)/stringify.sh $< > $@ - diff --git a/clutter/cogl/cogl/driver/gles/cogl-context-driver.c b/clutter/cogl/cogl/driver/gles/cogl-context-driver-gles.c similarity index 96% rename from clutter/cogl/cogl/driver/gles/cogl-context-driver.c rename to clutter/cogl/cogl/driver/gles/cogl-context-driver-gles.c index eb5bff4d8..ca0a0ed47 100644 --- a/clutter/cogl/cogl/driver/gles/cogl-context-driver.c +++ b/clutter/cogl/cogl/driver/gles/cogl-context-driver-gles.c @@ -36,7 +36,7 @@ void _cogl_create_context_driver (CoglContext *_context) { - #include "cogl-feature-functions.h" + #include "cogl-feature-functions-gles.h" /* Init the GLES2 wrapper */ #ifdef HAVE_COGL_GLES2 diff --git a/clutter/cogl/cogl/driver/gles/cogl-context-driver.h b/clutter/cogl/cogl/driver/gles/cogl-context-driver-gles.h similarity index 97% rename from clutter/cogl/cogl/driver/gles/cogl-context-driver.h rename to clutter/cogl/cogl/driver/gles/cogl-context-driver-gles.h index 9c473eb94..f35d435fb 100644 --- a/clutter/cogl/cogl/driver/gles/cogl-context-driver.h +++ b/clutter/cogl/cogl/driver/gles/cogl-context-driver-gles.h @@ -41,7 +41,7 @@ typedef struct _CoglContextDriver { /* This defines a list of function pointers */ -#include "cogl-feature-functions.h" +#include "cogl-feature-functions-gles.h" #ifdef HAVE_COGL_GLES2 CoglGles2Wrapper gles2; diff --git a/clutter/cogl/cogl/driver/gles/cogl-feature-functions.h b/clutter/cogl/cogl/driver/gles/cogl-feature-functions-gles.h similarity index 100% rename from clutter/cogl/cogl/driver/gles/cogl-feature-functions.h rename to clutter/cogl/cogl/driver/gles/cogl-feature-functions-gles.h diff --git a/clutter/cogl/cogl/driver/gles/cogl.c b/clutter/cogl/cogl/driver/gles/cogl-gles.c similarity index 98% rename from clutter/cogl/cogl/driver/gles/cogl.c rename to clutter/cogl/cogl/driver/gles/cogl-gles.c index 0a85d8504..8b99eb2e0 100644 --- a/clutter/cogl/cogl/driver/gles/cogl.c +++ b/clutter/cogl/cogl/driver/gles/cogl-gles.c @@ -50,7 +50,7 @@ _cogl_check_driver_valid (GError **error) #define COGL_FEATURE_END() \ { NULL, 0 }, \ }; -#include "cogl-feature-functions.h" +#include "cogl-feature-functions-gles.h" /* Define an array of features */ #undef COGL_FEATURE_BEGIN diff --git a/clutter/cogl/cogl/driver/gles/cogl-gles2-wrapper.c b/clutter/cogl/cogl/driver/gles/cogl-gles2-wrapper.c index 6245bc5a7..5cc1277f1 100644 --- a/clutter/cogl/cogl/driver/gles/cogl-gles2-wrapper.c +++ b/clutter/cogl/cogl/driver/gles/cogl-gles2-wrapper.c @@ -25,7 +25,6 @@ #include "config.h" #endif -#include #include #include diff --git a/clutter/cogl/cogl/driver/gles/cogl-gles2-wrapper.h b/clutter/cogl/cogl/driver/gles/cogl-gles2-wrapper.h index 9edf78de0..0274761bd 100644 --- a/clutter/cogl/cogl/driver/gles/cogl-gles2-wrapper.h +++ b/clutter/cogl/cogl/driver/gles/cogl-gles2-wrapper.h @@ -26,7 +26,7 @@ #include "cogl.h" /* needed for gl header include */ #include "cogl-internal.h" -#include "cogl-program.h" +#include "cogl-program-gles.h" G_BEGIN_DECLS diff --git a/clutter/cogl/cogl/driver/gles/cogl-program.c b/clutter/cogl/cogl/driver/gles/cogl-program-gles.c similarity index 99% rename from clutter/cogl/cogl/driver/gles/cogl-program.c rename to clutter/cogl/cogl/driver/gles/cogl-program-gles.c index 50715613b..d3ca29962 100644 --- a/clutter/cogl/cogl/driver/gles/cogl-program.c +++ b/clutter/cogl/cogl/driver/gles/cogl-program-gles.c @@ -36,7 +36,7 @@ #include #include "cogl-shader-private.h" -#include "cogl-program.h" +#include "cogl-program-gles.h" static void _cogl_program_free (CoglProgram *program); diff --git a/clutter/cogl/cogl/driver/gles/cogl-program.h b/clutter/cogl/cogl/driver/gles/cogl-program-gles.h similarity index 100% rename from clutter/cogl/cogl/driver/gles/cogl-program.h rename to clutter/cogl/cogl/driver/gles/cogl-program-gles.h diff --git a/clutter/cogl/cogl/driver/gles/cogl-texture-driver.c b/clutter/cogl/cogl/driver/gles/cogl-texture-driver-gles.c similarity index 100% rename from clutter/cogl/cogl/driver/gles/cogl-texture-driver.c rename to clutter/cogl/cogl/driver/gles/cogl-texture-driver-gles.c diff --git a/clutter/egl/Makefile.am b/clutter/egl/Makefile.am deleted file mode 100644 index 5d292e07f..000000000 --- a/clutter/egl/Makefile.am +++ /dev/null @@ -1,46 +0,0 @@ -libclutterincludedir = $(includedir)/clutter-@CLUTTER_API_VERSION@/clutter/egl -libclutterinclude_HEADERS = clutter-egl.h clutter-egl-headers.h - -INCLUDES = \ - -DG_LOG_DOMAIN=\"ClutterEGL\" \ - -DCLUTTER_COMPILATION \ - -I$(top_srcdir) \ - -I$(top_srcdir)/clutter \ - -I$(top_srcdir)/clutter/cogl \ - -I$(top_builddir)/clutter \ - -I$(top_builddir)/clutter/cogl \ - $(CLUTTER_CFLAGS) \ - $(CLUTTER_DEBUG_CFLAGS) \ - $(MAINTAINER_CFLAGS) -if SUPPORT_X11 -INCLUDES += -I$(top_srcdir)/clutter/x11 -endif - -LDADD = $(CLUTTER_LIBS) -if SUPPORT_X11 -LDADD += $(top_builddir)/clutter/x11/libclutter-x11.la -endif - -noinst_LTLIBRARIES = libclutter-egl.la - -if SUPPORT_X11 -libclutter_egl_la_DEPENDENCIES = \ - $(top_builddir)/clutter/x11/libclutter-x11.la -endif - -libclutter_egl_la_SOURCES = \ - clutter-backend-egl.h \ - clutter-backend-egl.c \ - clutter-stage-egl.h \ - clutter-stage-egl.c \ - clutter-egl.h \ - clutter-egl-headers.h - -if USE_TSLIB -libclutter_egl_la_SOURCES += clutter-event-tslib.c -endif - -if SUPPORT_CEX100 -libclutter_egl_la_SOURCES += clutter-backend-cex100.c clutter-backend-cex100.h -libclutterinclude_HEADERS += clutter-cex100.h -endif diff --git a/clutter/glx/Makefile.am b/clutter/glx/Makefile.am deleted file mode 100644 index b40316144..000000000 --- a/clutter/glx/Makefile.am +++ /dev/null @@ -1,36 +0,0 @@ -include $(top_srcdir)/build/autotools/Makefile.am.silent - -libclutter_glx_includedir = $(includedir)/clutter-@CLUTTER_API_VERSION@/clutter/glx -libclutter_glx_include_HEADERS = clutter-glx.h clutter-glx-texture-pixmap.h - -INCLUDES = \ - -DG_LOG_DOMAIN=\"ClutterGLX\" \ - -I$(top_srcdir) \ - -I$(top_srcdir)/clutter \ - -I$(top_srcdir)/clutter/cogl \ - -I$(top_srcdir)/clutter/x11 \ - -I$(top_builddir)/clutter \ - -I$(top_builddir)/clutter/cogl \ - -DCLUTTER_COMPILATION \ - -DCOGL_ENABLE_EXPERIMENTAL_API \ - $(CLUTTER_CFLAGS) \ - $(CLUTTER_DEBUG_CFLAGS) \ - $(MAINTAINER_CFLAGS) - -LDADD = $(CLUTTER_LIBS) $(top_builddir)/clutter/x11/libclutter-x11.la - -noinst_LTLIBRARIES = libclutter-glx.la - -libclutter_glx_la_DEPENDENCIES = \ - $(top_builddir)/clutter/x11/libclutter-x11.la - -libclutter_glx_la_SOURCES = \ - clutter-backend-glx.h \ - clutter-backend-glx.c \ - clutter-event-glx.h \ - clutter-event-glx.c \ - clutter-stage-glx.h \ - clutter-stage-glx.c \ - clutter-glx-texture-pixmap.h \ - clutter-glx-texture-pixmap.c \ - clutter-glx.h diff --git a/clutter/json/Makefile.am b/clutter/json/Makefile.am deleted file mode 100644 index 9ac960a42..000000000 --- a/clutter/json/Makefile.am +++ /dev/null @@ -1,39 +0,0 @@ -include $(top_srcdir)/build/autotools/Makefile.am.silent - -source_c = \ - $(srcdir)/json-array.c \ - $(srcdir)/json-generator.c \ - $(srcdir)/json-marshal.c \ - $(srcdir)/json-node.c \ - $(srcdir)/json-object.c \ - $(srcdir)/json-parser.c - -source_h = \ - $(top_srcdir)/clutter/json/json-generator.h \ - $(top_srcdir)/clutter/json/json-glib.h \ - $(top_srcdir)/clutter/json/json-marshal.h \ - $(top_srcdir)/clutter/json/json-parser.h \ - $(top_srcdir)/clutter/json/json-types.h - -source_h_priv = \ - $(top_srcdir)/clutter/json/json-types-private.h - -noinst_LTLIBRARIES = libclutter-json.la - -INCLUDES = \ - -I$(top_srcdir) \ - -DG_DISABLE_SINGLE_INCLUDES \ - -DG_LOG_DOMAIN=\"Clutter-Json\" \ - -DG_DISABLE_DEPRECATED \ - -DJSON_COMPILATION - -AM_CFLAGS = $(MAINTAINER_CFLAGS) -AM_CPPFLAGS = $(CLUTTER_CFLAGS) $(CLUTTER_DEBUG_CFLAGS) - -clutterjsondir = $(includedir)/clutter-@CLUTTER_API_VERSION@/clutter/json -clutterjson_HEADERS = $(source_h) - -libclutter_json_la_SOURCES = $(source_c) $(source_h) $(source_h_priv) - -noinst_DATA = -CLEANFILES = diff --git a/clutter/win32/Makefile.am b/clutter/win32/Makefile.am deleted file mode 100644 index c2e09eff1..000000000 --- a/clutter/win32/Makefile.am +++ /dev/null @@ -1,38 +0,0 @@ -libclutterincludedir = $(includedir)/clutter-@CLUTTER_API_VERSION@/clutter -libclutterinclude_HEADERS = clutter-win32.h - -clutter-win32-$(CLUTTER_API_VERSION).pc: clutter-win32.pc - @cp -f $< $(@F) - -pkgconfig_DATA = clutter-win32-@CLUTTER_API_VERSION@.pc -pkgconfigdir = $(libdir)/pkgconfig - -INCLUDES = \ - -DG_LOG_DOMAIN=\"ClutterWin32\" \ - -DCLUTTER_COMPILATION \ - -I$(top_srcdir) \ - -I$(top_srcdir)/clutter \ - -I$(top_srcdir)/clutter/cogl \ - -I$(top_builddir)/clutter \ - -I$(top_builddir)/clutter/cogl \ - $(CLUTTER_CFLAGS) \ - $(CLUTTER_DEBUG_CFLAGS) \ - $(MAINTAINER_CFLAGS) - -LDADD = $(CLUTTER_LIBS) - -noinst_LTLIBRARIES = libclutter-win32.la - -libclutter_win32_la_SOURCES = \ - clutter-backend-win32.h \ - clutter-backend-win32.c \ - clutter-device-manager-win32.h \ - clutter-device-manager-win32.c \ - clutter-event-win32.c \ - clutter-stage-win32.h \ - clutter-stage-win32.c \ - clutter-win32.h - -CLEANFILES = clutter-win32-$(CLUTTER_API_VERSION).pc - -EXTRA_DIST = clutter-win32.pc.in resources.rc invisible-cursor.cur diff --git a/clutter/win32/clutter-win32.pc.in b/clutter/win32/clutter-win32.pc.in deleted file mode 100644 index ad9a2b40c..000000000 --- a/clutter/win32/clutter-win32.pc.in +++ /dev/null @@ -1,16 +0,0 @@ -prefix=@prefix@ -exec_prefix=@exec_prefix@ -libdir=@libdir@ -includedir=@includedir@ -apiversion=@CLUTTER_API_VERSION@ -requires=@CLUTTER_REQUIRES@ -backend=@CLUTTER_WINSYS@ #only kept for backward compatability -winsys=@CLUTTER_WINSYS@ -cogl_driver=@COGL_DRIVER@ - -Name: Clutter -Description: Clutter Core Library (${winsys}/${cogl_driver} backend) -Version: @VERSION@ -Libs: -L${libdir} -lclutter-${winsys}-${apiversion} -Cflags: -I${includedir}/clutter-${apiversion} -Requires: ${requires} diff --git a/clutter/x11/Makefile.am b/clutter/x11/Makefile.am deleted file mode 100644 index b8c7c03da..000000000 --- a/clutter/x11/Makefile.am +++ /dev/null @@ -1,74 +0,0 @@ -include $(top_srcdir)/build/autotools/Makefile.am.silent - -NULL = - -INCLUDES = \ - -DG_LOG_DOMAIN=\"ClutterX11\" \ - -DCLUTTER_COMPILATION \ - -DCOGL_ENABLE_EXPERIMENTAL_API \ - -I$(top_srcdir) \ - -I$(top_srcdir)/clutter \ - -I$(top_srcdir)/clutter/cogl \ - -I$(srcdir)/xsettings \ - -I$(top_builddir)/clutter \ - -I$(top_builddir)/clutter/cogl \ - $(CLUTTER_CFLAGS) \ - $(CLUTTER_DEBUG_CFLAGS) \ - $(MAINTAINER_CFLAGS) - -LDADD = $(CLUTTER_LIBS) - -source_h = \ - $(top_srcdir)/clutter/x11/clutter-x11-texture-pixmap.h \ - $(top_srcdir)/clutter/x11/clutter-x11.h - -BUILT_SOURCES = - -EXTRA_DIST = - -CLEANFILES = - -DISTCLEANFILES = - -# glib-mkenums rules -glib_enum_h = clutter-x11-enum-types.h -glib_enum_c = clutter-x11-enum-types.c -glib_enum_headers = $(source_h) -include $(top_srcdir)/build/autotools/Makefile.am.enums - -noinst_LTLIBRARIES = libclutter-x11.la - -libclutter_x11_la_SOURCES = \ - $(srcdir)/clutter-backend-x11.h \ - $(srcdir)/clutter-backend-x11.c \ - $(srcdir)/clutter-device-manager-x11.h \ - $(srcdir)/clutter-device-manager-x11.c \ - $(srcdir)/clutter-event-x11.c \ - $(srcdir)/clutter-input-device-x11.h \ - $(srcdir)/clutter-input-device-x11.c \ - $(srcdir)/clutter-keymap-x11.h \ - $(srcdir)/clutter-keymap-x11.c \ - $(srcdir)/clutter-settings-x11.h \ - $(srcdir)/clutter-stage-x11.h \ - $(srcdir)/clutter-stage-x11.c \ - $(srcdir)/clutter-x11-texture-pixmap.c \ - $(srcdir)/xsettings/xsettings-client.c \ - $(srcdir)/xsettings/xsettings-client.h \ - $(srcdir)/xsettings/xsettings-common.c \ - $(srcdir)/xsettings/xsettings-common.h \ - clutter-x11-enum-types.h \ - clutter-x11-enum-types.c \ - $(NULL) - -libclutter_x11_includedir = $(includedir)/clutter-@CLUTTER_API_VERSION@/clutter/x11 -libclutter_x11_include_HEADERS = $(source_h) clutter-x11-enum-types.h - -clutter-x11-$(CLUTTER_API_VERSION).pc: clutter-x11.pc - @cp -f $< $(@F) - -pkgconfig_DATA = clutter-x11-@CLUTTER_API_VERSION@.pc -pkgconfigdir = $(libdir)/pkgconfig - -CLEANFILES += clutter-x11-$(CLUTTER_API_VERSION).pc - -EXTRA_DIST += clutter-x11.pc.in diff --git a/clutter/x11/clutter-backend-x11.c b/clutter/x11/clutter-backend-x11.c index c5aef41ba..9b9d1c96f 100644 --- a/clutter/x11/clutter-backend-x11.c +++ b/clutter/x11/clutter-backend-x11.c @@ -55,11 +55,12 @@ #include "cogl/cogl.h" #include "cogl/cogl-internal.h" -#include "../clutter-debug.h" -#include "../clutter-device-manager.h" -#include "../clutter-event.h" -#include "../clutter-main.h" -#include "../clutter-private.h" +#include "clutter-backend.h" +#include "clutter-debug.h" +#include "clutter-device-manager.h" +#include "clutter-event.h" +#include "clutter-main.h" +#include "clutter-private.h" G_DEFINE_TYPE (ClutterBackendX11, clutter_backend_x11, CLUTTER_TYPE_BACKEND); @@ -285,11 +286,14 @@ clutter_backend_x11_post_parse (ClutterBackend *backend, if (backend_x11->xdpy) { + ClutterSettings *settings; Atom atoms[n_atom_names]; double dpi; CLUTTER_NOTE (BACKEND, "Getting the X screen"); + settings = clutter_settings_get_default (); + /* Cogl needs to know the Xlib display connection for CoglTexturePixmapX11 */ _cogl_xlib_set_display (backend_x11->xdpy); @@ -310,7 +314,7 @@ clutter_backend_x11_post_parse (ClutterBackend *backend, dpi = (((double) DisplayHeight (backend_x11->xdpy, backend_x11->xscreen_num) * 25.4) / (double) DisplayHeightMM (backend_x11->xdpy, backend_x11->xscreen_num)); - clutter_backend_set_resolution (backend, dpi); + g_object_set (settings, "font-dpi", (int) dpi * 1024, NULL); /* register input devices */ backend_x11->device_manager = diff --git a/clutter/x11/clutter-x11-enum-types.c.in b/clutter/x11/clutter-x11-enum-types.c.in deleted file mode 100644 index abb5e76b2..000000000 --- a/clutter/x11/clutter-x11-enum-types.c.in +++ /dev/null @@ -1,31 +0,0 @@ -/*** BEGIN file-header ***/ -#include "clutter-x11-enum-types.h" -/*** END file-header ***/ - -/*** BEGIN file-production ***/ -/* enumerations from "@filename@" */ -#include "@filename@" -/*** END file-production ***/ - -/*** BEGIN value-header ***/ -GType -@enum_name@_get_type(void) { - static GType etype = 0; - if (G_UNLIKELY (!etype)) - { - static const G@Type@Value values[] = { -/*** END value-header ***/ - -/*** BEGIN value-production ***/ - { @VALUENAME@, "@VALUENAME@", "@valuenick@" }, -/*** END value-production ***/ - -/*** BEGIN value-tail ***/ - { 0, NULL, NULL } - }; - etype = g_@type@_register_static (g_intern_static_string ("@EnumName@"), values); - } - return etype; -} - -/*** END value-tail ***/ diff --git a/clutter/x11/clutter-x11-enum-types.h.in b/clutter/x11/clutter-x11-enum-types.h.in deleted file mode 100644 index f63e936bb..000000000 --- a/clutter/x11/clutter-x11-enum-types.h.in +++ /dev/null @@ -1,26 +0,0 @@ -/*** BEGIN file-header ***/ -#ifndef __CLUTTER_X11_ENUM_TYPES_H__ -#define __CLUTTER_X11_ENUM_TYPES_H__ - -#include - -G_BEGIN_DECLS - -/*** END file-header ***/ - -/*** BEGIN file-production ***/ -/* enumerations from "@filename@" */ -/*** END file-production ***/ - -/*** BEGIN file-tail ***/ -G_END_DECLS - -#endif /* !__CLUTTER_X11_ENUM_TYPES_H__ */ -/*** END file-tail ***/ - -/*** BEGIN value-header ***/ -GType @enum_name@_get_type (void) G_GNUC_CONST; -#define CLUTTER_X11_TYPE_@ENUMSHORT@ (@enum_name@_get_type()) - -/*** END value-header ***/ - diff --git a/clutter/x11/clutter-x11.h b/clutter/x11/clutter-x11.h index 70e3324bb..66611bd06 100644 --- a/clutter/x11/clutter-x11.h +++ b/clutter/x11/clutter-x11.h @@ -42,7 +42,6 @@ #include #include #include -#include #include G_BEGIN_DECLS diff --git a/clutter/x11/clutter-x11.pc.in b/clutter/x11/clutter-x11.pc.in deleted file mode 100644 index ad9a2b40c..000000000 --- a/clutter/x11/clutter-x11.pc.in +++ /dev/null @@ -1,16 +0,0 @@ -prefix=@prefix@ -exec_prefix=@exec_prefix@ -libdir=@libdir@ -includedir=@includedir@ -apiversion=@CLUTTER_API_VERSION@ -requires=@CLUTTER_REQUIRES@ -backend=@CLUTTER_WINSYS@ #only kept for backward compatability -winsys=@CLUTTER_WINSYS@ -cogl_driver=@COGL_DRIVER@ - -Name: Clutter -Description: Clutter Core Library (${winsys}/${cogl_driver} backend) -Version: @VERSION@ -Libs: -L${libdir} -lclutter-${winsys}-${apiversion} -Cflags: -I${includedir}/clutter-${apiversion} -Requires: ${requires} diff --git a/configure.ac b/configure.ac index be2a107d9..95b7df42a 100644 --- a/configure.ac +++ b/configure.ac @@ -413,6 +413,7 @@ AM_CONDITIONAL(SUPPORT_EGL_PLATFORM_POWERVR_NULL, [test "x$SUPPORT_EGL_PLATFORM_ AM_CONDITIONAL(SUPPORT_EGL_PLATFORM_POWERVR_GDL, [test "x$SUPPORT_EGL_PLATFORM_POWERVR_GDL" = "x1"]) AM_CONDITIONAL(SUPPORT_EGL_PLATFORM_FRUITY, [test "x$CLUTTER_WINSYS" = "xfruity"]) AM_CONDITIONAL(SUPPORT_OSX, [test "x$CLUTTER_WINSYS" = "xosx"]) +AM_CONDITIONAL(SUPPORT_FRUITY, [test "x$CLUTTER_WINSYS" = "xfruity"]) AM_CONDITIONAL(SUPPORT_WIN32, [test "x$CLUTTER_WINSYS" = "xwin32"]) AM_CONDITIONAL(SUPPORT_CEX100, [test "x$SUPPORT_EGL_PLATFORM_POWERVR_GDL" = "x1"]) @@ -581,6 +582,8 @@ for x in $cogl_gl_headers; do done; AC_SUBST(COGL_GL_HEADER_INCLUDES) +AM_CONDITIONAL([COGL_DRIVER_GLES], [test "x$COGL_DRIVER" = "xgles"]) +AM_CONDITIONAL([COGL_DRIVER_GL], [test "x$COGL_DRIVER" = "xgl"]) dnl === Clutter substitutions ================================================= # Eventually the idea of a winsys should be hidden from Clutter and moved @@ -1106,58 +1109,53 @@ AS_ALL_LINGUAS dnl =========================================================================== AC_CONFIG_FILES([ - Makefile - build/Makefile - build/autotools/Makefile - build/mingw/Makefile - clutter/Makefile - clutter/clutter-version.h - clutter/clutter-json.h - clutter/x11/Makefile - clutter/x11/clutter-x11.pc - clutter/glx/Makefile - clutter/egl/Makefile - clutter/egl/clutter-cex100.h - clutter/fruity/Makefile - clutter/osx/Makefile - clutter/win32/Makefile - clutter/win32/clutter-win32.pc - clutter/cally/Makefile - clutter/cally/cally.pc - clutter/cogl/Makefile - clutter/cogl/cogl/Makefile - clutter/cogl/cogl/cogl-defines.h - clutter/cogl/cogl/cogl.pc - clutter/cogl/cogl/driver/Makefile - clutter/cogl/cogl/driver/gl/Makefile - clutter/cogl/cogl/driver/gles/Makefile - clutter/cogl/pango/Makefile - clutter/json/Makefile - tests/Makefile - tests/accessibility/Makefile - tests/conform/Makefile - tests/conform/test-launcher.sh - tests/data/Makefile - tests/interactive/Makefile - tests/interactive/wrapper.sh - tests/micro-bench/Makefile - tests/tools/Makefile - doc/Makefile - doc/reference/Makefile - doc/reference/clutter/Makefile - doc/reference/clutter/clutter-docs.xml - doc/reference/cogl/Makefile - doc/reference/cogl/cogl-docs.xml - doc/reference/cally/Makefile - doc/reference/cally/cally-docs.xml - doc/common/Makefile - doc/manual/Makefile - doc/manual/clutter-manual.xml - doc/cookbook/Makefile - doc/cookbook/clutter-cookbook.xml - doc/cookbook/examples/Makefile - po/Makefile.in - clutter.pc + Makefile + + build/Makefile + build/autotools/Makefile + build/mingw/Makefile + + clutter/Makefile + clutter/clutter-version.h + clutter/clutter-json.h + clutter/clutter-$CLUTTER_API_VERSION.pc:clutter/clutter.pc.in + + clutter/cally/cally-$CLUTTER_API_VERSION.pc:clutter/cally/cally.pc.in + + clutter/cogl/Makefile + clutter/cogl/cogl/Makefile + clutter/cogl/cogl/cogl-defines.h + clutter/cogl/cogl/cogl-$CLUTTER_API_VERSION.pc:clutter/cogl/cogl/cogl.pc.in + clutter/cogl/pango/Makefile + + clutter/egl/clutter-cex100.h + + tests/Makefile + tests/accessibility/Makefile + tests/conform/Makefile + tests/conform/test-launcher.sh + tests/data/Makefile + tests/interactive/Makefile + tests/interactive/wrapper.sh + tests/micro-bench/Makefile + tests/tools/Makefile + + doc/Makefile + doc/reference/Makefile + doc/reference/clutter/Makefile + doc/reference/clutter/clutter-docs.xml + doc/reference/cogl/Makefile + doc/reference/cogl/cogl-docs.xml + doc/reference/cally/Makefile + doc/reference/cally/cally-docs.xml + doc/common/Makefile + doc/manual/Makefile + doc/manual/clutter-manual.xml + doc/cookbook/Makefile + doc/cookbook/clutter-cookbook.xml + doc/cookbook/examples/Makefile + + po/Makefile.in ]) AC_OUTPUT