shared library problems with eclipse on Ubuntu

筅森魡賤 提交于 2019-12-22 11:36:18

问题


I am using ubuntu 14.04 LTS 64 bits. and i installed eclipse Mars. and created "hello world" App. but the R class is always missing and never generated.

@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);//R cannot be resolved to a variable
}

and i did the folowing:

-clean project.

-delete the files in gen folder to be regenerated automatically

-checked the XML files in your resource folders and all has no errors

-right-click on the project->properties->Android to check that i am using the correct API

but the above mentioned steps did not solve the problem.

and the console output shows the following:

00] /home/guanr/Downloads/android-sdk-linux/build-tools/23.0.1/aapt: error     while loading shared libraries: libgcc_s.so.1: cannot open shared     object file: No such file or directory

Test_01] /home/guanr/Downloads/android-sdk-linux/build-tools/23.0.1/aapt: error while loading shared libraries: libgcc_s.so.1: cannot open shared object file: No such file or directory

please let me know how to solve it


回答1:


Looks like you need to install gcc library:

sudo apt-get install gcc-multilib


来源:https://stackoverflow.com/questions/32588471/shared-library-problems-with-eclipse-on-ubuntu

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!