Updated GLSL uniform/sampler handling from gallium-0.1 branch

Previously, the shader linker combined the uniforms used by the vertex and
fragment shaders into a combined set of uniforms.  This made the implementation
of glUniform*() simple, but was rather inefficient otherwise.  Now each shader
gets its own set of uniforms (no more modelview matrix showing up in the
fragment shader uniforms, for example).

cherry-picked by hand from gallium-0.1 branch
diff --git a/src/mesa/shader/prog_execute.c b/src/mesa/shader/prog_execute.c
index cb17aa5..d9bde3f 100644
--- a/src/mesa/shader/prog_execute.c
+++ b/src/mesa/shader/prog_execute.c
@@ -310,6 +310,8 @@
             const GLfloat texcoord[4], GLfloat lodBias,
             GLfloat color[4])
 {
+   const GLuint unit = machine->Samplers[inst->TexSrcUnit];
+
    /* Note: we only have the right derivatives for fragment input attribs.
     */
    if (machine->NumDeriv > 0 &&
@@ -320,12 +322,10 @@
       machine->FetchTexelDeriv(ctx, texcoord,
                                machine->DerivX[attr],
                                machine->DerivY[attr],
-                               lodBias,
-                               inst->TexSrcUnit, color);
+                               lodBias, unit, color);
    }
    else {
-      machine->FetchTexelLod(ctx, texcoord, lodBias,
-                             inst->TexSrcUnit, color);
+      machine->FetchTexelLod(ctx, texcoord, lodBias, unit, color);
    }
 }