ADT: missing “org.eclipse.wst.sse.core 0.0.0″ while installing sdk for eclipse on archlinux

在archlinux的eclipse上安装ADT的时候,出错了,错误提示是标题:missing “org.eclipse.wst.sse.core 0.0.0″。原因是eclipse的插件缺失造成的,只要把对应的插件安装上就可以了。参考链接为:http://code.google.com/intl/es/eclipse/docs/faq.html#wstinstallerror

简单来说主要需要添加插件的eclipse源,以便ADT安装时能够自动安装所依赖的包,我的eclipse的版本是3.7Eclipse 3.7(Indigo),源地址是:http://download.eclipse.org/releases/indigo

参考链接:http://androidcommunity.com/forums/f4/missing-org-eclipse-wst-sse-core-0-0-0-while-installing-sdk-for-eclipse-3-5-a-28714/

Posted in Android, linux应用, 技术为本 | 1 Comment

Unable to find root device-Archlinux(ZZ)

Problem Discription:

Today, when I open my computer, I find that I can not boot Archlinux successfully. I get an error message “ unable to find root device /dev/sda5” and is put into a recovery shell.  I try to boot Archlinux-fallback  and get the same error.

Error Source:

At first I think it is the problem of grub, so I type ‘e’ in the grub menu and try to modify grub. But I fail! Then I go to google in another computer and find the relevant information here. I learn that it is the  problem of my last upgrade. It is the udev package that goes wrong in the upgrade. It have to be reinstalled by the commands:
pacman -S udev
pacman -S linux Continue reading

Posted in linux应用, 技术为本 | 1 Comment

News: filesystem upgrade – manual intervention required(ZZ)

最近用上了archlinux,挺不错,不过升级系统的时候,出现错误,mtab有冲突,如果删除,又会出现空间不够的错误。google到了解决方法,如下:

When upgrading to filesystem-2011.12 there will be a conflict with /etc/mtab.

Install the package as follows:

pacman -S filesystem --force

It is strongly advised to avoid the --force or -f switch as it is not safe. However, in this particular case it is needed as deleting /etc/mtab manually would break pacman. Continue reading

Posted in linux应用, 技术为本 | 1 Comment

aptitude update – Error: Connection failed [IP: 127.0.0.1 8080]

最近ubuntu一直无法更新,开始也没注意,过去很久了一直不能更新。今天抽空看了一下,原来是proxy的问题。

错误提示是:Connection failed [IP: 127.0.0.1 8080]

解决办法是:

将/etc/apt/apt.conf文件里面有关代理的设置删掉。

OK。

Posted in linux应用 | Leave a comment

How to get Serial Number, Mac, or ANDROID ID of an Android Device(ZZ)

Hi,
I think many of you thought which is best to retrieve from the Android Device, so that you can be sure the device will not trick you and the identifier you asked is unique and unchangeable.
For example we can get the IMEI code but users would became suspicious because you will need to set a permission to use this, and beside this IMEI have only phones, not tablets.
You may choose to retrive ANDROID_ID with the following code: Continue reading

Posted in Android, Mobile, 技术为本, 文摘转贴 | Leave a comment

关于waitForCondition导致死锁的问题(zz)

waitForCondition 基本都出现在继承了类 GLSurfaceView 的情况下 , 出现死锁的位置一般是引用 egl.eglCreateWindowSurface(…) 或者 mEgl.eglSwapBuffers(…) 这两个方法的时候 .

避免出现 waitForCondition 的方法总结 :

  1. 在绘制线程中必须先合法的获取Surface 才能开始绘制内容,在SurfaceHolder.Callback.surfaceCreated() 和SurfaceHolder.Callback.surfaceDestroyed() 之间的状态为合法的,另外在Surface 类型为 SURFACE_TYPE_PUSH_BUFFERS 时候是不合法的. Continue reading
Posted in Android, Mobile, 技术为本, 文摘转贴 | Leave a comment

MD5 算法 (The MD5 Message-Digest Algorithm)

MD5即Message-Digest Algorithm 5(信息-摘要算法 5),用于确保信息传输完整一致。是计算机广泛使用的雜湊算法之一(又译摘要算法、哈希算法),主流编程语言普遍已有MD5实现。

在维基百科上有详细介绍,在各种语言上也都已有相应实现。
http://www.ietf.org/rfc/rfc1321.txt 上给出了算法介绍和C语言的实现。
我们在使用过程中发现一个问题,就是计算出来的MD5值有误。
经过调查,并非算法有问题,而是因为机器是64位系统导致的,在32位系统上就没问题。
为了通用性,只要把md5.h中的41行,修改一下就可以了。
typedef unsigned int UINT4;

Posted in C&C++, linux应用, 技术为本 | Leave a comment