I was not able to find an API function to get the CPU architecture of the loaded binary.
idaapi.py, there is a function
def set_processor_type(*args) but no equivalent such as
I don't want to fall back to running some additional (python) tool such as file, readelf or a python ELF parser. I also don't like the idea of parsing the strings displayed at the beginning of the IDA assembly listing.
There must be a way to use
idautils.py for this.