switch from import to callPackage in nix

This commit is contained in:
jacekpoz 2024-07-16 09:35:09 +02:00
parent 6506beba34
commit 311d6274b5
Signed by: poz
SSH key fingerprint: SHA256:JyLeVWE4bF3tDnFeUpUaJsPsNlJyBldDGV/dIKSLyN8
2 changed files with 13 additions and 6 deletions

View file

@ -14,7 +14,7 @@
system: let
pkgs = pkgsForEach.${system};
in rec {
osuplusplus = import ./nix/shell.nix {inherit pkgs;};
osuplusplus = pkgs.callPackage ./nix/shell.nix {};
default = osuplusplus;
}
);
@ -22,7 +22,7 @@
system: let
pkgs = pkgsForEach.${system};
in rec {
osuplusplus = import ./nix/default.nix {inherit (pkgs) lib stdenv sfml;};
osuplusplus = pkgs.callPackage ./nix/default.nix {};
default = osuplusplus;
}
);

View file

@ -1,15 +1,22 @@
{pkgs}:
pkgs.mkShell {
{
mkShell,
gcc,
gnumake,
clang-tools,
sfml,
...
}:
mkShell {
name = "osu++";
nativeBuildInputs = with pkgs; [
nativeBuildInputs = [
gcc
gnumake
# for clang-format
clang-tools
];
buildInputs = with pkgs; [
buildInputs = [
sfml
];
}