2020-10-20 17:27:49 +00:00
|
|
|
{ clang
|
2020-04-24 23:36:52 +00:00
|
|
|
, fetchFromGitHub
|
2020-10-20 17:27:49 +00:00
|
|
|
, lib
|
|
|
|
, llvmPackages
|
|
|
|
, protobuf
|
2020-04-24 23:36:52 +00:00
|
|
|
, rustPlatform
|
|
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "polkadot";
|
2020-11-06 00:33:48 +00:00
|
|
|
version = "0.8.26";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "paritytech";
|
2020-10-20 17:27:49 +00:00
|
|
|
repo = "polkadot";
|
|
|
|
rev = "v${version}";
|
2020-11-06 00:33:48 +00:00
|
|
|
sha256 = "1bvma6k3gsjqh8w76k4kf52sjg8wxn1b7a409kmnmmvmd9j6z5ia";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2020-11-06 00:33:48 +00:00
|
|
|
cargoSha256 = "0pacmmvvjgzmaxgg47qbfhqwl02jxj3i6vnmkjbj9npzqfmqf72d";
|
2020-10-20 17:27:49 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [ clang ];
|
|
|
|
|
|
|
|
LIBCLANG_PATH = "${llvmPackages.libclang}/lib";
|
|
|
|
PROTOC = "${protobuf}/bin/protoc";
|
|
|
|
|
|
|
|
# NOTE: We don't build the WASM runtimes since this would require a more
|
|
|
|
# complicated rust environment setup. The resulting binary is still useful for
|
|
|
|
# live networks since those just use the WASM blob from the network chainspec.
|
|
|
|
BUILD_DUMMY_WASM_BINARY = 1;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-10-20 17:27:49 +00:00
|
|
|
# We can't run the test suite since we didn't compile the WASM runtimes.
|
|
|
|
doCheck = false;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-10-20 17:27:49 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Polkadot Node Implementation";
|
|
|
|
homepage = "https://polkadot.network";
|
|
|
|
license = licenses.gpl3;
|
2020-10-19 09:53:12 +00:00
|
|
|
maintainers = with maintainers; [ akru andresilva RaghavSood ];
|
2020-04-24 23:36:52 +00:00
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|