summaryrefslogtreecommitdiff
path: root/legacy/evas/m4/evas_check_engine.m4
diff options
context:
space:
mode:
authorCarsten Haitzler <raster@rasterman.com>2009-10-09 12:10:27 +0000
committerCarsten Haitzler <raster@rasterman.com>2009-10-09 12:10:27 +0000
commit37b66e806b098e545bc9d545cc452f64d7a64fda (patch)
treef0933ecdf82b0b5f1712823b464e0d3228d07844 /legacy/evas/m4/evas_check_engine.m4
parentfd65247e8eae475a63617cf9eee8444b3cc27329 (diff)
new gl engine. no one uses it anyway. not 100% complete, but much better than
the old. and it ALSO does GLES2.0 as well asn GL. SVN revision: 42982
Diffstat (limited to '')
-rw-r--r--legacy/evas/m4/evas_check_engine.m444
1 files changed, 37 insertions, 7 deletions
diff --git a/legacy/evas/m4/evas_check_engine.m4 b/legacy/evas/m4/evas_check_engine.m4
index 2eb44b1e5f..55c1fcb838 100644
--- a/legacy/evas/m4/evas_check_engine.m4
+++ b/legacy/evas/m4/evas_check_engine.m4
@@ -125,7 +125,7 @@ evas_engine_[]$1[]_libs=""
125AC_PATH_X 125AC_PATH_X
126AC_PATH_XTRA 126AC_PATH_XTRA
127 127
128AC_CHECK_HEADERS([GL/gl.h GL/glu.h GL/glx.h X11/X.h], 128AC_CHECK_HEADERS([GL/gl.h GL/glx.h X11/X.h],
129 [have_dep="yes"], 129 [have_dep="yes"],
130 [have_dep="no"]) 130 [have_dep="no"])
131 131
@@ -137,9 +137,8 @@ if test "x${have_dep}" = "xyes" ; then
137 AC_CHECK_LIB([GL], [glXCreateContext], [have_dep="yes"], [have_dep="no"]) 137 AC_CHECK_LIB([GL], [glXCreateContext], [have_dep="yes"], [have_dep="no"])
138fi 138fi
139 139
140if test "x${have_dep}" = "xyes" ; then 140## HACK: force gles build on systems that have glx
141 AC_CHECK_LIB([GLU], [gluNewTess], [have_dep="yes"], [have_dep="no"]) 141#have_dep=no
142fi
143 142
144if test "x${have_dep}" = "xyes" ; then 143if test "x${have_dep}" = "xyes" ; then
145 if test "x$2" = "xyes" ; then 144 if test "x$2" = "xyes" ; then
@@ -150,12 +149,43 @@ if test "x${have_dep}" = "xyes" ; then
150 x_libs="${x_libs:--L${x_libraries:-$x_dir/lib}} -lX11" 149 x_libs="${x_libs:--L${x_libraries:-$x_dir/lib}} -lX11"
151 fi 150 fi
152 evas_engine_[]$1[]_cflags="-I/usr/include ${x_cflags}" 151 evas_engine_[]$1[]_cflags="-I/usr/include ${x_cflags}"
153 evas_engine_[]$1[]_libs="${x_libs} -lGL -lGLU -lpthread" 152 evas_engine_[]$1[]_libs="${x_libs} -lGL -lpthread"
153 evas_engine_gl_common_libs="-lGL -lpthread"
154else
155 if test "x$2" = "xyes" ; then
156 x_libs="${x_libs} -lX11 -lXext"
157 else
158 x_dir=${x_dir:-/usr/X11R6}
159 x_cflags=${x_cflags:--I${x_includes:-$x_dir/include}}
160 x_libs="${x_libs:--L${x_libraries:-$x_dir/lib}} -lX11"
161 fi
162 AC_CHECK_HEADERS([EGL/egl.h X11/X.h X11/Xlib.h], [have_egl="yes"])
163 if test "x${have_egl}" = "xyes" ; then
164 have_gles20="no"
165 AC_CHECK_LIB(gles20, glTexImage2D, [have_gles20="yes"], , -lEGL)
166 if test "x${have_gles20}" = "xyes" ; then
167 evas_engine_[]$1[]_cflags="${x_cflags}"
168 evas_engine_[]$1[]_libs="${x_libs} -lgles20 -lEGL"
169 AC_DEFINE(GLES_VARIETY_S3C6410, 1, [Samsung S3c6410 GLES2 support])
170 evas_engine_gl_common_libs="-lgles20"
171 have_dep="yes"
172 fi
173 have_glesv2="no"
174 AC_CHECK_LIB(GLESv2, glTexImage2D, [have_glesv2="yes"], , -lEGL ${x_libs} -lpthread -lm)
175 if test "x${have_glesv2}" = "xyes" ; then
176 evas_engine_[]$1[]_cflags="${x_cflags}"
177 evas_engine_[]$1[]_libs="${x_libs} -lGLESv2 -lpthread -lm -lEGL"
178 AC_DEFINE(GLES_VARIETY_SGX, 1, [Imagination SGX GLES2 support])
179 evas_engine_gl_common_libs="-lGLESv2 -lpthread -lm"
180 have_dep="yes"
181 fi
182 fi
154fi 183fi
155 184
156AC_SUBST([evas_engine_$1_cflags]) 185AC_SUBST([evas_engine_$1_cflags])
157AC_SUBST([evas_engine_$1_libs]) 186AC_SUBST([evas_engine_$1_libs])
158 187
188
159if test "x${have_dep}" = "xyes" ; then 189if test "x${have_dep}" = "xyes" ; then
160 m4_default([$4], [:]) 190 m4_default([$4], [:])
161else 191else
@@ -394,10 +424,10 @@ AC_DEFUN([EVAS_CHECK_ENGINE_DEP_GL_GLEW],
394evas_engine_[]$1[]_cflags="" 424evas_engine_[]$1[]_cflags=""
395evas_engine_[]$1[]_libs="" 425evas_engine_[]$1[]_libs=""
396 426
397AC_CHECK_HEADERS([GL/gl.h GL/glu.h GL/glew.h], 427AC_CHECK_HEADERS([GL/gl.h GL/glew.h],
398 [ 428 [
399 have_dep="yes" 429 have_dep="yes"
400 evas_engine_[]$1[]_libs="-lglu32 -lglew32 -lopengl32 -lgdi32" 430 evas_engine_[]$1[]_libs="-lglew32 -lopengl32 -lgdi32"
401 ], 431 ],
402 [have_dep="no"] 432 [have_dep="no"]
403) 433)