Implement 'cabal sandbox hc-pkg'.

See #1200 (for which this is a partial fix).
Merge pull request #1273 from 23Skidoo/sandbox-hc-pkg

Implement 'cabal sandbox hc-pkg'.