//usr/bin/env root -l $0; exit $?
at the top of my ROOT macros works for me. Could you check?
(Also posted here)