transgui: patch to circumvent v3 rpc issue

+30 -25
+30 -25
pkgs/applications/networking/p2p/transgui/default.nix
··· 1 - { lib, stdenv, fetchFromGitHub, pkg-config, makeDesktopItem, unzip, fpc, lazarus, 2 - libX11, glib, gtk2, gdk-pixbuf, pango, atk, cairo, openssl }: 3 4 stdenv.mkDerivation rec { 5 pname = "transgui"; 6 - version = "5.18.0"; 7 8 src = fetchFromGitHub { 9 owner = "transmission-remote-gui"; 10 repo = "transgui"; 11 - rev = "v${version}"; 12 - sha256 = "1dyx778756zhvz5sxgdvy49p2c0x44w4nmcfd90wqrmgfknncnf5"; 13 }; 14 15 nativeBuildInputs = [ pkg-config unzip ]; 16 buildInputs = [ 17 - fpc lazarus stdenv.cc 18 - libX11 glib gtk2 gdk-pixbuf pango atk cairo openssl 19 ]; 20 21 - NIX_LDFLAGS = " 22 - -L${stdenv.cc.cc.lib}/lib 23 - -lX11 -lglib-2.0 -lgtk-x11-2.0 -lgdk-x11-2.0 24 - -lgdk_pixbuf-2.0 -lpango-1.0 -latk-1.0 -lcairo -lc -lcrypto 25 - "; 26 27 - prePatch = '' 28 substituteInPlace restranslator.pas --replace /usr/ $out/ 29 ''; 30 ··· 33 lazbuild -B transgui.lpr --lazarusdir=${lazarus}/share/lazarus 34 ''; 35 36 - makeFlags = [ 37 - "FPC=fpc" 38 - "PP=fpc" 39 - "INSTALL_PREFIX=$(out)" 40 - ]; 41 42 LCL_PLATFORM = "gtk2"; 43 44 - desktopItem = makeDesktopItem rec { 45 - name = "transgui"; 46 - exec = name + " %U"; 47 - icon = name; 48 type = "Application"; 49 comment = meta.description; 50 desktopName = "Transmission Remote GUI"; 51 genericName = "BitTorrent Client"; 52 - categories = [ "Application" "Network" "FileTransfer" "P2P" "GTK" ]; 53 startupNotify = true; 54 mimeTypes = [ "application/x-bittorrent" "x-scheme-handler/magnet" ]; 55 }; ··· 64 ''; 65 66 meta = { 67 - description = "A cross platform front-end for the Transmission Bit-Torrent client"; 68 homepage = "https://sourceforge.net/p/transgui"; 69 license = lib.licenses.gpl2Plus; 70 maintainers = with lib.maintainers; [ ramkromberg ]; 71 - platforms = lib.platforms.linux; 72 }; 73 }
··· 1 + { lib, stdenv, fetchFromGitHub, pkg-config, makeDesktopItem, fetchpatch, unzip 2 + , fpc, lazarus, libX11, glib, gtk2, gdk-pixbuf, pango, atk, cairo, openssl }: 3 4 stdenv.mkDerivation rec { 5 pname = "transgui"; 6 + version = "unstable-2022-02-02"; 7 8 src = fetchFromGitHub { 9 owner = "transmission-remote-gui"; 10 repo = "transgui"; 11 + rev = "0e2c2a07c1b21b1704c0a4945a111a8aa1050a1a"; 12 + sha256 = "1x9wzii3q9zanpik4xc99jqsfrqch8vjmlx12jrvczxcfy51b1ba"; 13 }; 14 15 + patches = [ 16 + # TDDO: remove when transgui updates for transmission-daemon v3 rpc protocol 17 + (fetchpatch { 18 + url = "https://github.com/transmission-remote-gui/transgui/commit/9275c3fb877dd753a1940d1b900630cdc09a0cc2.patch"; 19 + sha256 = "0w2x7gcxp5kqczdz7ckfqhdz9hhkm62k8gcws54d6km7x9vc1023"; 20 + }) 21 + ]; 22 + 23 nativeBuildInputs = [ pkg-config unzip ]; 24 buildInputs = [ 25 + fpc lazarus stdenv.cc libX11 glib gtk2 gdk-pixbuf 26 + pango atk cairo openssl 27 ]; 28 29 + NIX_LDFLAGS = '' 30 + -L${stdenv.cc.cc.lib}/lib -lX11 -lglib-2.0 -lgtk-x11-2.0 31 + -lgdk-x11-2.0 -lgdk_pixbuf-2.0 -lpango-1.0 -latk-1.0 -lcairo 32 + -lc -lcrypto 33 + ''; 34 35 + postPatch = '' 36 substituteInPlace restranslator.pas --replace /usr/ $out/ 37 ''; 38 ··· 41 lazbuild -B transgui.lpr --lazarusdir=${lazarus}/share/lazarus 42 ''; 43 44 + makeFlags = [ "FPC=fpc" "PP=fpc" "INSTALL_PREFIX=$(out)" ]; 45 46 LCL_PLATFORM = "gtk2"; 47 48 + desktopItem = makeDesktopItem { 49 + name = pname; 50 + exec = "${pname} %U"; 51 + icon = pname; 52 type = "Application"; 53 comment = meta.description; 54 desktopName = "Transmission Remote GUI"; 55 genericName = "BitTorrent Client"; 56 + categories = [ "Network" "FileTransfer" "P2P" "GTK" ]; 57 startupNotify = true; 58 mimeTypes = [ "application/x-bittorrent" "x-scheme-handler/magnet" ]; 59 }; ··· 68 ''; 69 70 meta = { 71 + description = "A cross platform front-end for the Transmission BitTorrent client"; 72 homepage = "https://sourceforge.net/p/transgui"; 73 license = lib.licenses.gpl2Plus; 74 maintainers = with lib.maintainers; [ ramkromberg ]; 75 + mainProgram = "transgui"; 76 + platforms = [ "x86_64-linux" "x86_64-darwin" ]; 77 }; 78 }