aboutsummaryrefslogtreecommitdiff
path: root/flake.nix
diff options
context:
space:
mode:
authorsinanmohd <sinan@sinanmohd.com>2024-09-03 08:32:27 +0530
committersinanmohd <sinan@sinanmohd.com>2024-09-03 08:32:27 +0530
commita1eb8e06c42bf15e916a83180fc0d62c5a86fd37 (patch)
tree9660e72cd017053eb02a98f4f0631b0dd103123c /flake.nix
parent1001d8bb31d7a069b6b026ae2331034e3f4f0697 (diff)
flake/inputs: add nix
Diffstat (limited to 'flake.nix')
-rw-r--r--flake.nix26
1 files changed, 21 insertions, 5 deletions
diff --git a/flake.nix b/flake.nix
index 1cf206c..409947c 100644
--- a/flake.nix
+++ b/flake.nix
@@ -1,10 +1,21 @@
{
description = "A Nix build Scheduler";
- inputs.nixpkgs.url = "github:NixOs/nixpkgs/nixos-unstable";
+ inputs = {
+ nixpkgs.url = "github:NixOs/nixpkgs/nixos-unstable";
+
+ nix = {
+ url = "github:NixOS/nix";
+ inputs.nixpkgs.follows = "nixpkgs";
+ };
+ };
outputs =
- { self, nixpkgs }:
+ {
+ self,
+ nixpkgs,
+ nix,
+ }:
let
lib = nixpkgs.lib;
@@ -49,19 +60,24 @@
packages = forAllSystems (
{ system, pkgs }:
+ let
+ nixPkg = nix.packages.${system}.nix;
+ in
{
default = self.packages.${system}.evanix;
- evanix = pkgs.callPackage ./package.nix { };
+ evanix = pkgs.callPackage ./package.nix { nix = nixPkg; };
evanix-asan = self.packages.${system}.evanix.overrideAttrs (
_: previousAttrs: {
mesonFlags = previousAttrs.mesonFlags ++ [ (lib.mesonOption "b_sanitize" "address") ];
}
);
- evanix-py = pkgs.python3Packages.callPackage ./python-package.nix { };
+ evanix-py = pkgs.python3Packages.callPackage ./python-package.nix { nix = nixPkg; };
pythonWithEvanix =
let
- wrapper = pkgs.python3.withPackages (ps: [ (ps.callPackage ./python-package.nix { }) ]);
+ wrapper = pkgs.python3.withPackages (ps: [
+ (ps.callPackage ./python-package.nix { nix = nixPkg; })
+ ]);
in
wrapper.overrideAttrs (oldAttrs: {
makeWrapperArgs = oldAttrs.makeWrapperArgs or [ ] ++ [