2024-09-26 14:22:36 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
rustPlatform,
|
|
|
|
fetchFromGitHub,
|
|
|
|
pkg-config,
|
|
|
|
openssl,
|
|
|
|
sqlite,
|
|
|
|
zlib,
|
|
|
|
stdenv,
|
|
|
|
clang,
|
|
|
|
darwin,
|
2023-07-01 23:59:59 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "mchprs";
|
2024-09-26 14:22:36 +00:00
|
|
|
version = "0.5.1";
|
2023-07-01 23:59:59 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "MCHPR";
|
|
|
|
repo = "MCHPRS";
|
2024-09-26 14:22:36 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
hash = "sha256-Jm9ZsqCKOIxZsXQbCluYu7MgOD7hXYljcv/URaNVUW0=";
|
2023-07-01 23:59:59 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
cargoLock = {
|
|
|
|
lockFile = ./Cargo.lock;
|
|
|
|
outputHashes = {
|
2024-09-26 14:22:36 +00:00
|
|
|
"hematite-nbt-0.5.2" = "sha256-ohhsMlRLFNesccxhqn0GAiVswcdMldD3gv0AXcviHU8=";
|
2023-07-01 23:59:59 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
pkg-config
|
2024-09-26 14:22:36 +00:00
|
|
|
clang
|
2023-07-01 23:59:59 +00:00
|
|
|
rustPlatform.bindgenHook
|
|
|
|
];
|
|
|
|
|
2024-09-26 14:22:36 +00:00
|
|
|
buildInputs =
|
|
|
|
[
|
|
|
|
openssl
|
|
|
|
sqlite
|
|
|
|
zlib
|
|
|
|
]
|
|
|
|
++ lib.optionals stdenv.hostPlatform.isDarwin [
|
|
|
|
darwin.apple_sdk.frameworks.CoreFoundation
|
|
|
|
darwin.apple_sdk.frameworks.Security
|
|
|
|
darwin.apple_sdk.frameworks.SystemConfiguration
|
|
|
|
];
|
2023-07-01 23:59:59 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
mainProgram = "mchprs";
|
2024-06-07 07:46:46 +00:00
|
|
|
description = "Multithreaded Minecraft server built for redstone";
|
2023-07-01 23:59:59 +00:00
|
|
|
homepage = "https://github.com/MCHPR/MCHPRS";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ gdd ];
|
|
|
|
};
|
|
|
|
}
|