Files
nixpkgs/pkgs/by-name/fe/feather/package.nix
2026-08-06 14:03:09 +02:00

100 lines
2.1 KiB
Nix

{
bc-ur,
boost186,
cmake,
fetchFromGitHub,
fetchpatch2,
hidapi,
lib,
libsodium,
libusb1,
openssl,
pkg-config,
protobuf,
python3,
qrencode,
qt6,
readline,
stdenv,
testers,
tor,
unbound,
zxing-cpp,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "feather";
version = "2.8.1";
src = fetchFromGitHub {
owner = "feather-wallet";
repo = "feather";
tag = finalAttrs.version;
hash = "sha256-DZBRZBcoba32Z/bFThn/9siC8VESg5gdfoFO4Nw8JqM=";
fetchSubmodules = true;
};
patches = [
(fetchpatch2 {
name = "0001-zxing-3-compat.patch";
url = "https://github.com/feather-wallet/feather/commit/9b17ffd1f783689c835da3ce22996a25d8221806.patch?full_index=1";
hash = "sha256-o4Tq6Dg5xrkF1eoGw0uuN9GiW4+FCnswx6//PYYA34w=";
})
];
nativeBuildInputs = [
cmake
pkg-config
python3
qt6.wrapQtAppsHook
];
buildInputs = [
bc-ur
boost186
hidapi
libsodium
libusb1
openssl
protobuf
qrencode
unbound
zxing-cpp
]
++ (with qt6; [
qtbase
qtmultimedia
qtsvg
qttools
qtwayland
qtwebsockets
]);
cmakeFlags = [
"-DProtobuf_INCLUDE_DIR=${lib.getDev protobuf}/include"
"-DProtobuf_PROTOC_EXECUTABLE=${lib.getExe protobuf}"
"-DReadline_INCLUDE_DIR=${lib.getDev readline}/include/readline"
"-DReadline_LIBRARY=${lib.getLib readline}/lib/libreadline.so"
"-DReadline_ROOT_DIR=${lib.getDev readline}"
"-DTOR_DIR=${lib.makeBinPath [ tor ]}"
"-DTOR_VERSION=${tor.version}"
];
passthru.tests.version = testers.testVersion {
package = finalAttrs.finalPackage;
command = ''
QT_QPA_PLATFORM=minimal ${finalAttrs.finalPackage.meta.mainProgram} --version
'';
};
meta = {
description = "Free Monero desktop wallet";
homepage = "https://featherwallet.org/";
changelog = "https://featherwallet.org/changelog/#${finalAttrs.version}%20changelog";
platforms = lib.platforms.linux;
license = lib.licenses.bsd3;
mainProgram = "feather";
maintainers = with lib.maintainers; [ surfaceflinger ];
};
})