haskell / cabal

Official upstream development repository for Cabal and cabal-install
https://haskell.org/cabal
Other
1.61k stars 691 forks source link

Track external (pkgconfig) dependencies for custom setup script #3654

Open k0ral opened 8 years ago

k0ral commented 8 years ago

The haskell-gi-based packages are heavily relying on a custom Setup.hs that generates the haskell bindings to glib-based C libraries. Consequently, this process depends on the C library at setup-time, but it seems cabal only makes it possible to express a build-time dependency (through pkgconfig-depends within the library section). In systems like NixOS, this distinction matters a lot. Are you planning on supporting this use case in the future ? Otherwise, how would you suggest to overcome this untracked dependency issue ?

Thank you.

23Skidoo commented 8 years ago

Have you tried using build-type: Configure and generating a .buildinfo file?

ezyang commented 8 years ago

I don't think that helps; Configure runs a configure script which is still just a build-time dependency checker. So the answer is, no, we're pretty bad at tracking runtime deps.