Skip to content
This repository was archived by the owner on Dec 27, 2025. It is now read-only.

Commit d0ad0c0

Browse files
committed
feat: add native library support to Nix probitas package
The probitas package now includes native library dependencies (stdenv.cc.cc.lib, sqlite, duckdb) in runtimeInputs and sets LD_LIBRARY_PATH for FFI support. This ensures database clients work correctly when running `nix run` or `nix build` outputs, matching the capabilities already available in the dev shell.
1 parent c392f9f commit d0ad0c0

1 file changed

Lines changed: 15 additions & 1 deletion

File tree

flake.nix

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,24 @@
1212
overlay = final: prev: {
1313
probitas = prev.writeShellApplication {
1414
name = "probitas";
15-
runtimeInputs = [ prev.deno prev.coreutils ];
15+
runtimeInputs = [
16+
prev.deno
17+
prev.coreutils
18+
# Native library dependencies for database clients
19+
prev.stdenv.cc.cc.lib
20+
prev.sqlite
21+
prev.duckdb
22+
];
1623
text = ''
1724
export DENO_NO_UPDATE_CHECK=1
1825
26+
# Add native library paths for database clients (FFI support)
27+
export LD_LIBRARY_PATH="${prev.lib.makeLibraryPath [
28+
prev.stdenv.cc.cc.lib
29+
prev.sqlite
30+
prev.duckdb
31+
]}''${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}"
32+
1933
# Copy lock file to writable location to avoid /nix/store read-only errors
2034
TEMP_LOCK=$(mktemp)
2135
cp ${self}/deno.lock "$TEMP_LOCK"

0 commit comments

Comments
 (0)