fix compile with Mesa 10.0

Mesa 10.0 replaces struct wl_buffer with struct wl_resource in the
eglQueryWaylandBufferWL signature. The structures are binary compatible
(struct wl_buffer is a superset of struct wl_resource), but C++
complains about the type mismatch:

 error: cannot convert ‘wl_buffer*’ to ‘wl_resource*’ in argument passing

We are already using struct wl_resource on our side, so removing the now
redundant reinterpret_cast would fix it. But then we could not compile
with Mesa versions older than 10.0 any more, and those are still common
in mainstream distributions today.

A compile-time switch for different Mesa versions is possible, but
unnecessarily clumsy. Instead, re-declare the new signature and use that
independently of the Mesa version. The duplicate declaration can be
removed when backwards compatibility is no longer needed.

Change-Id: I3d0e326f5a0eb88d125b8c9fd23147682e23b94b