@@ -11,7 +11,13 @@ let #TODO: Upstream
1111 # automatically if the resulting derivation is installed, e.g. by
1212 # `nix-env -i`.
1313
14− justStaticExecutables' = drvOrig: overrideCabal (justStaticExecutables drvOrig) (drv: { configureFlags = drvOrig.configureFlags or [];});
14+ # TODO: Remove this after updating nixpkgs: https://github.com/NixOS/nixpkgs/issues/37750
15+ justStaticExecutables' = drv: let
16+ drv' = justStaticExecutables drv;
17+ in if pkgs.stdenv.isDarwin
18+ then removeConfigureFlag drv' "--ghc-option=-optl=-dead_strip"
19+ else drv';
20+
1521
1622 addOptparseApplicativeCompletionScripts = exeName: pkg: overrideCabal pkg (drv: {
1723 postInstall = (drv.postInstall or "") + ''