Build Failure on OpenSuSE 10.2 AMD 64 and Solution

Kelly O'Hair Kelly.Ohair at Sun.COM
Mon May 14 02:01:48 UTC 2007



Andreas Schaefer wrote:
> Hi
> 
> Petteri Räty wrote:
>> Andreas Schaefer kirjoitti:
>>   
>>> /usr/lib64/gcc/x86_64-suse-linux/4.1.2/../../../../x86_64-suse-linux/bin/ld:
>>> cannot find -lX11
>>>     
>> See that?
>>   
> Yes, I saw that and that what made me go installing X11. The strange
> thing is that there was only one X11.so (in ghostscript) and that after
> installing the additional RPMs I did not found any new X11.* files.
> 
> It also seems only to happen on AMD64 because with OpenSuSE on Intel
> 32-bit I did not have to install these packages.
>>   
>>> After installing X11-devel and X11-Server I could go with the build even
>>> though I have no clue what fixed it.
>>>
>>>     
>> You were missing the libraries so installing them fixed it. Of course it
>> would be better to check for them in the sanity check and fail with a
>> nice error message.
>>   
> Well, maybe but I am not quite sure if you can check for all
> dependencies. It is also difficult to keep up as you see with the
> AccColorT.h file that is not used to build but the sanity check looks
> for that file.
> 
> All of that is a strong incentive for me to have a Java-source-only
> build using Ant. It is way to complicated to build the Java source with
> the make file.
> 

Not sure what ant vs. make has to do with sanity checks and native libraries
missing, seems like they are a pain no matter what you use to build.

Just building the java source is worth investigating, but keep in mind
that we need to clean up the javac/recompile build ordering issue we have.
Right now, we use the boot jdk (stage 1) to build a javac from the jdk sources plus
enough runtime for this new first stage2 javac to run. These classes are
built by the boot javac, and usually aren't the final ones we want.
Then we take the stage2 javac we built and recompile everything javac
needs again, this gives us a new javac built from itself so to speak,
then we compile all the rest of the java source of the jdk.
The fact that we run what we build during the build process means that
any java sources that are backed up with JNI native libraries must
get their native code compiled after the java classes are built.
Since you need the javah headers to compile the native code, you need
the classes files first, then run javah, then run the native C/C++ compiler.
It's pretty convoluted.

But we plan on changing this soon, and in such a way that the entire
jdk is built completely, and running the build at all isn't required to get
a build. In other words, we remove the javac recompile stage2 compiler
and use a prebuilt javac from the javac team.
These changes are in the works, and should make things simplier to
build, and faster too.
The recompile process will be removed and delegated to the javac
team.

-kto

> -Andy



More information about the build-dev mailing list