support android build

support android build
This commit does not affect to each submodule's original standalone build system.
Fixed type mismatch on 32bit system.