Skip to content

Commit fad0c87

Browse files
authored
hack: fixed it sometimes not running on NixOS (#594)
1 parent 5432ac6 commit fad0c87

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

flake.nix

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131

3232
common = {
3333
packages = with pkgs; [
34+
nix # HACK: to fix the side effect of the hack below, installing two instances of nix
3435
gnumake
3536
bun
3637
nodejs-slim
@@ -47,6 +48,12 @@
4748
PRISMA_QUERY_ENGINE_LIBRARY = "${prisma-engines}/lib/libquery_engine.node";
4849
PRISMA_INTROSPECTION_ENGINE_BINARY = "${prisma-engines}/bin/introspection-engine";
4950
PRISMA_FMT_BINARY = "${prisma-engines}/bin/prisma-fmt";
51+
52+
# HACK: sharp can't find libstdc++.so.6 on bun without this
53+
# - hack because: setting this may break other packages
54+
# - info: it can find libstdc++.so.6 on Node.js
55+
# - info: NobbZ says it's because "We can not set an rpath for a scripting language"
56+
LD_LIBRARY_PATH = "${pkgs.stdenv.cc.cc.lib}/lib";
5057
};
5158
};
5259
in {

0 commit comments

Comments
 (0)