test $EUID instead of $UID

This is technically more correct in terms of the ability to
install macports. (Though in practice the user is unlikely to
encounter a scenario where $UID and $EUID differ.)