fa1433ec8b
libnssckbi.so (which contains the root certificates), so that library has to be in LD_LIBRARY_PATH. svn path=/nixpkgs/trunk/; revision=28519
61 lines
2.1 KiB
Nix
61 lines
2.1 KiB
Nix
{ GConf, alsaLib, bzip2, cairo, cups, dbus, dbus_glib, expat
|
|
, fetchurl, ffmpeg, fontconfig, freetype, gtkLibs, libX11
|
|
, libXScrnSaver, libXdamage, libXext, libXrender, libXt, libXtst
|
|
, libgcrypt, libjpeg, libpng, makeWrapper, nspr, nss, patchelf
|
|
, stdenv, unzip, zlib, pam }:
|
|
|
|
assert stdenv.system == "i686-linux" || stdenv.system == "x86_64-linux" ;
|
|
|
|
stdenv.mkDerivation rec {
|
|
name = "chrome-${version}";
|
|
version = "88807";
|
|
src =
|
|
if stdenv.system == "x86_64-linux" then
|
|
fetchurl {
|
|
url = "http://commondatastorage.googleapis.com/chromium-browser-continuous/Linux_x64/${version}/chrome-linux.zip";
|
|
sha256 = "c158f58fa8220782ec8dec4170f90c564b978d1c6ead298cc2f67e84613f17b1";
|
|
}
|
|
else if stdenv.system == "i686-linux" then
|
|
fetchurl {
|
|
url = "http://commondatastorage.googleapis.com/chromium-browser-continuous/Linux/${version}/chrome-linux.zip";
|
|
sha256 = "01sr882c7hr53001p8bnk5vyj8zfjm6r3i4a6wxzxd17xjh1bcxb";
|
|
}
|
|
else throw "Chromium is not supported on this platform.";
|
|
|
|
phases = "unpackPhase installPhase";
|
|
|
|
buildInputs = [ makeWrapper unzip ];
|
|
|
|
libPath =
|
|
stdenv.lib.makeLibraryPath
|
|
[ GConf alsaLib bzip2 cairo cups dbus dbus_glib expat
|
|
ffmpeg fontconfig freetype libX11 libXScrnSaver
|
|
libXdamage libXext libXrender libXt libXtst libgcrypt libjpeg
|
|
libpng nspr nss stdenv.gcc.gcc zlib stdenv.gcc.libc
|
|
gtkLibs.glib gtkLibs.gtk gtkLibs.gdk_pixbuf gtkLibs.pango
|
|
pam
|
|
];
|
|
|
|
installPhase = ''
|
|
ensureDir $out/bin
|
|
ensureDir $out/libexec/chrome
|
|
|
|
cp -R * $out/libexec/chrome
|
|
|
|
${patchelf}/bin/patchelf \
|
|
--interpreter "$(cat $NIX_GCC/nix-support/dynamic-linker)" \
|
|
--set-rpath ${libPath}:$out/lib:${stdenv.gcc.gcc}/lib64:${stdenv.gcc.gcc}/lib \
|
|
$out/libexec/chrome/chrome
|
|
|
|
makeWrapper $out/libexec/chrome/chrome $out/bin/chrome \
|
|
--prefix LD_LIBRARY_PATH : "${nss}/lib"
|
|
'';
|
|
|
|
meta = with stdenv.lib; {
|
|
description = "Chromium, an open source web browser";
|
|
homepage = http://www.chromium.org/;
|
|
maintainers = [ maintainers.goibhniu ];
|
|
license = licenses.bsd3;
|
|
};
|
|
}
|