Fix getGlobalDB
Fix getGlobalDB

@snoyberg

I found that while trying to use this function to get the global Cabal
version that the full path needs to be package.conf.d for ghc-pkg:

λ> runStdoutLoggingT (getGlobalDB mempty)
[Debug] Calling ghc-pkg with: ["--no-user-package-db","list","--global"] @(stack-0.0.0:Stack.GhcPkg /home/chris/Work/stack/src/Stack/GhcPkg.hs:71:5)
"/opt/ghc/7.8.4/lib/ghc-7.8.4/"
λ> :!ghc-pkg "--no-user-package-db" "list" "--global"
/opt/ghc/7.8.4/lib/ghc-7.8.4/package.conf.d:
    Cabal-1.18.1.5
    array-0.5.0.0
    base-4.7.0.2
    bin-package-db-0.0.0.0
    binary-0.7.1.0
    rts-1.0
    bytestring-0.10.4.0
    containers-0.5.5.1
    deepseq-1.3.0.2
    directory-1.2.1.0
    filepath-1.3.0.2
    (ghc-7.8.4)
    ghc-prim-0.3.1.0
    haskeline-0.7.1.2
    (haskell2010-1.1.2.0)
    (haskell98-2.0.0.3)
    hoopl-3.10.0.1
    hpc-0.6.0.1
    integer-gmp-0.5.1.0
    old-locale-1.0.0.6
    old-time-1.1.0.2
    pretty-1.1.1.1
    process-1.2.0.0
    template-haskell-2.9.0.0
    terminfo-0.4.0.0
    time-1.4.2
    transformers-0.3.0.0
    unix-2.7.0.1
    xhtml-3000.2.1
λ> :!ghc-pkg list -f /opt/ghc/7.8.4/lib/ghc-7.8.4/
/opt/ghc/7.8.4/lib/ghc-7.8.4/:
    (no packages)
λ> :!ghc-pkg list -f /opt/ghc/7.8.4/lib/ghc-7.8.4/package.conf.d
/opt/ghc/7.8.4/lib/ghc-7.8.4/package.conf.d:
    Cabal-1.18.1.5

If this behaves differently on your system or Cabal doesn't interpret
this path the same let me know.

duplode/stack,adinapoli/stack,luigy/stack,Andrew-the-Ubergeek/stack,lukexi/stack,bixuanzju/stack,sjakobi/stack,Fuuzetsu/stack,AndrewRademacher/stack,mrkkrp/stack,akhileshs/stack,joozek78/stack,sjakobi/stack,kairuku/stack,juhp/stack,AndreasPK/stack,wskplho/stack,rubik/stack,phadej/stack,MaxGabriel/stack,vigoo/stack,athanclark/stack,agrafix/stack,lukexi/stack,Heather/stack,bollu/stack,MichielDerhaeg/stack,chreekat/stack,sinelaw/stack,DanielG/stack,rubik/stack,MichielDerhaeg/stack,rekka/stack,phadej/stack,GaloisInc/stack,tedkornish/stack,Heather/stack,rrnewton/stack,k-bx/stack,fizruk/stack,duplode/stack,achernyak/stack,bollu/stack,Denommus/stack,meiersi-11ce/stack,cabrera/stack,vigoo/stack,athanclark/stack,harendra-kumar/stack,supermario/stack,mathhun/stack,keent/stack,martin-kolinek/stack,wolftune/stack,martin-kolinek/stack,deech/stack,narrative/stack,Blaisorblade/stack,achernyak/stack,cabrera/stack,ant1441/stack,bixuanzju/stack,Andrew-the-Ubergeek/stack,Fuuzetsu/stack,fizruk/stack,rvion/stack,AndrewRademacher/stack,narrative/stack,GaloisInc/stack,hesselink/stack,sinelaw/stack,deech/stack,anton-dessiatov/stack,rekka/stack,adinapoli/stack,chadbrewbaker/stack,MaxGabriel/stack,joozek78/stack,Denommus/stack,luigy/stack,mrkkrp/stack,anton-dessiatov/stack,markus1189/stack,k-bx/stack,meiersi-11ce/stack,wskplho/stack,mathhun/stack,agrafix/stack,supermario/stack,cocreature/stack,keent/stack,juhp/stack,CRogers/stack,soenkehahn/stack,chadbrewbaker/stack,chreekat/stack,mietek/stack,AndreasPK/stack,tedkornish/stack,soenkehahn/stack,DanielG/stack,robstewart57/stack,kairuku/stack,robstewart57/stack,rvion/stack,cocreature/stack,markus1189/stack,CRogers/stack,Blaisorblade/stack,ant1441/stack,harendra-kumar/stack,akhileshs/stack,wolftune/stack,rrnewton/stack