at 18.03-beta 68 lines 1.9 kB view raw
1{ stdenv, fetchFromGitHub, autoreconfHook, docbook_xsl, gtk-doc, icu 2, libxslt, pkgconfig, python2 }: 3 4let 5 6 listVersion = "2017-02-03"; 7 listSources = fetchFromGitHub { 8 sha256 = "0fhc86pjv50hxj3xf9r4mh0zzvdzqp5lac20caaxq1hlvdzavaa3"; 9 rev = "37e30d13801eaad3383b122c11d8091c7ac21040"; 10 repo = "list"; 11 owner = "publicsuffix"; 12 }; 13 14 libVersion = "0.17.0"; 15 16in stdenv.mkDerivation rec { 17 name = "libpsl-${version}"; 18 version = "${libVersion}-list-${listVersion}"; 19 20 src = fetchFromGitHub { 21 sha256 = "08dbl6ihnlf0kj4c9pdpjv9mmw7p676pzh1q184wl32csra5pzdd"; 22 rev = "libpsl-${libVersion}"; 23 repo = "libpsl"; 24 owner = "rockdaboot"; 25 }; 26 27 buildInputs = [ icu libxslt ]; 28 nativeBuildInputs = [ autoreconfHook docbook_xsl gtk-doc pkgconfig python2 ]; 29 30 postPatch = '' 31 substituteInPlace src/psl.c --replace bits/stat.h sys/stat.h 32 patchShebangs src/psl-make-dafsa 33 ''; 34 35 preAutoreconf = '' 36 mkdir m4 37 gtkdocize 38 ''; 39 40 preConfigure = '' 41 # The libpsl check phase requires the list's test scripts (tests/) as well 42 cp -Rv "${listSources}"/* list 43 ''; 44 configureFlags = [ 45 "--disable-builtin" 46 "--disable-static" 47 "--enable-gtk-doc" 48 "--enable-man" 49 ]; 50 51 enableParallelBuilding = true; 52 53 doCheck = true; 54 55 meta = with stdenv.lib; { 56 description = "C library for the Publix Suffix List"; 57 longDescription = '' 58 libpsl is a C library for the Publix Suffix List (PSL). A "public suffix" 59 is a domain name under which Internet users can directly register own 60 names. Browsers and other web clients can use it to avoid privacy-leaking 61 "supercookies" and "super domain" certificates, for highlighting parts of 62 the domain in a user interface or sorting domain lists by site. 63 ''; 64 homepage = http://rockdaboot.github.io/libpsl/; 65 license = licenses.mit; 66 platforms = with platforms; linux ++ darwin; 67 }; 68}