gdb has been more or less broken under OSX and was unusable under mojave, but there is hope...
This is description on how I got the latest release (dating fro 5.1.2019) up and running under mojave. In particular code signing has become more intricate under mojave since a debugger now needs the right entitlements not just a signature.
I'm assuming that a working gcc-8 installation is present (e.g. brew install gcc) and that a valid code signing certificate is in the SYSTEM keychain.
Here are the steps I took to get a working gdb: