Enlightenment CVS committal
Author : doursse
Project : e17
Module : libs/evas
Dir : e17/libs/evas
Modified Files:
configure.in
Log Message:
simplify detection of gl engines
===================================================================
RCS file: /cvs/e/e17/libs/evas/configure.in,v
retrieving revision 1.226
retrieving revision 1.227
diff -u -3 -r1.226 -r1.227
--- configure.in 6 Aug 2007 15:36:59 -0000 1.226
+++ configure.in 7 Aug 2007 10:18:51 -0000 1.227
@@ -531,90 +531,67 @@
#######################################
## Check if we should build the gl_x11 engine
+have_evas_gl_common="no"
have_evas_gl_x11="no";
## Automatic check...
- AC_CHECK_HEADER(GL/gl.h,
- [
- AC_CHECK_HEADER(X11/X.h,
- [ have_evas_gl_x11="yes" ],
- [ have_evas_gl_x11="no" ]
- )
- ],
- [ have_evas_gl_x11="no" ]
+AC_CHECK_HEADERS(GL/gl.h GL/glu.h X11/X.h,
+ [ have_evas_gl_x11="yes" ],
+ [ have_evas_gl_x11="no" ]
)
## manually disable gl engine by default - not auto detected.
have_evas_gl_x11="no"
## Manual override
-AC_MSG_CHECKING(whether gl x11 backend is to be built)
AC_ARG_ENABLE(gl-x11, [ --enable-gl-x11 enable the OpenGL X11
display engine], [
if test x"$enableval" = x"yes" ; then
- AC_MSG_RESULT(yes)
have_evas_gl_x11="yes"
else
- AC_MSG_RESULT(no)
have_evas_gl_x11="no"
fi
- ], [
- AC_MSG_RESULT($have_evas_gl_x11)
- ]
+ ]
)
+AC_MSG_CHECKING(whether gl x11 backend is to be built)
+AC_MSG_RESULT($have_evas_gl_x11)
+
if test "x$have_evas_gl_x11" = "xyes"; then
- AC_CHECK_HEADER(GL/gl.h,
- [
- AC_CHECK_HEADER(GL/glu.h,
- [
- AC_CHECK_HEADER(X11/X.h,
- [
- AM_CONDITIONAL(BUILD_ENGINE_GL_X11, true)
- AC_DEFINE(BUILD_ENGINE_GL_X11, 1, [OpenGL X11 Rendering Backend])
- AM_CONDITIONAL(BUILD_ENGINE_GL_COMMON, true)
- AC_DEFINE(BUILD_ENGINE_GL_COMMON, 1, [Generic OpenGL Rendering
Support])
- x_dir=${x_dir:-/usr/X11R6};
- x_cflags=${x_cflags:--I$x_dir/include}
- x_libs="${x_libs:--L$x_dir/lib -lX11 -lXext}"
- gl_cflags="-I/usr/include"
- gl_libs="-lGL -lGLU -lpthread"
- gl_dir=""
- ], [
- AM_CONDITIONAL(BUILD_ENGINE_GL_X11, false)
- AM_CONDITIONAL(BUILD_ENGINE_GL_COMMON, false)
- AC_MSG_RESULT(disabling GL X11 engine)
- have_evas_gl_x11="no"
- ]
- )
- ], [
- AM_CONDITIONAL(BUILD_ENGINE_GL_X11, false)
- AM_CONDITIONAL(BUILD_ENGINE_GL_COMMON, false)
- AC_MSG_RESULT(disabling GL X11 engine)
- have_evas_gl_x11="no"
- ]
- )
- ], [
- AM_CONDITIONAL(BUILD_ENGINE_GL_X11, false)
- AM_CONDITIONAL(BUILD_ENGINE_GL_COMMON, false)
- AC_MSG_RESULT(disabling GL X11 engine)
- have_evas_gl_x11="no"
- ]
+ AC_CHECK_HEADERS(GL/gl.h GL/glu.h,
+ [ have_evas_gl_common="yes" ],
+ [ have_evas_gl_x11="no" ]
)
-else
- AM_CONDITIONAL(BUILD_ENGINE_GL_X11, false)
- AM_CONDITIONAL(BUILD_ENGINE_GL_COMMON, false)
- have_evas_gl_x11="no"
+ if test "x$have_evas_gl_common" = "xyes"; then
+ AC_CHECK_HEADER(X11/X.h,
+ [
+ AC_DEFINE(BUILD_ENGINE_GL_X11, 1, [OpenGL X11 Rendering Backend])
+ AC_DEFINE(BUILD_ENGINE_GL_COMMON, 1, [Generic OpenGL Rendering
Support])
+ x_dir=${x_dir:-/usr/X11R6};
+ x_cflags=${x_cflags:--I$x_dir/include}
+ x_libs="${x_libs:--L$x_dir/lib -lX11 -lXext}"
+ gl_cflags="-I/usr/include"
+ gl_libs="-lGL -lGLU -lpthread"
+ gl_dir=""
+ ],
+ [
+ have_evas_gl_x11="no"
+ have_evas_gl_common="no"
+ ]
+ )
+ fi
fi
+AM_CONDITIONAL(BUILD_ENGINE_GL_COMMON, test "x$have_evas_gl_common" = "xyes")
+AM_CONDITIONAL(BUILD_ENGINE_GL_X11, test "x$have_evas_gl_x11" = "xyes")
+
#######################################
## Check if we should build the gl_glew engine
have_evas_gl_glew="no";
## Automatic check...
-AC_CHECK_HEADERS(GL/glew.h,
+AC_CHECK_HEADERS(GL/gl.h GL/glu.h GL/glew.h,
[ have_evas_gl_glew="yes" ],
[ have_evas_gl_glew="no" ]
)
## manually disable gl engine by default - not auto detected.
have_evas_gl_glew="no"
## Manual override
-AC_MSG_CHECKING(whether gl glew backend is to be built)
AC_ARG_ENABLE(gl-glew, [ --enable-gl-glew enable the OpenGL
Glew display engine], [
if test x"$enableval" = x"yes" ; then
have_evas_gl_glew="yes"
@@ -623,22 +600,31 @@
fi
]
)
+AC_MSG_CHECKING(whether gl glew backend is to be built)
AC_MSG_RESULT($have_evas_gl_glew)
-if test "x$have_evas_gl_glew" = "xyes"; then
- AC_CHECK_HEADER(GL/glew.h,
- [
- AC_DEFINE(BUILD_ENGINE_GL_GLEW, 1, [OpenGL Glew Rendering Backend])
- AC_DEFINE(BUILD_ENGINE_GL_COMMON, 1, [Generic OpenGL Rendering Support])
- glew_libs="-lglew32 -lopengl32 -lgdi32"
- gl_libs="-lglu32"
- ], [
- have_evas_gl_glew="no"
- ]
+if test "x$have_evas_gl_glew" = "xyes" ; then
+ AC_CHECK_HEADERS(GL/gl.h GL/glu.h,
+ [ have_evas_gl_common="yes" ],
+ [ have_evas_gl_glew="no" ]
)
+ if test "x$have_evas_gl_common" = "xyes" ; then
+ AC_CHECK_HEADER(GL/glew.h,
+ [
+ AC_DEFINE(BUILD_ENGINE_GL_GLEW, 1, [OpenGL Glew Rendering Backend])
+ AC_DEFINE(BUILD_ENGINE_GL_COMMON, 1, [Generic OpenGL Rendering
Support])
+ glew_libs="-lglew32 -lopengl32 -lgdi32"
+ gl_libs="-lglu32"
+ ],
+ [
+ have_evas_gl_glew="no"
+ have_evas_gl_common="no"
+ ]
+ )
+ fi
fi
+AM_CONDITIONAL(BUILD_ENGINE_GL_COMMON, test "x$have_evas_gl_common" = "xyes")
AM_CONDITIONAL(BUILD_ENGINE_GL_GLEW, test "x$have_evas_gl_glew" = "xyes")
-AM_CONDITIONAL(BUILD_ENGINE_GL_COMMON, test "x$have_evas_gl_glew" = "xyes" -o
"x$have_evas_gl_x11" = "xyes")
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs