haskell / haskell/cabal

constraints for dynamic / static executables

Open
#1,423 1 comment 0 reactions 0 assignees View on GitHub
type: enhancement
Dominant language
Haskell
Stars
1.7k
Forks
750
Avg merge
4d 3h
Merged PRs (30d)
28

Description

Currently the choice for building statically or dynamically linked executables is made by the users. Unfortunately not in all configurations static and dynamic linking are interchangeable: When GHC is built with dynamic libraries, a program using the GHC API to interpret or typecheck Haskell needs to be linked dynamically. This affects at least:
- `GHCJS`
- `ghc-mod`
- snap and yesod

So would be nice to be able to specify constraints on how an executable is linked, and to figure whether GHC uses dynamic libs with a flag.

Contributor guide

Open the contributing guide

Research direction

Start by tracing how Cabal currently selects static versus dynamic executable linking and how it detects whether GHC uses dynamic libraries. Review the GHC API consumers named in the issue—GHCJS, ghc-mod, snap, and yesod—to understand the required constraints. Done means executable-linking constraints can be specified and incompatible configurations are identifiable.

Written by the indexing model from the issue text.

Assessment

Tech stack
haskell
Domain
build-system
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.