[Haskell-cafe] Cabal, Time & GHC 6.10.2

2009-05-17 Thread Dominic Steinitz
I get

> d...@linux-6ofq:~/asn1> runghc Setup.hs configure
> Configuring PER-0.0.20...
> Setup.hs: At least the following dependencies are missing:
> time -any && -any

but I have time

> d...@linux-6ofq:~/asn1> ghc-pkg list | grep time
> old-locale-1.0.0.1, old-time-1.0.0.2, packedstring-0.1.0.1,
> time-1.1.2.4

I think I can see why cabal isn't finding it:

> ghc-pkg dump --global | grep time-1.1.2.4

finds nothing and I believe that is what cabal uses to find things.

What's not clear is what I do to fix things. Go back to 6.10.1?

Thanks, Dominic.

> d...@linux-6ofq:~/asn1> ghc --version
> The Glorious Glasgow Haskell Compilation System, version 6.10.2
> d...@linux-6ofq:~/asn1> ghc-pkg --version
> GHC package manager version 6.10.2

Here's my .cabal file.

> Name:PER
> Version: 0.0.20
> License: BSD3
> Author:  Dominic Steinitz
> Maintainer:  dominic.stein...@blueyonder.co.uk
> Copyright:   Dominic Steinitz 2003 - 2009
> Stability:   Alpha
> Category:Language
> Homepage:http://www.haskell.org/asn1
> Synopsis:ASN.1 PER support for Haskell
> Description: A formal and executable specification of the Packed Encoding 
> Rules (PER)
>  for ASN.1
> build-depends:   binary-strict == 0.4.2,
>  bytestring,
>  mtl,
>  containers,
>  time,
>  pretty,
>  base
> build-type:  custom
> 
> Exposed-Modules: Language.ASN1.PER.Integer
>  Language.ASN1.PER.GenerateC
> 
> Executable:  PERTest
> Main-Is: PERTest.hs

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Cabal, Time & GHC 6.10.2

2009-05-17 Thread Duncan Coutts
On Sun, 2009-05-17 at 09:17 +0100, Dominic Steinitz wrote:
> I get
> 
> > d...@linux-6ofq:~/asn1> runghc Setup.hs configure
> > Configuring PER-0.0.20...
> > Setup.hs: At least the following dependencies are missing:
> > time -any && -any
> 
> but I have time
> 
> > d...@linux-6ofq:~/asn1> ghc-pkg list | grep time
> > old-locale-1.0.0.1, old-time-1.0.0.2, packedstring-0.1.0.1,
> > time-1.1.2.4
> 
> I think I can see why cabal isn't finding it:
> 
> > ghc-pkg dump --global | grep time-1.1.2.4
> 
> finds nothing and I believe that is what cabal uses to find things.

The default for "runghc Setup.hs configure" is --global, but the default
for "cabal configure" is --user. So if you're using the "cabal" program
to install packages, then you can also us it to configure other
packages. If for you need to use the runghc Setup.hs interface (e.g. in
some system build scripts) and you want it to pick up packages from the
user package db then use the --user flag. If you're constantly having to
use the runghc Setup.hs interface and doing per-user installs is a pain
then you can set the default for the cabal program to be global installs
in the cabal config file (~/.cabal/config).

I'll add this issue to the FAQ, it come up enough. If anyone else
reading would like to eliminate this FAQ, then implementing this ticket
is the answer:

suggest use of --user if configure fails with missing deps that
are in the user db
http://hackage.haskell.org/trac/hackage/ticket/384

Duncan

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Cabal, Time & GHC 6.10.2

2009-05-24 Thread Dominic Steinitz
Duncan Coutts wrote:
> On Sun, 2009-05-17 at 09:17 +0100, Dominic Steinitz wrote:
>> I get
>>
>>> d...@linux-6ofq:~/asn1> runghc Setup.hs configure
>>> Configuring PER-0.0.20...
>>> Setup.hs: At least the following dependencies are missing:
>>> time -any && -any
>> but I have time
>>
>>> d...@linux-6ofq:~/asn1> ghc-pkg list | grep time
>>> old-locale-1.0.0.1, old-time-1.0.0.2, packedstring-0.1.0.1,
>>> time-1.1.2.4
>> I think I can see why cabal isn't finding it:
>>
>>> ghc-pkg dump --global | grep time-1.1.2.4
>> finds nothing and I believe that is what cabal uses to find things.
> 
> The default for "runghc Setup.hs configure" is --global, but the default
> for "cabal configure" is --user. So if you're using the "cabal" program
> to install packages, then you can also us it to configure other
> packages. If for you need to use the runghc Setup.hs interface (e.g. in
> some system build scripts) and you want it to pick up packages from the
> user package db then use the --user flag. If you're constantly having to
> use the runghc Setup.hs interface and doing per-user installs is a pain
> then you can set the default for the cabal program to be global installs
> in the cabal config file (~/.cabal/config).
> 
> I'll add this issue to the FAQ, it come up enough. If anyone else
> reading would like to eliminate this FAQ, then implementing this ticket
> is the answer:
> 
> suggest use of --user if configure fails with missing deps that
> are in the user db
> http://hackage.haskell.org/trac/hackage/ticket/384
> 
> Duncan
> 
> 
> 
Duncan,

Thanks very much. I'm happy to update the FAQ this weekend unless you
have already done it.

Dominic.

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Cabal, Time & GHC 6.10.2

2009-05-24 Thread Duncan Coutts
On Sun, 2009-05-24 at 12:04 +0100, Dominic Steinitz wrote:

> > I'll add this issue to the FAQ, it come up enough. If anyone else
> > reading would like to eliminate this FAQ, then implementing this ticket
> > is the answer:
> > 
> > suggest use of --user if configure fails with missing deps that
> > are in the user db
> > http://hackage.haskell.org/trac/hackage/ticket/384
> > 

> Thanks very much. I'm happy to update the FAQ this weekend unless you
> have already done it.

Oh that'd be great. The Cabal website is managed as a darcs repo so
just:

darcs get http://haskell.org/cabal/

then edit the FAQ.markdown and run make to update the FAQ.html (uses
pandoc). Then darcs send the patches to me or the cabal-devel mailing
list.

Duncan

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe