add global variables and predefined $GLOBALS (version 0.3.3)

Change-Id: Ieb59b418ed50e1ef65260a8a2593beb414b67870