C++11 and aliasing fixes.

Conflicts:
	Android.mk
Fix some build issues.