4bd3fa583e
* clutter/clutter-private.h: Remove inclusion of backend-specific headers; update the main context object; add the declarations for the event queue functions. * clutter/clutter-backend.[ch]: Add the abstract ClutterBackend object, which holds backend-specific settings, the main stage, and the event queue. Every backend must implement a subclass of ClutterBackend and ClutterStage. * clutter/clutter-feature.c: Protect the GLX specific calls behing #ifdef HAVE_CLUTTER_GLX. * clutter/clutter-actor.c: * clutter/clutter-group.c: * clutter/clutter-clone-texture.c: Include GL/gl.h * clutter/clutter-event.[ch]: Update public API and implement the event queue private API; hold a reference on the event objects; move out the keysym-to-unicode table; add the new event types. * clutter/clutter-color.h: Include clutter-fixed.h * clutter/clutter-main.c: Update API; get the main stage from the backend object; process the event received from the queue; lock/unlock the main mutex if we have one; move the initialisation process sooner in the init sequence, in order to have the backend object when we check for options; call the backed vfuncs in the pre/post parse hooks. * clutter/clutter-stage.c: Make ClutterStage and abstract class, implemented by the backends. * clutter/clutter/glx/clutter-glx.h: * clutter/clutter/glx/clutter-backend-glx.[ch]: * clutter/clutter/glx/clutter-event-glx.c: * clutter/clutter/glx/clutter-stage-glx.[ch]: * clutter/clutter/glx/Makefile.am: Add the GLX backend. * clutter/clutter/egl/clutter-backend-egl.[ch]: * clutter/clutter/egl/clutter-event-egl.c: * clutter/clutter/egl/clutter-stage-egl.[ch]: * clutter/clutter/egl/Makefile.am: Add the stub for a EGL backend. * examples/*.c: Update for the new API.
217 lines
6.4 KiB
Plaintext
217 lines
6.4 KiB
Plaintext
# clutter package version number, (as distinct from shared library version)
|
|
# An odd micro number indicates in-progress development, (eg. from CVS)
|
|
# An even micro number indicates a released version.
|
|
m4_define([clutter_major_version], [0])
|
|
m4_define([clutter_minor_version], [3])
|
|
m4_define([clutter_micro_version], [0])
|
|
|
|
m4_define([clutter_version],
|
|
[clutter_major_version.clutter_minor_version.clutter_micro_version])
|
|
|
|
m4_define([clutter_api_version],
|
|
[clutter_major_version.clutter_minor_version])
|
|
|
|
# increase the interface age for each release; if the API changes, set to 0
|
|
m4_define([clutter_interface_age], [0])
|
|
m4_define([clutter_binary_age],
|
|
[m4_eval(100 * clutter_minor_version + clutter_micro_version)])
|
|
|
|
AC_PREREQ(2.53)
|
|
|
|
AC_INIT([clutter],
|
|
[clutter_version],
|
|
[http://bugzilla.o-hand.com/enter_bug.cgi?product=Clutter])
|
|
AC_CONFIG_SRCDIR([clutter/clutter.h])
|
|
AM_CONFIG_HEADER([config.h])
|
|
|
|
AM_INIT_AUTOMAKE([1.7])
|
|
|
|
CLUTTER_MAJOR_VERSION=clutter_major_version
|
|
CLUTTER_MINOR_VERSION=clutter_minor_version
|
|
CLUTTER_MICRO_VERSION=clutter_micro_version
|
|
CLUTTER_VERSION=clutter_version
|
|
CLUTTER_MAJORMINOR=clutter_api_version
|
|
AC_SUBST(CLUTTER_MAJOR_VERSION)
|
|
AC_SUBST(CLUTTER_MINOR_VERSION)
|
|
AC_SUBST(CLUTTER_MICRO_VERSION)
|
|
AC_SUBST(CLUTTER_VERSION)
|
|
AC_SUBST(CLUTTER_MAJORMINOR)
|
|
|
|
m4_define([lt_current],
|
|
[m4_eval(100 * clutter_minor_version + clutter_micro_version - clutter_interface_age)])
|
|
m4_define([lt_revision], [clutter_interface_age])
|
|
m4_define([lt_age], [m4_eval(clutter_binary_age - clutter_interface_age)])
|
|
CLUTTER_LT_CURRENT=lt_current
|
|
CLUTTER_LT_REV=lt_revision
|
|
CLUTTER_LT_AGE=lt_age
|
|
CLUTTER_LT_VERSION="$CLUTTER_LT_CURRENT:$CLUTTER_LT_REV:$CLUTTER_LT_AGE"
|
|
CLUTTER_LT_LDFLAGS="-version-info $CLUTTER_LT_VERSION"
|
|
|
|
AC_SUBST(CLUTTER_LT_VERSION)
|
|
AC_SUBST(CLUTTER_LT_LDFLAGS)
|
|
|
|
dnl ========================================================================
|
|
|
|
# Checks for programs.
|
|
AC_PROG_CC
|
|
AC_DISABLE_STATIC
|
|
AC_PROG_LIBTOOL
|
|
|
|
# Checks for header files.
|
|
AC_HEADER_STDC
|
|
AC_CHECK_HEADERS([fcntl.h stdlib.h string.h unistd.h])
|
|
|
|
# Checks for typedefs, structures, and compiler characteristics.
|
|
AC_C_CONST
|
|
|
|
# Checks for library functions.
|
|
AC_FUNC_MALLOC
|
|
AC_FUNC_MMAP
|
|
AC_CHECK_FUNCS([memset munmap strcasecmp strdup])
|
|
|
|
|
|
dnl ========================================================================
|
|
|
|
PKG_CHECK_MODULES(X11, x11, [have_x11=yes], [have_x11=no])
|
|
if test x$have_x11 = xno
|
|
then
|
|
AC_PATH_X
|
|
if test x"$x_includes" != x"NONE" && test -n "$x_includes" ; then
|
|
X11_CFLAGS=-I`echo $x_includes | sed -e "s/:/ -I/g"`
|
|
fi
|
|
if test x"$x_libraries" != x"NONE" && test -n "$x_libraries" ; then
|
|
X11_LIBS=-L`echo $x_libraries | sed -e "s/:/ -L/g"`
|
|
fi
|
|
fi
|
|
|
|
if $PKG_CONFIG --exists xfixes ; then
|
|
AC_DEFINE(HAVE_XFIXES, 1, Have the XFIXES X extension)
|
|
|
|
X11_LIBS="$X11_LIBS -lXfixes"
|
|
fi
|
|
|
|
AC_CHECK_HEADERS([GL/gl.h GL/glx.h],,
|
|
[AC_MSG_ERROR([Unable to locate required GL headers])])
|
|
|
|
AC_CHECK_LIB(GL, glXCreateContext, HAVE_LIBGL=yes, HAVE_LIBGL=no)
|
|
|
|
if test "x$HAVE_LIBGL" = "xno"; then
|
|
AC_MSG_ERROR(libGL not found);
|
|
else
|
|
GLX_LIBS="$X11_LIBS -lGL"
|
|
fi
|
|
|
|
GLX_CFLAGS="$X11_CFLAGS"
|
|
|
|
clutterbackend=glx
|
|
AC_ARG_WITH([flavour],
|
|
AC_HELP_STRING([--with-flavour=@<:@glx/egl@:>@],
|
|
[Select the Clutter backend]),
|
|
clutterbackend=$with_flavour)
|
|
|
|
AC_SUBST([clutterbackend])
|
|
case $clutterbackend in
|
|
glx)
|
|
CLUTTER_FLAVOUR="glx"
|
|
AC_DEFINE([HAVE_CLUTTER_GLX], 1, [Have the GLX backend])
|
|
;;
|
|
egl)
|
|
CLUTTER_FLAVOUR="egl"
|
|
AC_DEFINE([HAVE_CLUTTER_EGL], 1, [Have the EGL backend])
|
|
;;
|
|
*) AC_MSG_ERROR([Invalid backend for Clutter: use glx or egl])
|
|
;;
|
|
esac
|
|
|
|
AC_SUBST(CLUTTER_FLAVOUR)
|
|
|
|
clutterbackendlib=libclutter-$clutterbackend-$CLUTTER_MAJORMINOR.la
|
|
AC_SUBST([clutterbackendlib])
|
|
|
|
dnl ========================================================================
|
|
|
|
pkg_modules="pangoft2 glib-2.0 >= 2.8 gthread-2.0 gdk-pixbuf-2.0 gdk-pixbuf-xlib-2.0"
|
|
PKG_CHECK_MODULES(CLUTTER_DEPS, [$pkg_modules])
|
|
|
|
dnl ========================================================================
|
|
|
|
if test "x$GCC" = "xyes"; then
|
|
GCC_FLAGS="-g -Wall"
|
|
fi
|
|
|
|
dnl = Enable debug level ===================================================
|
|
|
|
m4_define([debug_default],
|
|
m4_if(m4_eval(clutter_minor_version % 2), [1], [yes], [minimum]))
|
|
|
|
AC_ARG_ENABLE(debug,
|
|
AC_HELP_STRING([--enable-debug=@<:@no/minimum/yes@:>@],
|
|
[turn on debugging. yes; All glib asserts, checks and runtime clutter verbose messages. minimum; Just glib cast checks and runtime clutter verbose messagaes. no; No glib asserts or checks and no runtime clutter verbose messages. @<:@default=debug_default@:>@]),
|
|
,
|
|
enable_debug=debug_default)
|
|
|
|
if test "x$enable_debug" = "xyes"; then
|
|
test "$cflags_set" = set || CFLAGS="$CFLAGS -g"
|
|
CLUTTER_DEBUG_CFLAGS="-DCLUTTER_ENABLE_DEBUG"
|
|
else
|
|
if test "x$enable_debug" = "xno"; then
|
|
CLUTTER_DEBUG_CFLAGS="-DG_DISABLE_ASSERT -DG_DISABLE_CHECKS -DG_DISABLE_CAST_CHECKS"
|
|
else # minimum
|
|
CLUTTER_DEBUG_CFLAGS="-DCLUTTER_ENABLE_DEBUG -DG_DISABLE_CAST_CHECKS"
|
|
fi
|
|
fi
|
|
|
|
AC_SUBST(CLUTTER_DEBUG_CFLAGS)
|
|
|
|
AC_ARG_WITH(fpu, AS_HELP_STRING([--without-fpu],
|
|
[Assume target hardware has no fpu]),
|
|
[with_fpu=$withval], [with_fpu=yes])
|
|
|
|
if test "x$with_fpu" != "xyes" ; then
|
|
CLUTTER_FIXED_CFLAGS="-DCFX_NO_FPU"
|
|
fi
|
|
|
|
dnl = GTK Doc check ========================================================
|
|
|
|
GTK_DOC_CHECK([1.4])
|
|
|
|
dnl ========================================================================
|
|
|
|
AC_SUBST(GCC_FLAGS)
|
|
|
|
CLUTTER_CFLAGS="$GLX_CLAGS $CLUTTER_DEPS_CFLAGS $CLUTTER_FIXED_CFLAGS"
|
|
CLUTTER_LIBS="$GLX_LIBS $CLUTTER_DEPS_LIBS"
|
|
|
|
AC_SUBST(CLUTTER_CFLAGS)
|
|
AC_SUBST(CLUTTER_LIBS)
|
|
|
|
AC_CONFIG_FILES([
|
|
Makefile
|
|
clutter/pango/Makefile
|
|
clutter/Makefile
|
|
clutter/clutter-version.h
|
|
clutter/glx/Makefile
|
|
clutter/egl/Makefile
|
|
examples/Makefile
|
|
doc/Makefile
|
|
doc/reference/Makefile
|
|
doc/reference/version.xml
|
|
clutter.pc
|
|
])
|
|
|
|
AC_OUTPUT
|
|
|
|
dnl ========================================================================
|
|
|
|
echo ""
|
|
echo " Clutter $VERSION"
|
|
echo " ==================="
|
|
echo ""
|
|
echo " prefix: ${prefix}"
|
|
echo ""
|
|
echo " Flavour: ${clutterbackend}"
|
|
echo " Debug level: ${enable_debug}"
|
|
echo " Documentation: ${enable_gtk_doc}"
|
|
echo " FPU: ${with_fpu}"
|
|
echo ""
|