NationalSecurityAgency / ghidra

Ghidra is a software reverse engineering (SRE) framework
https://www.nsa.gov/ghidra
Apache License 2.0
50.9k stars 5.8k forks source link

Recommendation: set java.awt.headless for analyzeHeadless #6859

Open infinitesteps opened 1 month ago

infinitesteps commented 1 month ago

When running analyzeHeadless from the command line (at least on macOS) a GUI is launched and steals UI focus. For batch scripting this is undesirable. I have added the following to analyzeHeadless and it works much better:

VMARG_LIST="$VMARG_LIST -Djava.awt.headless=true"

https://github.com/NationalSecurityAgency/ghidra/blob/2eb39242f9c2c37df796c66b2830f9aa48bfb034/Ghidra/RuntimeScripts/Linux/support/analyzeHeadless#L22

ryanmkurtz commented 1 month ago

We used to have this. I forget why we took it out.