at 23.11-beta 36 lines 1.1 kB view raw
1{ lib, stdenv, fetchurl, fetchpatch, librsync }: 2 3stdenv.mkDerivation rec { 4 pname = "btar"; 5 version = "1.1.1"; 6 7 src = fetchurl { 8 url = "https://vicerveza.homeunix.net/~viric/soft/btar/btar-${version}.tar.gz"; 9 sha256 = "0miklk4bqblpyzh1bni4x6lqn88fa8fjn15x1k1n8bxkx60nlymd"; 10 }; 11 12 patches = [ 13 (fetchpatch { 14 url = "https://build.opensuse.org/public/source/openSUSE:Factory/btar/btar-librsync.patch?rev=2"; 15 sha256 = "1awqny9489vsfffav19s73xxg26m7zrhvsgf1wxb8c2izazwr785"; 16 }) 17 ]; 18 19 # Workaround build failure on -fno-common toolchains like upstream 20 # gcc-10. Otherwise build fails as: 21 # ld: listindex.o:/build/btar-1.1.1/loadindex.h:12: multiple definition of 22 # `ptr'; main.o:/build/btar-1.1.1/loadindex.h:12: first defined here 23 env.NIX_CFLAGS_COMPILE = "-fcommon"; 24 25 buildInputs = [ librsync ]; 26 27 makeFlags = [ "PREFIX=$(out)" ]; 28 29 meta = with lib; { 30 description = "Tar-compatible block-based archiver"; 31 license = lib.licenses.gpl3Plus; 32 homepage = "https://viric.name/cgi-bin/btar"; 33 platforms = platforms.all; 34 maintainers = with maintainers; [ viric ]; 35 }; 36}