fix problem at module installation

ensure xmlids are defined before they are used