brew install domq/gdb/<formula>
Or brew tap domq/gdb and then brew install <formula>.
brew tap domq/gdb
brew install <formula>
brew help, man brew or check Homebrew's documentation.
brew help
man brew