
I've got a library that needed some simple matrix computation, so I added the bedandbreakfast package. While my library builds fine on both 7.6 and 7.8, the last released version of that package won't build on 7.8. However, the current HUB was update a couple of weeks ago, and now builds on 7.8. Is there some way to capture that information in a cabal file? That if you're using GHC 7.8, you need bedandbreakfast >= 5.*, but for GHC7.6 you can use bedandbreakfast >= 4.*? I did send an email to the maintainer a little over a week ago asking if he could do a release, and haven't gotten either a reply or a release. Any suggestions on what I should do about releasing the updated version of my library?

Hi Mike, something like this should do the trick (untested):
```
flag ghc78
description: Using GHC >= 7.8
default: True
library
if flag(ghc78)
build-depends:
base >= 4.7
bedandbreakfast >= 5
else
build-depends:
base < 4.7
bedandbreakfast >= 4
```
This uses a non-manual flag so cabal will toggle it if it needs to.
HTH,
Adam
On Wed, Sep 10, 2014 at 8:20 PM, Mike Meyer
I've got a library that needed some simple matrix computation, so I added the bedandbreakfast package. While my library builds fine on both 7.6 and 7.8, the last released version of that package won't build on 7.8. However, the current HUB was update a couple of weeks ago, and now builds on 7.8.
Is there some way to capture that information in a cabal file? That if you're using GHC 7.8, you need bedandbreakfast >= 5.*, but for GHC7.6 you can use bedandbreakfast >= 4.*?
I did send an email to the maintainer a little over a week ago asking if he could do a release, and haven't gotten either a reply or a release.
Any suggestions on what I should do about releasing the updated version of my library?
_______________________________________________ Libraries mailing list Libraries@haskell.org http://www.haskell.org/mailman/listinfo/libraries

Ok, that works fine - except that bedandbreakfast 0.5 hasn't been released
yet :-(. Is there anything I can do other than add a note to add the head
from github as a sourcce, and send a note to the maintainer asking for a
release :-)?
Thanks,
Mike
On Wed, Sep 10, 2014 at 1:41 PM, Adam Bergmark
Hi Mike, something like this should do the trick (untested):
``` flag ghc78 description: Using GHC >= 7.8 default: True
library if flag(ghc78) build-depends: base >= 4.7 bedandbreakfast >= 5 else build-depends: base < 4.7 bedandbreakfast >= 4 ```
This uses a non-manual flag so cabal will toggle it if it needs to.
HTH, Adam
On Wed, Sep 10, 2014 at 8:20 PM, Mike Meyer
wrote: I've got a library that needed some simple matrix computation, so I added the bedandbreakfast package. While my library builds fine on both 7.6 and 7.8, the last released version of that package won't build on 7.8. However, the current HUB was update a couple of weeks ago, and now builds on 7.8.
Is there some way to capture that information in a cabal file? That if you're using GHC 7.8, you need bedandbreakfast >= 5.*, but for GHC7.6 you can use bedandbreakfast >= 4.*?
I did send an email to the maintainer a little over a week ago asking if he could do a release, and haven't gotten either a reply or a release.
Any suggestions on what I should do about releasing the updated version of my library?
_______________________________________________ Libraries mailing list Libraries@haskell.org http://www.haskell.org/mailman/listinfo/libraries

On Wed, Sep 10, 2014 at 2:20 PM, Mike Meyer
I've got a library that needed some simple matrix computation, so I added the bedandbreakfast package. While my library builds fine on both 7.6 and 7.8, the last released version of that package won't build on 7.8. However, the current HUB was update a couple of weeks ago, and now builds on 7.8.
Is there some way to capture that information in a cabal file? That if you're using GHC 7.8, you need bedandbreakfast >= 5.*, but for GHC7.6 you can use bedandbreakfast >= 4.*?
While you can do this, there's really no reason to. All your package depends on is any version of bedandbreakfast that the user can install. cabal will prefer to install newer versions of packages over older ones, so I don't think there's any situation in which adding this information to your cabal file would allow your package to install when it otherwise wouldn't. Your real problem, as you note, is just that bedandbreakfast 5 is not available on hackage. Regards, Reid Barton

Whoops, missed that part!
If you want a new version to be uploaded see
http://www.haskell.org/haskellwiki/Taking_over_a_package
Taking over a package takes some time, as it should. If you can't wait you
can inline the package into yours for the time being.
On Wed, Sep 10, 2014 at 8:56 PM, Reid Barton
On Wed, Sep 10, 2014 at 2:20 PM, Mike Meyer
wrote: I've got a library that needed some simple matrix computation, so I added the bedandbreakfast package. While my library builds fine on both 7.6 and 7.8, the last released version of that package won't build on 7.8. However, the current HUB was update a couple of weeks ago, and now builds on 7.8.
Is there some way to capture that information in a cabal file? That if you're using GHC 7.8, you need bedandbreakfast >= 5.*, but for GHC7.6 you can use bedandbreakfast >= 4.*?
While you can do this, there's really no reason to. All your package depends on is any version of bedandbreakfast that the user can install. cabal will prefer to install newer versions of packages over older ones, so I don't think there's any situation in which adding this information to your cabal file would allow your package to install when it otherwise wouldn't.
Your real problem, as you note, is just that bedandbreakfast 5 is not available on hackage.
Regards, Reid Barton
_______________________________________________ Libraries mailing list Libraries@haskell.org http://www.haskell.org/mailman/listinfo/libraries
participants (3)
-
Adam Bergmark
-
Mike Meyer
-
Reid Barton