add build configs

This commit is contained in:
Schrottkatze 2024-11-06 16:19:32 +01:00
parent 11c2c7f79f
commit 00a584c8f0
Signed by: schrottkatze
SSH key fingerprint: SHA256:hXb3t1vINBFCiDCmhRABHX5ocdbLiKyCdKI4HK2Rbbc
2 changed files with 17 additions and 0 deletions

1
.gitignore vendored
View file

@ -1,3 +1,4 @@
/target /target
.devenv .devenv
.direnv .direnv
/result

View file

@ -65,5 +65,21 @@
}) })
]; ];
}; };
packages.default = let
toolchain = inputs.fenix.packages.${system}.minimal.toolchain;
pkgs = nixpkgs.legacyPackages.${system};
in
(pkgs.makeRustPlatform {
cargo = toolchain;
rustc = toolchain;
})
.buildRustPackage {
pname = "chatthing";
version = "0.1.0";
src = ./.;
builtInputs = [pkgs.libpqxx pkgs.openssl];
nativeBuildInputs = [pkgs.pkg-config];
cargoLock.lockFile = ./Cargo.lock;
};
}); });
} }