envsetup: Fix remote functions to deal with symlinks

Change-Id: I6f35dc30dda22149b2c37e1c6c7d41ea7239d3bb
Merge pull request #3 from CyanogenMod/cm-10.2

envsetup: Fix remote functions to deal with symlinks