Build system improvements.

Separate dependency fetching + building from installing.