Package support fixed.

Message names was resolved in wrong way when packages was specified.
Import definitions only from directly imporetd files.

TODO: support for "import public" should be added.