fix dependencies build order