Fix external module declarations