Installing a 64 bit OS or keeping a 32 bit OS?
jonesc at hep.phy.cam.ac.uk
Fri Feb 1 12:13:32 UTC 2008
Jef Driesen wrote:
> Chris Jones wrote:
>>> Can I still run 32bit applications?
>> Yes, absolutely. You will need to install some 32 bit system libraries
>> along side their 64 bit versions (this may be default, I don't have a 64
>> bit ubuntu so cannot be sure here. Someone else who does can clarify this).
> But if I install a 32bit application, I also need to install a 32bit
> version of all its dependencies? Or is that not necessary?
Yes, any 32 bit application will need 32 bit versions all dynamic
libraries it needs. However, if you do this via apt/synaptic etc., this
should be done automatically for you.
I'm currently on a 64 bit redhat box, here the main 64bit system
libraries go in /usr/lib64 and /lib64 - However, in order to allow 32
bit binaries to run as well, the system also has 32 bit versions of the
same libraries in /usr/lib and /lib
The names might be different on ubuntu, I don't have a 64bit version of
that so cannot be sure, but the principle is the same.
The 32 bit libraries where not there by default, but they where
available in the standard software repositories it uses (via yum/rpm) -
I'm sure ubuntu must have a similar thing ?
>>> The laptop is mainly used for software development, so I would like to
>>> have a 64bit environment for testing my code. But I still need to be
>>> able to compile for a 32bit environment (and preferable test them as
>>> well). Is that possible?
>> yes, with gcc just use the "-m32" flag and that will force the 64 bit
>> compiler to build 32 bit binaries.
> Does that also work when linking with other libraries? I suppose a 64bit
> Ubuntu will have only 64bit libraries installed. How do I build the
> 32bit binary in that case?
If you want to build 32 bit binaries, you will need to install 32bit
versions of all libraries you need to link against. See above.
More information about the ubuntu-users