Fixes build dependencies for messages