Skip to content

Commit

Permalink
Dynamically link compiler executable.
Browse files Browse the repository at this point in the history
DDlog used to rely on static linking to reduce runtime dependencies.
Unfortunately, this no longer works well on recent Ubuntu and Fedora
releases (see #1051).  The problem appears to be in the `unix` Haskell
package, which may still load dynamic libraries (in particular glibc)
using `dlopen` when using static linking.  As far as I can tell it uses
older versions of Linux static libraries, which require some deprecated
libc symbols (specifically `__xmnod`).  This will probably get fixed
eventually, but overall static linking probably was not a good idea, so
we switch to the more standard dynamic linking method.
  • Loading branch information
ryzhyk committed Jul 23, 2022
1 parent 588d489 commit 7059a5a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions package.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ dependencies:
library:
source-dirs: src
ghc-options:
- -optl-static
# - -optl-static
- -optl-pthread
- -Wall
- -Werror
Expand All @@ -66,7 +66,7 @@ executables:
- -threaded
- -rtsopts
- -with-rtsopts=-N
- -optl-static
# - -optl-static
- -optl-pthread
- -Wall
- -Werror
Expand All @@ -91,7 +91,7 @@ executables:
- -threaded
- -rtsopts
- -with-rtsopts=-N
- -optl-static
# - -optl-static
- -Wall
- -Werror
else:
Expand Down

0 comments on commit 7059a5a

Please sign in to comment.