On 21 May 2012 11:08, Pauli Nieminen <span dir="ltr">&lt;<a href="mailto:pauli.nieminen@linux.intel.com" target="_blank">pauli.nieminen@linux.intel.com</a>&gt;</span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
There is a few places where glu is used without including the header.<br>
That produces warnings about missing functions. To silence compiler<br>
warnings glu header needs to be included.<br></blockquote><div><br>If I&#39;m not mistaken, glu is *usually* present on a conformant GL implementation, but it&#39;s not a guarantee, and it&#39;s usually not present on a conformant GLES implementation.  So I would rather decrease our dependence on it if possible.<br>
<br>It looks to like there are only two things we use glu for in these files:<br><br>(a) Calling gluErrorString() to translate an error enum to its string representation<br>(b) Calling gluPerspective() to set up a perspective transformation<br>
<br>These uses are simple enough that I think we would be better off just replacing them with code that doesn&#39;t use the glu library at all.  The calls to gluErrorString() can probably just be directly replaced with calls to piglit_get_gl_error_name().<br>
<br>As for the call to gluPerspective(), I think we could just replace it with a direct call to glFrustum() for now.  In the longer term we&#39;ll probably want to modify this test so that it doesn&#39;t rely on deprecated matrix stack functionality (that way it will be able to be run on GLES implementations and forward compatible contexts), but I think that can wait.<br>
 </div><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
Signed-off-by: Pauli Nieminen &lt;<a href="mailto:pauli.nieminen@linux.intel.com">pauli.nieminen@linux.intel.com</a>&gt;<br>
---<br>
 .../arb_shader_texture_lod/execution/texgrad.c     |    1 +<br>
 tests/spec/gl-2.0/api/clip-flag-behavior.c         |    1 +<br>
 tests/texturing/teximage-errors.c                  |    1 +<br>
 tests/texturing/texture-integer.c                  |    1 +<br>
 4 files changed, 4 insertions(+), 0 deletions(-)<br>
<br>
diff --git a/tests/spec/arb_shader_texture_lod/execution/texgrad.c b/tests/spec/arb_shader_texture_lod/execution/texgrad.c<br>
index a7bf6ec..64e8f49 100644<br>
--- a/tests/spec/arb_shader_texture_lod/execution/texgrad.c<br>
+++ b/tests/spec/arb_shader_texture_lod/execution/texgrad.c<br>
@@ -30,6 +30,7 @@<br>
  */<br>
<br>
 #include &quot;piglit-util.h&quot;<br>
+#include &lt;GL/glu.h&gt;<br>
<br>
 int piglit_window_mode = GLUT_RGB | GLUT_DOUBLE;<br>
 int piglit_width = 512;<br>
diff --git a/tests/spec/gl-2.0/api/clip-flag-behavior.c b/tests/spec/gl-2.0/api/clip-flag-behavior.c<br>
index f429c22..1b9450a 100644<br>
--- a/tests/spec/gl-2.0/api/clip-flag-behavior.c<br>
+++ b/tests/spec/gl-2.0/api/clip-flag-behavior.c<br>
@@ -37,6 +37,7 @@<br>
  */<br>
<br>
 #include &quot;piglit-util.h&quot;<br>
+#include &lt;GL/glu.h&gt;<br>
<br>
 int piglit_width = 100, piglit_height = 100;<br>
 int piglit_window_mode = GLUT_RGB | GLUT_DOUBLE;<br>
diff --git a/tests/texturing/teximage-errors.c b/tests/texturing/teximage-errors.c<br>
index 4a0aac7..6918329 100644<br>
--- a/tests/texturing/teximage-errors.c<br>
+++ b/tests/texturing/teximage-errors.c<br>
@@ -28,6 +28,7 @@<br>
  */<br>
<br>
 #include &quot;piglit-util.h&quot;<br>
+#include &lt;GL/glu.h&gt;<br>
<br>
 int piglit_width = 100, piglit_height = 100;<br>
 int piglit_window_mode = GLUT_RGB;<br>
diff --git a/tests/texturing/texture-integer.c b/tests/texturing/texture-integer.c<br>
index a256e0a..a055c4b 100644<br>
--- a/tests/texturing/texture-integer.c<br>
+++ b/tests/texturing/texture-integer.c<br>
@@ -28,6 +28,7 @@<br>
  */<br>
<br>
 #include &quot;piglit-util.h&quot;<br>
+#include &lt;GL/glu.h&gt;<br>
<br>
<br>
 int piglit_width = 100, piglit_height = 100;<br>
<span class="HOEnZb"><font color="#888888">--<br>
1.7.5.4<br>
<br>
_______________________________________________<br>
Piglit mailing list<br>
<a href="mailto:Piglit@lists.freedesktop.org">Piglit@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/piglit" target="_blank">http://lists.freedesktop.org/mailman/listinfo/piglit</a><br>
</font></span></blockquote></div><br>