mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-10-03 13:30:36 +00:00
84 lines
2.0 KiB
Nix
84 lines
2.0 KiB
Nix
{
|
|
lib,
|
|
stdenv,
|
|
swt,
|
|
fetchurl,
|
|
jre,
|
|
wrapGAppsHook3,
|
|
nix-update-script,
|
|
}:
|
|
|
|
stdenv.mkDerivation (finalAttrs: {
|
|
pname = "biglybt";
|
|
version = "4.1.0.0";
|
|
|
|
src = fetchurl {
|
|
url = "https://github.com/BiglySoftware/BiglyBT/releases/download/v${finalAttrs.version}/GitHub_BiglyBT_unix.tar.gz";
|
|
hash = "sha256-P9CscKANZUZd49tPelT8fZVVaf5P5CKnq5eAbE7H6eU=";
|
|
};
|
|
|
|
nativeBuildInputs = [
|
|
swt
|
|
wrapGAppsHook3
|
|
];
|
|
|
|
buildInputs = [
|
|
swt
|
|
];
|
|
|
|
runtimeDeps = [
|
|
swt
|
|
];
|
|
|
|
configurePhase = ''
|
|
runHook preConfigure
|
|
|
|
sed -e 's/AUTOUPDATE_SCRIPT=1/AUTOUPDATE_SCRIPT=0/g' \
|
|
-i biglybt || die
|
|
|
|
runHook postConfigure
|
|
'';
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
install -d $out/{share/{biglybt,applications,icons/hicolor/scalable/apps},bin}
|
|
|
|
cp -r ./* $out/share/biglybt/
|
|
|
|
ln -s ${swt}/lib/* $out/share/biglybt/
|
|
rm -rf $out/share/biglybt/swt/*.jar $out/share/biglybt/swt/J17/*.jar
|
|
ln -s ${swt}/jars/swt.jar $out/share/biglybt/swt/swt-$(uname -m).jar
|
|
ln -s ${swt}/jars/swt.jar $out/share/biglybt/swt/J17/swt-$(uname -m).jar
|
|
|
|
ln -s $out/share/biglybt/biglybt.desktop $out/share/applications/
|
|
|
|
ln -s $out/share/biglybt/biglybt.svg $out/share/icons/hicolor/scalable/apps/
|
|
|
|
wrapProgram $out/share/biglybt/biglybt \
|
|
--prefix PATH : ${lib.makeBinPath [ jre ]}
|
|
|
|
ln -s $out/share/biglybt/biglybt $out/bin/
|
|
runHook postInstall
|
|
'';
|
|
|
|
passthru.updateScript = nix-update-script {
|
|
extraArgs = [
|
|
"--version-regex"
|
|
"^(v[0-9.]+)$"
|
|
];
|
|
};
|
|
|
|
meta = {
|
|
changelog = "https://github.com/BiglySoftware/BiglyBT/releases/tag/v${finalAttrs.version}";
|
|
description = "BitTorrent client based on the Azureus that supports I2P darknet for privacy";
|
|
downloadPage = "https://github.com/BiglySoftware/BiglyBT";
|
|
homepage = "https://www.biglybt.com/";
|
|
license = lib.licenses.gpl3Plus;
|
|
platforms = lib.platforms.unix;
|
|
sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ];
|
|
mainProgram = "biglybt";
|
|
maintainers = with lib.maintainers; [ raspher ];
|
|
};
|
|
})
|