
On 22 February 2005 13:17, Krasimir Angelov wrote:
On Mon, 21 Feb 2005 17:56:08 -0800, Isaac Jones
wrote: * What any good package should have: package (name and version) :: PackageIdentifier, license :: License, -- OR? licenseFile :: FilePath, copyright :: String, maintainer :: String, synopsis :: String,
The good package should have these fields but they aren't required if you only want to build some code with Cabal. This will be the typical case with VSHaskell. The developer will use Cabal in order to build his/her projects but may never fill these fields. These fields are important when the developer decide to distribute the package. I think that Cabal should check only for "package" field, but Hackage should check for all fields.
Krasimir's right, I'd forgotten about this. Cabal is going to be used not just for distributing libraries & tools, but also just as a simple build system for local code (and why not?), and as the main build system for Visual Haskell. In which case there's no need to have the license, copyright, maintainer or synopsis fields - since you're not necessarily giving the code to anyone. Perhaps if you attempt to do './setup sdist' then it should complain if these fields are missing, but otherwise omitting them shouldn't be fatal. Cheers, Simon

"Simon Marlow"
On 22 February 2005 13:17, Krasimir Angelov wrote:
On Mon, 21 Feb 2005 17:56:08 -0800, Isaac Jones
wrote: * What any good package should have: package (name and version) :: PackageIdentifier, license :: License, -- OR? licenseFile :: FilePath, copyright :: String, maintainer :: String, synopsis :: String,
The good package should have these fields but they aren't required if you only want to build some code with Cabal. This will be the typical case with VSHaskell. The developer will use Cabal in order to build his/her projects but may never fill these fields. These fields are important when the developer decide to distribute the package. I think that Cabal should check only for "package" field, but Hackage should check for all fields.
Krasimir's right, I'd forgotten about this. Cabal is going to be used not just for distributing libraries & tools, but also just as a simple build system for local code (and why not?), and as the main build system for Visual Haskell.
Hmm. I have no problem with this, actually. I suppose that if Hackage has to reject a package due to missing fields, someone can just fix it. Hackage can document what fields it needs.
Perhaps if you attempt to do './setup sdist' then it should complain if these fields are missing, but otherwise omitting them shouldn't be fatal.
I like that idea, but sdist is currently broken, so it doesn't really make sense. We can implement that, though, and document it for now. How 'bout we give warnings during configure for missing fields? I can do that tonight. It's easy to change warnings to errors in PackageDescription if anyone wants to get to it sooner. peace, isaac
participants (2)
-
Isaac Jones
-
Simon Marlow