gl-2.0: Test edgeflag in immediate mode with shader.

This is just a copy of the test edgeflag.c with client side arrays replaced
by immediate mode calls.
glsl-1.20: Access constant array of structs.

Add two tests:
Test reading from a constant array of structs.
Test reading from a constant array of structs with an array member.

This test provokes failed assertions in st/mesa: glsl_to_tgsi.
ARB_explicit_uniform_location: Remove unused variables.
util: Define strequal()

Please. Let's stop writing `!strcmp(...)` and `strcmp(...) == 0`.  This
patch defines a little function strequal() that reads much more nicely
than idioms using strcmp.

Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
util: Refactor parsing subtest args

Pre-patch, piglit-framework-gl.c:process_args() parsed subtest args
('-subtest' and '-list-subtests') with inline code. This patch moves
that code to a new function, piglit_parse_subtest_args().

This prepares for using Piglit's subtest magic in non-GL tests.
Currently, all the code for subtests lives in piglit-framework-gl.{c,h},
and so must be moved out to the API-independent piglit-util.{c,h}.

Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
util/gl: Reject unrecongized subtest names

If the user specifies "-subtest $NAME" on the command line, but
the test defines no subtest with that name, then
piglit_parse_subtest_args() now reports PIGLIT_FAIL.

The test should fail early as possible on usage errors. Pre-patch, if
the user requested an invalid subtest name, the test did not fail until
it attempted to execute the invalid subtest. Post-patch, the test fails
during arg parsing.

Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
util/gl: Rename struct piglit_gl_subtest -> piglit_subtest

This prepares for using Piglit's subtest magic in non-GL tests.

Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
util/gl: Rename PIGLIT_GL_SUBTEST_END -> PIGLIT_SUBTEST_END

This prepares for using Piglit's subtest magic for non-GL tests.

Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
util: Move subtest utils to API-independent files

Pre-patch, piglit-framework-gl.{c,h} defined the function and structs
for working with subtests. This patch moves them to piglit-util.{c,h},
so that they become available for non-GL tests.

This is simply a copy-paste patch. The patch does not modify the
relocated code.

Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
util/egl: Add EGLDisplay parameter to piglit_require_egl_extension()

This makes the signature of piglit_require_egl_extension() match that of
piglit_is_egl_extension_supported().

Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
WIP egl_khr_fence_sync: Add tests
KHR_fence_sync: Add TODO to test for EGL_BAD_MATCH for attributes that don't match a sync type

Can't test this until there are more sync types with unique attributes.
KHR_fence_sync: eglCreateSyncKHR: Test passing an invalid sync type
KHR_fence_sync: drop an effectively untestable bit of the spec
util/egl: piglit_egl_bind_api: Add a missing newline to an error message
util/egl: Add a checked version of eglGetProcAddress

The new piglit_egl_get_proc_address fails the test if eglGetProcAddress
returns NULL.
KHR_fence_sync: Use piglit_egl_get_proc_address to get extension functions