Support wildcards in c-sources and cxx-sources?
- Dominant language
- Haskell
- Stars
- 1.7k
- Forks
- 750
- Avg merge
- 4d 3h
- Merged PRs (30d)
- 28
Description
**Describe the feature request**
Support wildcards in c-sources and cxx-sources, e.g.
```
c-sources: cbits/*.c other_cbits/**/*.c
```
**Additional context**
Some time ago, I created a library with extensive C source codes - not the best decision. Today, I stumbled upon some intriguing comments in the GHC rts.cabal file:
https://gitlab.haskell.org/ghc/ghc/-/blob/master/rts/rts.cabal.in#L665
```
-- I wish we had wildcards..., this would be:
-- *.c hooks/**/*.c sm/**/*.c eventlog/**/*.c linker/**/*.c
```
(If there is already any other issue with this, please tell me or just close this one. I only found this related one: https://github.com/haskell/cabal/issues/206)
Contributor guide
Research direction
Start by tracing how Cabal handles the c-sources and cxx-sources fields, then compare the requested behavior with the linked GHC rts/rts.cabal.in example. Done means wildcard patterns such as cbits/*.c and other_cbits/**/*.c are accepted and expanded consistently for both fields, with coverage in the relevant tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- haskell
- Domain
- build-system
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100