64位Ubuntu无法安装 lib32stdc++6问题


在Ubuntu下安装Android开发环境,一切就绪后,项目编译出现问题:

    错误信息为:Cannot run program
    “/home/xxxx/android/android-sdk/platform-tools/adb”: error=2,
    没有那个文件或目录

原因:由于是64位的linux系统,而Android SDK只有32位的,需要安装一些支持包才能使用。安装:

sudo apt-get install lib32bz2-1.0

解决了这个问题。不过,又报了一个新的错误:编译找不到 libstdc++.so.6 文件

sudo apt-get install lib32stdc++6

继续安装lib32stdc++6, 出现问题:

    Reading package lists… Done Building dependency tree Reading
    state information… Done Some packages could not be installed. This
    may mean that you have requested an impossible situation or if you are
    using the unstable distribution that some required packages have not
    yet been created or been moved out of Incoming. The following
    information may help to resolve the situation:

    The following packages have unmet dependencies: lib32stdc++6 :
    Depends: gcc-4.8-base (= 4.8.2-19ubuntu1) but 4.8.4-2ubuntu1~14.04 is
    to be installed E: Unable to correct problems, you have held broken
    packages.

看起来是安装依赖出现了问题,解决办法:

sudo aptitude -f install lib32stdc++6

出现第一个Y/N选项时选N,第二个及之后选Y,一路下来即可。

问题搞定!


参看:

http://stackoverflow.com/questions/31119467/ubuntu-14-04-64bit-can-not-install-lib32stdc6

你可能感兴趣的:(64位Ubuntu无法安装 lib32stdc++6问题)