Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib, stdenvNoCC, fetchurl }: 2 3stdenvNoCC.mkDerivation rec { 4 pname = "psol"; 5 version = "1.13.35.2"; # Latest stable, 2018-02-05 6 7 src = fetchurl { 8 url = "https://dl.google.com/dl/page-speed/psol/${version}-x64.tar.gz"; 9 hash = "sha256-3zujyPxU4ThF0KHap6bj2YMSbCORKFG7+Lo1vmRqQ08="; 10 }; 11 12 installPhase = '' 13 runHook preInstall 14 15 mkdir -p $out 16 mv include lib -t $out 17 18 runHook postInstall 19 ''; 20 21 meta = with lib; { 22 description = "PageSpeed Optimization Libraries"; 23 homepage = "https://developers.google.com/speed/pagespeed/psol"; 24 license = licenses.asl20; 25 sourceProvenance = with sourceTypes; [ binaryNativeCode ]; 26 # WARNING: This only works with Linux because the pre-built PSOL binary is only supplied for Linux. 27 # TODO: Build PSOL from source to support more platforms. 28 platforms = platforms.linux; 29 }; 30}