Skip to content

Commit

Permalink
OpenBSD --strip-unneeded strips too much
Browse files Browse the repository at this point in the history
  • Loading branch information
geekosaur committed Dec 6, 2024
1 parent 8cc49d9 commit f755b9e
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Cabal/src/Distribution/Simple/Program/Strip.hs
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ stripLib verbosity (Platform arch os) progdb path = do
IOS -> return ()
AIX -> return ()
Solaris -> return ()
OpenBSD -> -- '--strip-unneeded' sometimes strips too much on OpenBSD.
return ()
Windows ->
-- Stripping triggers a bug in 'strip.exe' for
-- libraries with lots identically named modules. See
Expand Down
11 changes: 11 additions & 0 deletions changelog.d/pr-10616
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
synopsis: "OpenBSD `--strip-unneeded` sometimes strips too much"
packages: [Cabal]
prs: 10616
---

OpenBSD's `--strip-unneeded` thinks some symbols are unneeded that are in fact
needed when C bits are involved, so suppress its use.

Taken from the OpenBSD ports repo (https://cvsweb.openbsd.org/cgi-bin/cvsweb/~checkout~/ports/lang/ghc/patches/patch-libraries_Cabal_Cabal_Distribution_Simple_Program_Strip_hs);
brought to our attention by maerwald.

0 comments on commit f755b9e

Please sign in to comment.