Hi Magnus,

Yes I've also run afoul of this when cross-compiling - mostly recently when we started doing 32-bit cross-compiles (for arm) on 64-bit x86.

As I understand this, sizers is to X11 Java code what the UnixConstants program is to the filesystem code. It has to determine various sizes of native data structures used by X11 so that those values can be handled correctly in the Java code (storing pointer and offsets in Java code to pass ot native). Unlike the UnixConstants these values only seem to differ between 32-bit and 64-bit, not across different OS, so our cross-compilation can use the data produced by sizers executing on the build host. (For UnixConstants we did have to bypass when cross-compiling and have generated Java classes checked in the repo - which isn't satisfactory either.

David

On 14/06/2012 7:12 PM, Magnus Ihse Bursie wrote:
We've had series of recurring issues with the xawt sizer wrapper (as
defined in jdk/make/sun/xawt/Makefile) -- we've called it the
X11Wrapper, I'm not sure if it has any other, more proper name.

First of all, I must ask: what is the purpose of this? Does anybody here
know, and can explain?

The logic of this makefile is quite convoluted, with multi-step
generation and execution. Is this really neccessary?

The real problem, from our point of view, is not the complex
generate/run/generate scheme -- make handles that for us. The problem is
the interaction between the build and target platform, and the reason
for having both 32 and 64-bit versions.

Appearantly, we build both a 32 and a 64 bit version on some platforms,
and then try to execute both. This works with varying degree of success
depending on what build OS you're using and how it is configured. :-)

Do we really need to do this? And why?

Also, for 64-bit solaris we compare the generated file with a checked-in
version, and if it differs, the build fail! So in reality, on this
platform, we're not really doing real build work, but rather verifying
that the build system looks like expected. But this is something that
should be done in configure, rather as part of the build. If this is the
real reason for this wrapper, could we perhaps generate these
sizes-files for all platforms and check them in, and just verify them as
part of configure?

/Magnus
(who have been working hard with the X11Wrapper for quite some time and
still is totally confused about it's purpose and workings)

Reply via email to