From eaec29b94f9f23618985bf1670539048fc11e7da Mon Sep 17 00:00:00 2001 From: Nicolas Hiillos Date: Wed, 16 Aug 2023 09:04:57 +0300 Subject: [PATCH] Improve --- flake.lock | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ flake.nix | 15 ++++++++------ 2 files changed, 69 insertions(+), 6 deletions(-) create mode 100644 flake.lock diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..8c0c30b --- /dev/null +++ b/flake.lock @@ -0,0 +1,60 @@ +{ + "nodes": { + "flake-utils": { + "inputs": { + "systems": "systems" + }, + "locked": { + "lastModified": 1689068808, + "narHash": "sha256-6ixXo3wt24N/melDWjq70UuHQLxGV8jZvooRanIHXw0=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "919d646de7be200f3bf08cb76ae1f09402b6f9b4", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1692025715, + "narHash": "sha256-tsRiiopGT7HA8d/cuk5xYBRXgdnnvD+JhUGUe3x7vmY=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "09a137528c3aea3780720d19f99cd706f52c3823", + "type": "github" + }, + "original": { + "id": "nixpkgs", + "ref": "nixos-23.05", + "type": "indirect" + } + }, + "root": { + "inputs": { + "flake-utils": "flake-utils", + "nixpkgs": "nixpkgs" + } + }, + "systems": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix index c3ca98e..8ca7596 100644 --- a/flake.nix +++ b/flake.nix @@ -4,10 +4,13 @@ flake-utils.url = "github:numtide/flake-utils"; }; outputs = { self, nixpkgs, flake-utils, ... }: - let - kernel = nixpkgs.linuxPackages_latest; - in - flake-utils.lib.eachDefaultSystem (system: { - packages.${system}.ethercat = (import ./ethercat.nix) { inherit kernel; }; - }); + flake-utils.lib.eachDefaultSystem (system: + let + pkgs = nixpkgs.legacyPackages.${system}; + kernel = pkgs.linuxPackages_latest; + in + { + packages.${system}.ethercat = (import ./ethercat.nix) { inherit kernel; }; + } + ); }