Relative paths in cabal.project files don't work as expected
- Dominant language
- Haskell
- Stars
- 1.7k
- Forks
- 750
- Avg merge
- 4d 3h
- Merged PRs (30d)
- 28
Description
I want to pass some options to a dependency. So I added the flags to my cabal.project file as follows.
```
package groups
ghc-options: -fwrite-ide-info -hiedir=./test/hie-files
```
However, now `groups` is rebuilt but the `hie` files are not in the directory I specified and nor are they anywhere to be seen at all! I can't find them anywhere in my home directory.
If I write an absolute path it works fine.
Why I consider this a bug, if I `cabal get groups`, modify the cabal file to add the ghc-options and add it as a local dependency then the path is resolved relative to the cabal file.
Contributor guide
Research direction
Start with the cabal.project package stanza containing ghc-options and compare how relative paths are handled for a local dependency versus the external groups dependency obtained with cabal get. Reproduce the -hiedir behavior, then confirm that the generated HIE files appear in the documented relative location without requiring an absolute path.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- haskell
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100