This patch can be used to patch the "install" script on ns-allinone-2.35.tar.gz.
tar xfz ns-allinone-2.35.tar.gz
patch -p1 -i install.osx.patch
patch to "install" script
ns-2.36 (release candidate 1) should support OS X Yosemite now, so I think that this could be marked as "overcome by events"
more testing would be welcome: