use "global" instead of "extern"