I have no idea what this is supposed to be doing, given that the compilation scope doesn't run script. We should make sure this is reviewed by someone who remembers why this was written.