at 23.11-beta 53 lines 1.2 kB view raw
1{ lib 2, stdenv 3, fetchFromGitHub 4, fetchpatch2 5, autoreconfHook 6, strace 7, which 8}: 9 10stdenv.mkDerivation rec { 11 pname = "libeatmydata"; 12 version = "131"; 13 14 src = fetchFromGitHub { 15 owner = "stewartsmith"; 16 repo = pname; 17 rev = "refs/tags/v${version}"; 18 sha256 = "sha256-0lrYDW51/KSr809whGwg9FYhzcLRfmoxipIgrK1zFCc="; 19 }; 20 21 patches = [ 22 # Fixes "error: redefinition of 'open'" on musl 23 (fetchpatch2 { 24 url = "https://raw.githubusercontent.com/void-linux/void-packages/861ac185a6b60134292ff93d40e40b5391d0aa8e/srcpkgs/libeatmydata/patches/musl.patch"; 25 hash = "sha256-MZfTgf2Qn94UpPlYNRM2zK99iKQorKQrlbU5/1WJhJM="; 26 }) 27 ]; 28 29 postPatch = '' 30 patchShebangs . 31 ''; 32 33 nativeBuildInputs = [ 34 autoreconfHook 35 ]; 36 37 nativeCheckInputs = [ 38 strace 39 which 40 ]; 41 42 doCheck = stdenv.buildPlatform.canExecute stdenv.hostPlatform; 43 44 enableParallelBuilding = true; 45 46 meta = with lib; { 47 description = "Small LD_PRELOAD library to disable fsync and friends"; 48 homepage = "https://www.flamingspork.com/projects/libeatmydata/"; 49 license = licenses.gpl3Plus; 50 mainProgram = "eatmydata"; 51 platforms = platforms.unix; 52 }; 53}