I think I made some progress on the issue. I have been using my Mac to build the source in native OS X environment. I removed MacPorts and installed Homebrew instead. I searched on the net for similar issues others had come across. It appeared to be related to broken symbolic links between used/gsed. Here's a link to that info:
After switching to Homebrew, I had no problems building a stock ROM. I did run into a problem when I tried generating certificates for using Superuser. Every time I executed the command development/tools/make_security..., I would get an error message and the keys would not be generated. I wonder if this is related to problems with openssl.
I built a VM on my older Mac with Ubuntu 12.0.04. Everything works fine. I am curious how to resolve the problem on my newer Mac. That machine is running openssl 0.98r.
Sent from my Full AOSP on Toro-VZW using RootzWiki
AOSP build with no Baseband-(Cdma Galaxy Nexus)