mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-10-02 13:00:23 +00:00
52 lines
1.2 KiB
Nix
52 lines
1.2 KiB
Nix
{
|
|
stdenv,
|
|
lib,
|
|
fetchFromGitHub,
|
|
rustPlatform,
|
|
openssl,
|
|
pkg-config,
|
|
alsa-lib,
|
|
nix-update-script,
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage (finalAttrs: {
|
|
pname = "chess-tui";
|
|
version = "2.7.1";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "thomas-mauran";
|
|
repo = "chess-tui";
|
|
tag = finalAttrs.version;
|
|
hash = "sha256-B6CpUha5e2W82HnWOxV2arHAiqJCyL5bwkhELYQPxMg=";
|
|
};
|
|
|
|
cargoHash = "sha256-Vik4FceQSYnziDpAqz7r7gpabUp2JL5u40iT0r8fnAw=";
|
|
|
|
checkFlags = [
|
|
# assertion failed: result.is_ok()
|
|
"--skip=tests::test_config_create"
|
|
];
|
|
|
|
buildInputs = [
|
|
openssl
|
|
]
|
|
# alsa-lib is required for the alsa-sys. alsa-lib does not compile on darwin
|
|
++ lib.optionals stdenv.hostPlatform.isLinux [ alsa-lib ]
|
|
# bindgenHook is required for coreaudio-sys on darwin
|
|
++ lib.optionals stdenv.hostPlatform.isDarwin [ rustPlatform.bindgenHook ];
|
|
|
|
nativeBuildInputs = [ pkg-config ];
|
|
|
|
env.PKG_CONFIG_PATH = "${openssl.dev}/lib/pkgconfig";
|
|
|
|
passthru.updateScript = nix-update-script { };
|
|
|
|
meta = {
|
|
description = "Chess TUI implementation in rust";
|
|
homepage = "https://github.com/thomas-mauran/chess-tui";
|
|
maintainers = with lib.maintainers; [ ByteSudoer ];
|
|
license = lib.licenses.mit;
|
|
mainProgram = "chess-tui";
|
|
};
|
|
})
|