mirror of
https://github.com/SChernykh/p2pool.git
synced 2024-12-22 11:29:23 +00:00
support build for all nixpkgs default systems
This commit is contained in:
parent
8c5cd198e0
commit
14a828618b
2 changed files with 44 additions and 18 deletions
18
flake.lock
18
flake.lock
|
@ -17,7 +17,23 @@
|
|||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs"
|
||||
"nixpkgs": "nixpkgs",
|
||||
"utils": "utils"
|
||||
}
|
||||
},
|
||||
"utils": {
|
||||
"locked": {
|
||||
"lastModified": 1629481132,
|
||||
"narHash": "sha256-JHgasjPR0/J1J3DRm4KxM4zTyAj4IOJY8vIl75v/kPI=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "997f7efcb746a9c140ce1f13c72263189225f482",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
44
flake.nix
44
flake.nix
|
@ -3,27 +3,37 @@
|
|||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs";
|
||||
utils.url = "github:numtide/flake-utils";
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs }: {
|
||||
packages.x86_64-linux.p2pool = with import nixpkgs { system = "x86_64-linux";}; stdenv.mkDerivation {
|
||||
pname = "p2pool";
|
||||
version = "0.0.1";
|
||||
src = self;
|
||||
outputs = { self, nixpkgs, utils }:
|
||||
utils.lib.eachDefaultSystem (system:
|
||||
let
|
||||
pkgs = import nixpkgs { inherit system; };
|
||||
in
|
||||
rec {
|
||||
packages = utils.lib.flattenTree {
|
||||
p2pool = pkgs.stdenv.mkDerivation {
|
||||
pname = "p2pool";
|
||||
version = "0.0.1";
|
||||
src = self;
|
||||
|
||||
nativeBuildInputs = [ cmake pkg-config ];
|
||||
nativeBuildInputs = builtins.attrValues {
|
||||
inherit (pkgs) cmake pkg-config;
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
libuv zeromq
|
||||
libsodium gss
|
||||
];
|
||||
buildInputs = builtins.attrValues {
|
||||
inherit (pkgs) libuv zeromq libsodium gss;
|
||||
};
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
cp -r ./p2pool $out/bin/
|
||||
'';
|
||||
};
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
cp -r ./p2pool $out/bin/
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
defaultPackage.x86_64-linux = self.packages.x86_64-linux.p2pool;
|
||||
};
|
||||
defaultPackage = packages.p2pool;
|
||||
}
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue