Friday, August 28, 2009

NoCheatCalls(NCC)可疑電話通報


寫了篇文章介紹前段時間寫的防詐騙公益程式。



Sunday, August 16, 2009

Introduction of Android Scripting Environment



On Coscup 2009

Saturday, August 15, 2009

Google Python Style Guide

http://google-styleguide.googlecode.com/svn/trunk/pyguide.html

Thursday, August 13, 2009

Compiling Python for Android Scripting Environment

Android Scripting Environment (ASE) is the scripting language (BeanShell, Python, Lua, Ruby) environment for Android Operating System.

This article is about how to compile python for ASE.

The following instructions are according to the discussion from ASE group.

Compile python for host
To compile python for ASE, you need a Linux machine, then here goes:

Download proper python source distribution (according to the python version in ase/python/src) from http://www.python.org/

Extract the source and run the following command:

$ cd Python-2.6.2
$ ./configure
$ make

Then you have a clean python compiled for your PC (called host system).

Compile python for target
Now we can go to compile python for your Android device (called target system).

Copy the python executable file and the pgen file into ase/python/src folder

$ cd ~
$ cp Python-2.6.2/python ase/python/src/hostpython
$ cp Python-2.6.2/Parser/pgen ase/python/src/Parser/hostpgen

Then we should prepare the compile tools.

First checkout the android source from http://source.android.com/ (name as mydroid), we'll use the cross compile gcc in it's "prebuilt/linux-x86/toolchain/arm-eabi-4.2.1/bin" folder. Another tool is located in "ase/tools/agcc".

Edit .bashrc , add a line to include those compile tools:
export PATH=${PATH}:~/mydroid/prebuilt/linux
-x86/toolchain/arm-eabi-4.2.1/bin:~/ase/tools/agcc

Then start compile python for ASE.

$ cd ase/python
$ ./build.py

Done!

Wednesday, August 05, 2009

AppStore Rules

不管在哪個環境下開發給使用者用的應用程式都得先自我審查,過了自己這一關再把程式丟出去。