nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at 20.09 59 lines 1.2 kB view raw
1{ stdenv 2, fetchurl 3, python 4, pkg-config 5, readline 6, libxslt 7, docbook-xsl-nons 8, docbook_xml_dtd_42 9, fixDarwinDylibNames 10, wafHook 11}: 12 13stdenv.mkDerivation rec { 14 pname = "talloc"; 15 version = "2.3.1"; 16 17 src = fetchurl { 18 url = "mirror://samba/talloc/${pname}-${version}.tar.gz"; 19 sha256 = "0xwzgzrqamfdlklwacp9d219pqkah0yfrhxb1j7bxlmgzp924j7g"; 20 }; 21 22 nativeBuildInputs = [ 23 pkg-config 24 fixDarwinDylibNames 25 python 26 wafHook 27 docbook-xsl-nons 28 docbook_xml_dtd_42 29 ]; 30 31 buildInputs = [ 32 readline 33 libxslt 34 ]; 35 36 wafPath = "buildtools/bin/waf"; 37 38 wafConfigureFlags = [ 39 "--enable-talloc-compat1" 40 "--bundled-libraries=NONE" 41 "--builtin-libraries=replace" 42 ]; 43 44 # this must not be exported before the ConfigurePhase otherwise waf whines 45 preBuild = stdenv.lib.optionalString stdenv.hostPlatform.isMusl '' 46 export NIX_CFLAGS_LINK="-no-pie -shared"; 47 ''; 48 49 postInstall = '' 50 ${stdenv.cc.targetPrefix}ar q $out/lib/libtalloc.a bin/default/talloc.c.[0-9]*.o 51 ''; 52 53 meta = with stdenv.lib; { 54 description = "Hierarchical pool based memory allocator with destructors"; 55 homepage = "https://tdb.samba.org/"; 56 license = licenses.gpl3; 57 platforms = platforms.all; 58 }; 59}