I installed Ubuntu 14.04 (Trusty Tahr) yesterday. Everything seems OK. But when I tried to compile some C code, I encounter the following error. The error seems to be due to the OS lacking the 32-bit architecture support. The error output is as following:
/usr/bin/ld: i386 architecture of input file `./libsc.a(ftl_msg.o)' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `./libsc.a(libsc_debug.o)' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `./libsc.a(libsc_str.o)' is incompatible with i386:x86-64 output
/usr/bin/ld: i386 architecture of input file `./libsc.a(libsc_cfg_common.o)' is incompatible with i386:x86-64 output
I used to apt-get install ia32-libs
when I was using UbuntuĀ 12.04 (Precise Pangolin). But what I know is that Ubuntu has removed the ia32-libs since UbuntuĀ 13.10 (Saucy Salamander). How can I fix this problem?
Best Answer
You can try this to install the 32-bit library (not all in ia32-libs):
sudo dpkg --add-architecture i386
may be required (if you haven't ever run that).Or if you want to install the whole ia32-lib instead, try the following order:
PS: In this way, you can install
ia32-libs
. However, we add the source of 13.04 instead, so, there may be some unknown problem. After installingia32-libs
, I recommend you to remove theia32-libs-raring.list
in/etc/apt/sources.list.d
, and dosudo apt-get update
.If you want to fix the dependency of Android SDK, you can try this bellow:
sudo apt-get install -y libc6-i386 lib32stdc++6 lib32gcc1 lib32ncurses5 lib32z1