nix: add package for database with WAL enabled
This commit is contained in:
@@ -129,6 +129,12 @@
|
||||
inherit src;
|
||||
};
|
||||
|
||||
database-wal = pkgs.callPackage ./nix/database.nix {
|
||||
inherit (self.packages.${system}) database-tool jmdict radkfile kanjidic2;
|
||||
inherit src;
|
||||
wal = true;
|
||||
};
|
||||
|
||||
docs = pkgs.callPackage ./nix/docs.nix {
|
||||
inherit (self.packages.${system}) database;
|
||||
};
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
radkfile,
|
||||
kanjidic2,
|
||||
sqlite,
|
||||
wal ? false,
|
||||
}:
|
||||
stdenvNoCC.mkDerivation {
|
||||
name = "jadb";
|
||||
@@ -29,7 +30,9 @@ stdenvNoCC.mkDerivation {
|
||||
sqlite3 jadb.sqlite < "$migration"
|
||||
done
|
||||
|
||||
"${lib.getExe database-tool}" create-db --libsqlite "${sqlite.out}/lib/libsqlite3.so"
|
||||
"${lib.getExe database-tool}" create-db \
|
||||
${lib.optionalString wal "--wal"} \
|
||||
--libsqlite "${sqlite.out}/lib/libsqlite3.so"
|
||||
|
||||
runHook postBuild
|
||||
'';
|
||||
|
||||
Reference in New Issue
Block a user