Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Why is there a /usr/lib and a /usr/lib32 directory but only a /usr/bin and no /usr/bin32 directory on a AMD64 64-bit-install of Ubuntu? If or when Debian/Ubuntu start supporting multi-target-architecture binaries in their ELF's will this directory branching become unnecessary?

share|improve this question
    
Why does it matter ? If you need to link against a library, you need the corresponding arch, but if you call an external program, as long as it runs on your system, why would its architecture make a difference worth reflecting on the filesystem ? –  b0fh Jul 3 '12 at 7:05
add comment

2 Answers

up vote 1 down vote accepted

The idea is that you might want to install both 32-bit and 64-bit versions of the same library on your system, to accomodate binaries using either architecture, wherewas there is little point in having the same binary in two different architectures.

Some applications are very pointer-intensive, in which case running a 32-bit version for a small dataset could be more efficient as you'll save memory and reduce cache misses. That will only work up to 3GB of address space for i386 (or 2GB, depending on kernel compile time options).

If you run into a situation where a 32-bit binary makes more sense, you can recompile said binary yourself. However this is too much of a corner case for distributions to handle. If you feel this decision is wrong, you can always create a feature request.

Another sapproach is to install a 32-bit version of the whole distribution, and run it with a 64-bit kernel. This will work fine, each process will have access to 4GB of memory (instead of 3GB or less as mentioned earlier), the system can use more than 4GB of RAM, and the kernel doesn't need any of the tricks that 32-bit kernels use (eg PAE).

share|improve this answer
add comment

Debian already has multi-arch releases:

http://cdimage.debian.org/debian-cd/6.0.5/multi-arch/iso-cd/

You can install it and see how it's done.

share|improve this answer
    
Unfortunately, not exactly what OP is looking for. wiki.debian.org/Multiarch mentions that they only "co-installation of libraries and headers for different architectures, but not (yet) binaries". –  Pierre Carrier Jul 5 '12 at 22:52
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.