at 18.09-beta 41 lines 1.3 kB view raw
1{ stdenv, fetchFromGitHub, pkgconfig, cmake, zlib 2, dbus, networkmanager, spidermonkey_38, pcre, python2, python3 3, SystemConfiguration, CoreFoundation, JavaScriptCore }: 4 5stdenv.mkDerivation rec { 6 name = "libproxy-${version}"; 7 version = "0.4.15"; 8 9 src = fetchFromGitHub { 10 owner = "libproxy"; 11 repo = "libproxy"; 12 rev = version; 13 sha256 = "10swd3x576pinx33iwsbd4h15fbh2snmfxzcmab4c56nb08qlbrs"; 14 }; 15 16 outputs = [ "out" "dev" ]; # to deal with propagatedBuildInputs 17 18 nativeBuildInputs = [ pkgconfig cmake ]; 19 20 buildInputs = [ pcre python2 python3 zlib ] 21 ++ (if stdenv.hostPlatform.isDarwin 22 then [ SystemConfiguration CoreFoundation JavaScriptCore ] 23 else [ spidermonkey_38 dbus networkmanager ]); 24 25 preConfigure = '' 26 cmakeFlagsArray+=( 27 "-DWITH_MOZJS=ON" 28 "-DPYTHON2_SITEPKG_DIR=$out/${python2.sitePackages}" 29 "-DPYTHON3_SITEPKG_DIR=$out/${python3.sitePackages}" 30 ) 31 ''; 32 33 doCheck = false; # fails 1 out of 10 tests 34 35 meta = with stdenv.lib; { 36 platforms = platforms.linux ++ platforms.darwin; 37 license = licenses.lgpl21; 38 homepage = http://libproxy.github.io/libproxy/; 39 description = "A library that provides automatic proxy configuration management"; 40 }; 41}