Support changing install destination of header files for `foreign-library`
- Dominant language
- Haskell
- Stars
- 1.7k
- Forks
- 750
- Avg merge
- 4d 3h
- Merged PRs (30d)
- 28
Description
Currently include files listed in `install-includes` are installed into `$libsubdir/include`.
This is reasonable for ordinally libraries that contain C headers.
On the other hand, for foreign-libraries, users may want to include headers into foreign lauguages.
But `$libsubdir` tend to be a very long, unfixed path name. So users have no way to specify include paths within their build tools.
The documentation says,
> With modern ghc regular libraries are installed in directories that contain package keys. This isn’t usually a problem because the package gets registered in ghc’s package DB and so we can figure out what the location of the library is. Foreign libraries however don’t get registered, which means that we’d have to have a way of finding out where a platform library got installed (other than by searching the lib/ directory). Instead, we install foreign libraries in ~/.cabal/lib, much like we install executables in ~/.cabal/bin.
(quoted from https://www.haskell.org/cabal/users-guide/developing-packages.html#foreign-libraries)
I think the same is true for header files.
So in my opinion, there should be a feature to change install destination of header files.
Contributor guide
Assessment
This issue has not been assessed yet.