Fix current staging plugin

Missing some imports and build only localdep
Improve check phase in staging plugin

It now checks not only for changed packages but also for changes in build
state.
Merge pull request #49 from miska/master

Little improvement of staging plugin