| 325 | |
| 326 | @classmethod |
| 327 | def set_debug_flags(cls, d): |
| 328 | cls.gdbserver_port = 7777 |
| 329 | cls.debug_core = False |
| 330 | cls.debug_gdb = False |
| 331 | cls.debug_gdbserver = False |
| 332 | cls.debug_all = False |
| 333 | cls.debug_attach = False |
| 334 | if d is None: |
| 335 | return |
| 336 | dl = d.lower() |
| 337 | if dl == "core": |
| 338 | cls.debug_core = True |
| 339 | elif dl == "gdb" or dl == "gdb-all": |
| 340 | cls.debug_gdb = True |
| 341 | elif dl == "gdbserver" or dl == "gdbserver-all": |
| 342 | cls.debug_gdbserver = True |
| 343 | elif dl == "attach": |
| 344 | cls.debug_attach = True |
| 345 | else: |
| 346 | raise Exception("Unrecognized DEBUG option: '%s'" % d) |
| 347 | if dl == "gdb-all" or dl == "gdbserver-all": |
| 348 | cls.debug_all = True |
| 349 | |
| 350 | @classmethod |
| 351 | def get_vpp_worker_count(cls): |