Skip to content

Commit 771bd90

Browse files
committed
nix: update to 25.05
1 parent 286afb4 commit 771bd90

File tree

5 files changed

+76
-138
lines changed

5 files changed

+76
-138
lines changed

derivation.nix

Lines changed: 0 additions & 16 deletions
This file was deleted.

flake.lock

Lines changed: 15 additions & 75 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

Lines changed: 34 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1,55 +1,42 @@
11
{
22
inputs = {
3-
nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.05";
4-
utils.url = "github:numtide/flake-utils";
5-
crane = {
6-
url = "github:ipetkov/crane";
7-
inputs.nixpkgs.follows = "nixpkgs";
8-
inputs.flake-utils.follows = "utils";
9-
};
10-
fenix = {
11-
url = "github:nix-community/fenix";
12-
inputs.nixpkgs.follows = "nixpkgs";
13-
};
3+
nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.05";
4+
flake-utils.url = "github:numtide/flake-utils";
145
};
156

16-
outputs = inputs@{ self, nixpkgs, utils, crane, fenix}:
17-
utils.lib.eachDefaultSystem
18-
(system:
19-
let
20-
pkgs = nixpkgs.legacyPackages.${system};
21-
craneLib = crane.lib.${system}.overrideToolchain fenix.packages.${system}.minimal.toolchain;
22-
package = pkgs.callPackage ./derivation.nix { craneLib = craneLib; };
23-
in
24-
rec {
25-
checks = packages;
26-
packages = {
27-
chemo = package;
28-
default = package;
29-
docs = (pkgs.nixosOptionsDoc {
30-
options = (nixpkgs.lib.nixosSystem {
31-
inherit system;
32-
modules = [ self.nixosModules.default ];
33-
}).options.TLMS;
34-
}).optionsCommonMark;
35-
};
36-
devShells.default = pkgs.mkShell {
37-
nativeBuildInputs = (with packages.chemo; nativeBuildInputs ++ buildInputs);
38-
};
7+
outputs = { self, nixpkgs, flake-utils }:
8+
flake-utils.lib.eachDefaultSystem
9+
(system:
10+
let
11+
pkgs = (import nixpkgs) {
12+
inherit system;
13+
};
14+
chemo = pkgs.callPackage ./package.nix { };
15+
in
16+
{
17+
packages = {
18+
inherit chemo;
19+
default = chemo;
20+
docs = (pkgs.nixosOptionsDoc {
21+
options = (nixpkgs.lib.nixosSystem {
22+
inherit system;
23+
modules = [ self.nixosModules.default ];
24+
}).options.TLMS;
25+
}).optionsCommonMark;
26+
};
3927

40-
apps = {
41-
chemo = utils.lib.mkApp { drv = packages.chemo; };
42-
default = apps.chemo;
43-
};
44-
}) // {
45-
nixosModules = rec {
46-
default = chemo;
47-
chemo = import ./nixos-module;
48-
};
28+
devShells.default = pkgs.mkShell {
29+
nativeBuildInputs = with chemo; nativeBuildInputs ++ buildInputs;
30+
};
31+
}
32+
) // {
33+
overlays.default = _: prev: {
34+
inherit (self.packages."${prev.system}") chemo;
35+
};
4936

50-
overlays.default = final: prev: {
51-
inherit (self.packages.${prev.system})
52-
chemo;
37+
nixosModules = rec {
38+
chemo = ./module.nix;
39+
default = chemo;
40+
};
5341
};
54-
};
5542
}
File renamed without changes.

package.nix

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
{ lib, rustPlatform, pkg-config, cmake, openssl, libpq, ... }:
2+
3+
let
4+
manifest = (lib.importTOML ./Cargo.toml).package;
5+
in
6+
rustPlatform.buildRustPackage (finalAttrs: {
7+
pname = manifest.name;
8+
inherit (manifest) version;
9+
10+
src = lib.cleanSource ./.;
11+
12+
cargoHash = "sha256-JCeuelqP5vCNd0A7dRnW+M3+FKUM2sUFFCyArm8VwN4=";
13+
14+
cargoBuildFlags = "-p ${finalAttrs.pname}";
15+
cargoTestFlags = "-p ${finalAttrs.pname}";
16+
17+
nativeBuildInputs = [ pkg-config cmake ];
18+
19+
buildInputs = [ openssl libpq ];
20+
21+
meta = {
22+
mainProgram = "chemo";
23+
description = "Merging high end quality TM Data Streams since 2023";
24+
homepage = "https://github.com/dump-dvb/chemo";
25+
};
26+
})
27+

0 commit comments

Comments
 (0)