Add modifyArrayShape function.
Fix generation of the Futhark_build module.

This is now done as a post-configuration rather than as a pre-build
step.  The main improvement is that we can now build in a Cabal
sandbox (I hope).