I also tried to remove things related to other package managers, such as Macports or Fink. It turned out I had none of these installed. I also logged in and out in this process, so I am not sure if that helped too.
One thing I noted is that macports had added things in the `.bash_profile ` setting of the `PATH`. Maybe worth checking your path: `echo $PATH` in the terminal?
Hope any of this could help, otherwise I have run out of ideas to help you. Good luck!