ANDROID: Fix darwin builds when out contains symlinks

The emulated readlink loop used on darwin builds was using
ls -l outdir | grep '\->' to detect if outdir is a symlink.
This has a false positive if outdir is not a symlink but
contains one or more symlinks, which is how the Android
builds deal with merging an hg forest into non-nested git
projects.  The false positive results in CANONICAL_TOPDIR
being set to a list of files and invalid make syntax
inserted into the generated spec.gmk file:
../build/macosx-x86_64-normal-server-release/spec.gmk:133: *** missing separator.  Stop.

Test: toolchain/jdk/build/build-openjdk-darwin.sh --version=9 gets further
Change-Id: I36fa53bcaee1cfc348e67c829623a1d0e2384a6c
1 file changed