mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-16 02:33:25 +00:00
0b899d4084
Diff: https://github.com/woelper/oculante/compare/0.6.63...0.6.64 Changelog: https://github.com/woelper/oculante/blob/0.6.64/CHANGELOG.md
76 lines
1.4 KiB
Nix
76 lines
1.4 KiB
Nix
{ lib
|
|
, rustPlatform
|
|
, fetchFromGitHub
|
|
, cmake
|
|
, pkg-config
|
|
, openssl
|
|
, fontconfig
|
|
, nasm
|
|
, libX11
|
|
, libXcursor
|
|
, libXrandr
|
|
, libXi
|
|
, libGL
|
|
, libxkbcommon
|
|
, wayland
|
|
, stdenv
|
|
, gtk3
|
|
, darwin
|
|
, perl
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
pname = "oculante";
|
|
version = "0.6.64";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "woelper";
|
|
repo = pname;
|
|
rev = version;
|
|
sha256 = "sha256-7Xe01Z4ea+EHaMHwb81cjJkCW/HDobmFZ29YxKcaYJg=";
|
|
};
|
|
|
|
cargoLock = {
|
|
lockFile = ./Cargo.lock;
|
|
};
|
|
|
|
nativeBuildInputs = [
|
|
cmake
|
|
pkg-config
|
|
nasm
|
|
perl
|
|
];
|
|
|
|
checkFlagsArray = [ "--skip=tests::net" ]; # requires network access
|
|
|
|
buildInputs = [
|
|
openssl
|
|
fontconfig
|
|
] ++ lib.optionals stdenv.isLinux [
|
|
libGL
|
|
libX11
|
|
libXcursor
|
|
libXi
|
|
libXrandr
|
|
gtk3
|
|
|
|
libxkbcommon
|
|
wayland
|
|
] ++ lib.optionals stdenv.isDarwin [
|
|
darwin.libobjc
|
|
];
|
|
|
|
postFixup = lib.optionalString stdenv.isLinux ''
|
|
patchelf $out/bin/oculante --add-rpath ${lib.makeLibraryPath [ libxkbcommon libX11 ]}
|
|
'';
|
|
|
|
meta = with lib; {
|
|
broken = stdenv.isDarwin;
|
|
description = "A minimalistic crossplatform image viewer written in Rust";
|
|
homepage = "https://github.com/woelper/oculante";
|
|
changelog = "https://github.com/woelper/oculante/blob/${version}/CHANGELOG.md";
|
|
license = licenses.mit;
|
|
maintainers = with maintainers; [ dit7ya figsoda ];
|
|
};
|
|
}
|