How to build 32-bit builds on 64-bit Ubuntu
Phil Race
philip.race at oracle.com
Tue Oct 30 08:58:44 PDT 2012
On 10/30/2012 7:54 AM, Kelly Ohair wrote:
> keep in mind that a closed build will be different than an openjdk build with regards to X11 dependences
XRender is used in open and closed. I don't think there's much
difference wrt X11 for open vs. closed
for the packages. Probably zero difference at that level.
freetype is the only extra openjdk dependency that might be considered
such as its most frequently available
as part of X11 but it doesn't have to be and in fact is needed for
headless too ..
-phil.
>
> Sent from my iPhone
>
> On Oct 30, 2012, at 6:10, Magnus Ihse Bursie<magnus.ihse.bursie at oracle.com> wrote:
>
>> On 2012-10-30 05:03, David Holmes wrote:
>>> Hi Magnus,
>>>
>>> On 30/10/2012 1:59 AM, Magnus Ihse Bursie wrote:
>>>> I was asked to document how to build 32-bit builds on 64-bit Ubuntu.
>>>>
>>>> You need to install three packages:
>>>> sudo apt-get install libc6-dev-i386 lib32stdc++6 ia32-libs
>>> We also had to do:
>>>
>>> apt-get install libxext-dev:i386 libxrender-dev:i386 libxtst-dev:i386
>>>
>>> for X11. But these are the 32-bit libs that broke their 64-bit counterparts. I don't know exactly which one is to blame, or whether it has now been fixed upstream. We have had a lot of problems trying to install 32-bit libraries on these Ubuntu systems.
>> Yeah, I can imagine. If I understand apt-get correctly, you are forcing install of 32-bit libraries as if it were a 32-bit system you installed on.
>>
>> The libxext and libxtst packages seems to provide two .a files. Are these really needed? libxrender-dev provides libXrender.so, but the 32-bit version is provided in usr/lib32/libXrender.so by the package ia32-libs. That was all that I needed to install to be able to build for X11. (Without it, I could still build headless only).
>>
>> This might of course have changed from one Ubuntu release to another. I am using 11.04 Natty. (I know, it's really old, but I haven't been comfortable switching to Unity.)
>>
>>
>>>> However, these are broken, and do not place proper symlinks. (This is a
>>>> bug that should probably be reported upstream to Ubuntu, if anyone
>>>> bothers...). Therefore, you also need to do:
>>>> sudo ln -s /usr/lib32/libstdc++.so.6 /usr/lib32/libstdc++.so
>>>> sudo ln -s /usr/lib32/libasound.so.2 /usr/lib32/libasound.so
>>> We have not had to do this AFAIK for our servers. At least for libasound there is an asound-dev package that has to be installed. It may be lib32asound-dev (can't check as the build servers are offline due to the storm).
>> You are indeed correct, I had installed lib32asound2 and forgot about it. I also have lib32gcc1 installed, but I don't remember if I did that manually to support building reduced OpenJDK builds.
>>
>> /Magnus
>>
More information about the build-infra-dev
mailing list