Files
nixpkgs/pkgs/development/libraries/sqlite/sqlar.nix
T
Ihar Hrachyshka 567e8dfd8e treewide: clean up 'meta = with' pattern
This commit was created by a combination of scripts and tools:
- an ast-grep script to prefix things in meta with `lib.`,
- a modified nixf-diagnose / nixf combination to remove unused `with
lib;`, and
- regular nixfmt.

Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
2025-12-10 18:09:49 +01:00

47 lines
946 B
Nix

{
lib,
stdenv,
fetchurl,
fuse,
zlib,
withFuse ? true,
}:
stdenv.mkDerivation {
pname = "sqlar";
version = "2018-01-07";
src = fetchurl {
url = "https://www.sqlite.org/sqlar/tarball/4824e73896/sqlar-src-4824e73896.tar.gz";
sha256 = "09pikkbp93gqypn3da9zi0dzc47jyypkwc9vnmfzhmw7kpyv8nm9";
};
postPatch = ''
substituteInPlace Makefile \
--replace 'gcc' '${stdenv.cc.targetPrefix}cc'
'';
buildInputs = [ zlib ] ++ lib.optional withFuse fuse;
buildFlags = [
"CFLAGS=-Wno-error"
"sqlar"
]
++ lib.optional withFuse "sqlarfs";
installPhase = ''
install -D -t $out/bin sqlar
''
+ lib.optionalString withFuse ''
install -D -t $out/bin sqlarfs
'';
meta = {
homepage = "https://sqlite.org/sqlar";
description = "SQLite Archive utilities";
license = lib.licenses.bsd2;
platforms = lib.platforms.all;
maintainers = with lib.maintainers; [ dtzWill ];
};
}