$OpenBSD: patch-jdk_src_solaris_native_sun_java2d_x11_X11SurfaceData_c,v 1.2 2011/01/11 15:47:50 kurt Exp $
--- jdk/src/solaris/native/sun/java2d/x11/X11SurfaceData.c.orig	Fri Aug 13 03:22:14 2010
+++ jdk/src/solaris/native/sun/java2d/x11/X11SurfaceData.c	Mon Oct 25 18:15:59 2010
@@ -32,6 +32,7 @@
 #include "gdefs.h"
 
 #include "jni_util.h"
+#include "jvm_md.h"
 #include "awt_Component.h"
 #include "awt_GraphicsEnv.h"
 
@@ -163,7 +164,7 @@ Java_sun_java2d_x11_X11SurfaceData_initIDs(JNIEnv *env
 
     if (tryDGA && (getenv("NO_J2D_DGA") == NULL)) {
     /* we use RTLD_NOW because of bug 4032715 */
-        lib = dlopen("libsunwjdga.so", RTLD_NOW);
+        lib = dlopen(JNI_LIB_NAME("sunwjdga"), RTLD_NOW);
     }
 
     if (lib != NULL) {
