title: Haskell cabal: I just installed packages, but now the packages are not found
body: <p><a href="http://haskell.org/haskellwiki/Cabal-Install#I_just_installed_packages.2C_but_now_the_packages_are_not_found" rel="noreferrer">Over here</a> is the only reason I can find that packages I'm installing using <code>cabal</code> are not being found by GHC:</p>
  
  <blockquote>
    <p>This happens when you install a package globally, and the previous packages were installed locally. Note that cabal-install install locally by default [...]</p>
  </blockquote>
  
  <p>Presumably, "local installation" means putting packages in <code>~/.cabal/</code>.  First question: <strong>where are global installs?</strong></p>
  
  <p>I've been running <code>cabal</code> using <code>sudo</code>, so I guess that's a global install?  The reason I've been doing this is that it complains about permissions when run without <code>sudo</code>, so this contradicts the statement "cabal-install install locally by default".  Second question: <strong>how do I install locally and how do I install globally?</strong></p>
  
  <p>Trying to fix this mess, I've been randomly using <code>sudo ghc-pkg unregister</code> and randomly removing stuff from <code>~/.cabal/</code>.  Consequently my package tree is broken, probably locally and globally.  Third question: <strong>How do I start again?</strong></p>
  
  <hr>
  
  <p>Edit: I'm running Ubuntu 10.10.  I installed the Haskell Platform 2011.</p>