From owner-freebsd-gecko@FreeBSD.ORG Tue Aug 23 21:41:41 2011 Return-Path: Delivered-To: gecko@freebsd.org Received: from [127.0.0.1] (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by hub.freebsd.org (Postfix) with ESMTP id 9B427106566C for ; Tue, 23 Aug 2011 21:41:39 +0000 (UTC) (envelope-from jkim@FreeBSD.org) From: Jung-uk Kim To: gecko@freebsd.org Date: Tue, 23 Aug 2011 17:41:26 -0400 User-Agent: KMail/1.6.2 MIME-Version: 1.0 Content-Disposition: inline Content-Type: Multipart/Mixed; boundary="Boundary-00=_H6BVOG8RmaHnjS/" Message-Id: <201108231741.27971.jkim@FreeBSD.org> Cc: Subject: [PATCH] Firefox 6.0 and Mesa X-BeenThere: freebsd-gecko@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Gecko Rendering Engine issues List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Aug 2011 21:41:41 -0000 --Boundary-00=_H6BVOG8RmaHnjS/ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline After I upgraded Firefox to 6.0, I started getting very annoying messages like this: WARNING: Application calling GLX 1.3 function "glXCreatePixmap" when GLX 1.3 is not supported! This is an application bug! failed to create drawable I googled and found a bug was already filed and resolved by the upstream: https://bugzilla.mozilla.org/show_bug.cgi?id=659932 http://hg.mozilla.org/mozilla-central/rev/39fd1683ee6f A patch adopted for Firefox 6.0 release is attached. This patch does not "fix" the problem but the above annoying error messages are gone. Cheers, Jung-uk Kim --Boundary-00=_H6BVOG8RmaHnjS/ Content-Type: text/plain; charset="iso-8859-1"; name="patch-bugzilla-659932" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="patch-bugzilla-659932" --- toolkit/xre/glxtest.cpp.orig 2011-08-11 17:41:31.000000000 -0400 +++ toolkit/xre/glxtest.cpp 2011-08-23 15:09:48.000000000 -0400 @@ -114,6 +114,9 @@ typedef GLXFBConfig* (* PFNGLXQUERYEXTENSION) (Display *, int *, int *); PFNGLXQUERYEXTENSION glXQueryExtension = cast(dlsym(libgl, "glXQueryExtension")); + typedef GLXFBConfig* (* PFNGLXQUERYVERSION) (Display *, int *, int *); + PFNGLXQUERYVERSION glXQueryVersion = cast(dlsym(libgl, "glXQueryVersion")); + typedef GLXFBConfig* (* PFNGLXCHOOSEFBCONFIG) (Display *, int, const int *, int *); PFNGLXCHOOSEFBCONFIG glXChooseFBConfig = cast(dlsym(libgl, "glXChooseFBConfig")); @@ -139,6 +142,7 @@ PFNGLGETSTRING glGetString = cast(dlsym(libgl, "glGetString")); if (!glXQueryExtension || + !glXQueryVersion || !glXChooseFBConfig || !glXGetVisualFromFBConfig || !glXCreatePixmap || @@ -158,6 +162,14 @@ ///// Check that the GLX extension is present ///// if (!glXQueryExtension(dpy, NULL, NULL)) fatal_error("GLX extension missing"); + + ///// Check that the GLX version is >= 1.3, needed for glXCreatePixmap, bug 659932 ///// + int majorVersion, minorVersion; + if (!glXQueryVersion(dpy, &majorVersion, &minorVersion)) + fatal_error("Unable to query GLX version"); + + if (majorVersion < 1 || (majorVersion == 1 && minorVersion < 3)) + fatal_error("GLX version older than the required 1.3"); XSetErrorHandler(x_error_handler); --Boundary-00=_H6BVOG8RmaHnjS/--