mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-10-02 13:00:23 +00:00
This commit was created by a combination of scripts and tools: - an ast-grep script to prefix things in meta with `lib.`, - a modified nixf-diagnose / nixf combination to remove unused `with lib;`, and - regular nixfmt. Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
35 lines
874 B
Nix
35 lines
874 B
Nix
{
|
|
lib,
|
|
stdenvNoCC,
|
|
fetchurl,
|
|
}:
|
|
|
|
stdenvNoCC.mkDerivation rec {
|
|
pname = "psol";
|
|
version = "1.13.35.2"; # Latest stable, 2018-02-05
|
|
|
|
src = fetchurl {
|
|
url = "https://dl.google.com/dl/page-speed/psol/${version}-x64.tar.gz";
|
|
hash = "sha256-3zujyPxU4ThF0KHap6bj2YMSbCORKFG7+Lo1vmRqQ08=";
|
|
};
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
mkdir -p $out
|
|
mv include lib -t $out
|
|
|
|
runHook postInstall
|
|
'';
|
|
|
|
meta = {
|
|
description = "PageSpeed Optimization Libraries";
|
|
homepage = "https://developers.google.com/speed/pagespeed/psol";
|
|
license = lib.licenses.asl20;
|
|
sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ];
|
|
# WARNING: This only works with Linux because the pre-built PSOL binary is only supplied for Linux.
|
|
# TODO: Build PSOL from source to support more platforms.
|
|
platforms = lib.platforms.linux;
|
|
};
|
|
}
|