[patch] Allow compiling against newer X11 headers
Vlastimil Babka
caster at gentoo.org
Mon Nov 2 13:06:23 PST 2009
Andrew John Hughes wrote:
> Hi Mark, Vlastimil,
Hi Andrew,
> Having seen both patches before, I'd personally prefer we just added
> the necessary headers if that works, rather than the additional cruft
> we have in the Fedora patch. We should do that in awt_GraphicsEnv.h
> though, as in the Fedora patch, which would also remove the need for
> the #ifdef MITSHM (it's in awt_GraphicsEnv.h already). So basically
> the Fedora patch but without the removal of the XShm.h include and the
> additional structs.
Sure, why not. I just included it in the .c file because the .h file
didn't use the constant and I hoped to minimize potential symbol
collisions or something (suspected something like that could be the
reason for the weird Fedora patch).
> Though I've been aware of this for a while, I deliberately haven't
> upgraded my own build systems to the new version because it will break
> OpenJDK builds for which we don't yet have a solution. Does anyone
> know of some versioning defines in the X headers that would avoid us
> having to use a configure check, and thus allow the patch to be
> submitted upstream? I believe the change
> (http://lists.x.org/archives/xorg-devel/2009-June/001242.html) appears
> in libXext 1.1.1 as Vlastimil says, but is there a way of detecting
> that other than with autoconf?
I don't know about versioning defines, but maybe the simple test Diego
suggested on our IRC channel could work in this case?
#include <XShm.h>
#ifndef X_ShmAttach
#include <X11/Xmd.h>
#include <X11/extensions/shmproto.h>
#endif
Vlastimil
More information about the distro-pkg-dev
mailing list