I also think, this don't belong here, but I answer, like you asked about the tools in general.
MacPorts is the Mac version of the bsd package manager "port" (Mac is in fact a bsd derivate, not Linux). homebrew is a (as I know) package manager written from scratch. MacPorts does his magic in the /opt directory, homebrew normally ins /usr/local/Cellar. the fact, I prefer homebrew, is that you can install homebrew just via cloning a git repo, adapting path and that's it. you can install homebrew everywhere, updates come via git pull
and all packages are prefixed into that directory. additionally permissions are managed so you don't need sudo.
pip is a python package manager, it serves python packages, ruby gems are the same written in ruby
one last word: any package manager won't update your system. it installs the packages from scratch and modify the path so you actually use those tools installed. they are not ment to keep your system up-to-date, they should provide additional software