I encountered a problem when trying to run ROOT-based application without terminal. This can be illustrated on simple example: let’s say there is a macro browser.C which creates TBrowser window. I try to run:
nohup root -l browser.C
It causes TBrowser window to appear for a second and then it disappears. I also tried with some input/output and it makes no difference.
Ulitmatelly, what I need is to add execution of this application to bash_profile, so it automatically starts when machine is rebooted. In this case I don’t use nohup, but there is still no terminal attached to this process and it doesn’t work as well on SLC6 (for some reason with nohup it works on Mac OS).
The question is: how do I run ROOT without a terminal.
I am not sure if it helps or not, but the case I have to deal with is the Event Display of ALICE, so alieve from AliROOT. Previously it looked like there is no difference between running alieve and root. Now, after trying your examples I can see different behavior. In both cases (screen and main.cxx) it works for ROOT, but not for alieve. Concerning second example, in alieve instead of TApplication we create TRint, maybe it makes it different.