Fixed missing extern variable declarations resulting in multiple variable instances