Cabal's configure doesn't notice missing headers

Duncan Coutts duncan.coutts at worc.ox.ac.uk
Mon Mar 17 19:52:18 EDT 2008


On Mon, 2008-03-17 at 23:23 +0200, Valery V. Vorotyntsev wrote:
> Hi,
> 
> while installing zlib[1] from hackage, I've discovered possible Cabal's
> misbehaviour.
> 
> There was no `zlib.h' in my system. runhaskell Setup configure went fine, with
> no complaints. It was only during build step when missing header had been
> noticed and an error reported.
> apt-get install zlib1g-dev; and zlib cabal package installation
> succeeded, but...
> 
> Closer to my question. `zlib.h' _is_ mentioned in zlib.cabal:
>   includes:  zlib.h
> According to documentation[2], `includes' "field applies to both header files
> that are already installed on the system and to those coming with the package
> to be isntalled." [NB the typo]
> 
> I think that Cabal should complain of missing headers during configuration step.
> At least of the ones explicitly mentioned in `includes:' field.

Yes, I think so too. I mentioned this in ticket #177

http://hackage.haskell.org/trac/hackage/ticket/177#comment:5

Perhaps you could file a separate ticket about checking that all
specified header files and C libs can be found at configure time. We'd
want to use the same technique that autoconf uses.

If you or anyone else wants to work on implementing the check then
that'd be great. We're aiming for a Cabal-1.4 release in the next month
or so.

Duncan



More information about the Libraries mailing list