I create gdb.cert and run this:
killall taskgated
codesign -fs gdb.cert /usr/local/bin/gdb
but it does not work, gives error:
Starting program: <path>
Unable to find Mach task port for process-id 46414: (os/kern) failure (0x5).
(please check gdb is codesigned - see taskgated(8))
What should I do?