gallium makefiles: use a linker script for building dri drivers

Only export __driDriverExtensions by default, and radeon_drm_winsys_create on radeons.
Remove -Bsymbolic which should no longer be needed.

As a side effect, it ought to fix a manifestation of bug 73200 on radeon.

Signed-off-by: Maarten Lankhorst<maarten.lankhorst@canonical.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
nouveau: create only 1 shared screen between vdpau and opengl

This fixes bug 73200 "vdpau-GL interop fails due to different screen
objects" in the same way radeon does.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
mesa: Preserve the NewArrays state when copying a VAO

Cc: "10.1" "10.0" <mesa-stable@lists.freedesktop.org>

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=72895
Reviewed-by: Brian Paul <brianp@vmware.com>
glsl: Add ARB_shader_image_load_store extension enables.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl: Add image type to the GLSL IR.

v2: Reuse the glsl_sampler_dim enum for images.  Reuse the
    glsl_type::sampler_* fields instead of creating new ones specific
    to image types.  Reuse the same constructor as for samplers adding
    a new 'base_type' argument.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl: Add helper methods to glsl_type for dealing with images.

Add predicates to query if a GLSL type is or contains an image.
Rename sampler_coordinate_components() to coordinate_components().

v2: Use assert instead of unreachable.
v3: No need to use a separate code-path for images in
    coordinate_components() after merging image and sampler fields in
    the glsl_type structure.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl: Add image memory and layout qualifiers to ir_variable.

v2: Add comment next to the read_only and write_only qualifier flags.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl: Add gl_uniform_storage fields to keep track of image uniform indices.

v2: Promote anonymous struct into named struct.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl/ast: Keep track of type qualifiers defined by ARB_shader_image_load_store.

v2: Add comment next to the read_only and write_only qualifier flags.
    Change temporary copies of the type qualifier mask to use uint64_t
    too.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl/lexer: Add new tokens for ARB_shader_image_load_store.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl/parser: Handle the early_fragment_tests input layout qualifier.

v2: Only allow the early_fragment_tests qualifier in fragment shaders.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl/parser: Handle image memory qualifiers.

v2: Make the "map" array static const.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl/parser: Handle image built-in types.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl/ast: Validate and apply memory qualifiers to image variables.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl/ast: Verify that function calls don't discard image format qualifiers.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl/ast: Make sure that image argument qualifiers match the function prototype.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl/ast: Forbid declaration of image variables in structures and uniform blocks.

Aggregating images inside uniform blocks is explicitly disallowed by
the standard, aggregating them inside structures is not (as of GL
4.4), but there is a similar problem as with atomic counters: image
uniform declarations require either a "writeonly" memory qualifier or
an explicit format qualifier, which are explicitly forbidden in
structure member declarations.  In the resolution of Khronos bug
#10903 the same wording applied to atomic counters was decided to mean
that they're not allowed inside structures -- Rejecting image member
declarations within structures seems the most reasonable option for
now.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl/ast: Generalize some sampler variable restrictions to all opaque types.

No opaque types may be statically initialized in the shader, all
opaque variables must be declared uniform or be part of an "in"
function parameter declaration, no opaque types may be used as the
return type of a function.

v2: Add explicit check for opaque types in interface blocks.  Check
    for opaque types in ir_dereference::is_lvalue().

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glsl: Add built-in types defined by ARB_shader_image_load_store.

Reviewed-by: Paul Berry <stereotype441@gmail.com>
glcpp: Add built-in define for ARB_shader_image_load_store.

Reviewed-by: Paul Berry <stereotype441@gmail.com>