ddssff / cabal-debian

Create a Debianization by examining a .cabal file.
Other
16 stars 10 forks source link

cabal-debian does not detect pkg-config #57

Open ivanperez-keera opened 7 years ago

ivanperez-keera commented 7 years ago

Cabal-debian does not detect the need for pkg-config.

An example of a package that needs pkg-config is HOpenCV.

The resulting control file does not require pkg-config, so the build breaks:

https://launchpadlibrarian.net/318334013/buildlog_ubuntu-xenial-amd64.hopencv_0.4.0.1-0~xenial_BUILDING.txt.gz

Configuring HOpenCV-0.4.0.1...
Dependency allocated-processor >=0.0.1: using allocated-processor-0.0.2
Dependency base ==4.*: using base-4.8.2.0
Dependency vector-space -any: using vector-space-0.10.2
hlibrary.setup: The program 'pkg-config' version >=0.9.0 is required but it
could not be found.

The need for pkg-config is mentioned in HOpenCV's cabal file. So, cabal-debian could, in principle, deduce it.

ddssff commented 7 years ago

So if there is a pkgconfig-depends field in the cabal file a build dep should be added on pkg-config?

ivanperez-haskell commented 7 years ago

I think so, yes.