[OpenJDK 2D-Dev] RFR(XS): 8213944: Fix AIX build after the removal of Xrandr.h and add a configure check for it

Volker Simonis volker.simonis at gmail.com
Fri Nov 16 10:22:52 UTC 2018


On Thu, Nov 15, 2018 at 6:01 PM Philip Race <philip.race at oracle.com> wrote:
>
> PS I am not sure why xrandr headers would not be available for AIX.
> They are a standard part of the xdistribution.
>

I'm not an X11 guru, but as far as I understand, xrandr is an
extension and as such it doesn't have to be supported by every
implementation. To the best of my knowledge (I've just started another
poll among some experts) AIX doesn't support Xrandr and does not have
the corresponding headers.

> If true, think what you are going to have to do is add a
> --with-xrandr-include option
> and provide it that way.
>

What if there are no standard Xrandr headers on a platform? Do you
really want to force users to get them from some dubious sources just
for building the OpenJDK? Sorry, but I don't think that's a good
solution. Than I'd rather prefer the ugly ifdefs (or I check the
headers back in again in an AIX-specific directory :)

Thank you and best regards,
Volker

> -phil.
>
> On 11/15/18, 8:55 AM, Philip Race wrote:
> > Hmm. I don't like the ifdefs.
> >
> > Xrandr is a requirement for the build. If its not there at runtime
> > that's OK.
> >
> > -phil.
> >
> > On 11/15/18, 8:06 AM, Volker Simonis wrote:
> >> Hi,
> >>
> >> can I please have a review for the following small change:
> >>
> >> http://cr.openjdk.java.net/~simonis/webrevs/2018/8213944/
> >> https://bugs.openjdk.java.net/browse/JDK-8213944
> >>
> >> Change JDK-8210863 removed the Xrandr.h/randr.h headers from the
> >> OpenJDK sources but forgot to add a configure check for the Xrandr
> >> extension which is now a build dependency.
> >>
> >> The change also broke the AIX build. AIX never supported Xrandr, but
> >> that was only detected at runtime, when the JDK was unable to
> >> dynamically load libXrand.so. Now, without Xrandr.h/randr.h in the
> >> source tree any more, we have to conditionally compile some parts of
> >> src/java.desktop/unix/native/libawt_xawt/awt/awt_GraphicsEnv.c such
> >> that it doesn't require the definitions and declarations from
> >> Xrandr.h/randr.h any more.
> >>
> >> Thank you and best regards,
> >> Volker


More information about the 2d-dev mailing list