diff options
author | Andrew Burgess <andrew.burgess@embecosm.com> | 2020-08-27 16:53:13 +0100 |
---|---|---|
committer | Andrew Burgess <andrew.burgess@embecosm.com> | 2021-04-28 09:56:22 +0100 |
commit | edeaceda7b2f33b2c3bf78c732e67f3188e7f0b9 (patch) | |
tree | 4a42856ef94f912794b339aa6cdec12616e2c978 /bfd/elf32.c | |
parent | 041ca48e976b9a2a39a9440f7fbc2dffc77ed7c1 (diff) | |
download | gdb-edeaceda7b2f33b2c3bf78c732e67f3188e7f0b9.zip gdb-edeaceda7b2f33b2c3bf78c732e67f3188e7f0b9.tar.gz gdb-edeaceda7b2f33b2c3bf78c732e67f3188e7f0b9.tar.bz2 |
gdb: startup commands to control Python extension language
Add two new commands to GDB that can be placed into the early
initialization to control how Python starts up. The new options are:
set python ignore-environment on|off
set python dont-write-bytecode auto|on|off
show python ignore-environment
show python dont-write-bytecode
These can be used from GDB's startup file to control how the Python
extension language behaves. These options are equivalent to the -E
and -B flags to python respectively, their descriptions from the
Python man page:
-E Ignore environment variables like PYTHONPATH and PYTHONHOME
that modify the behavior of the interpreter.
-B Don't write .pyc files on import.
gdb/ChangeLog:
* NEWS: Mention new commands.
* python/python.c (python_ignore_environment): New static global.
(show_python_ignore_environment): New function.
(set_python_ignore_environment): New function.
(python_dont_write_bytecode): New static global.
(show_python_dont_write_bytecode): New function.
(set_python_dont_write_bytecode): New function.
(_initialize_python): Register new commands.
gdb/doc/ChangeLog:
* python.texinfo (Python Commands): Mention new commands.
gdb/testsuite/ChangeLog:
* gdb.python/py-startup-opt.exp: New file.
Diffstat (limited to 'bfd/elf32.c')
0 files changed, 0 insertions, 0 deletions