mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-13 21:32:23 +03:00
Forward port: ccache, FF3b3
svn path=/nixpkgs/branches/stdenv-updates/; revision=10694
This commit is contained in:
parent
80612bff71
commit
d607e902af
55
pkgs/applications/networking/browsers/firefox-3/binary.nix
Normal file
55
pkgs/applications/networking/browsers/firefox-3/binary.nix
Normal file
@ -0,0 +1,55 @@
|
||||
args: with args;
|
||||
|
||||
assert stdenv.system == "i686-linux";
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "firefox-3b1";
|
||||
|
||||
src =
|
||||
fetchurl {
|
||||
url = ftp://ftp.mozilla.org/pub/firefox/releases/3.0b1/linux-i686/en-US/firefox-3.0b1.tar.bz2;
|
||||
sha256 = "1cpcc5b07zdqyd5kiwhb4dqhy2mzbf97plsglcp6bc9054cmsylk";
|
||||
};
|
||||
buildInputs = [
|
||||
pkgconfig gtk perl zip libIDL libXi libjpeg libpng zlib cairo
|
||||
python curl coreutils atk pango glib libX11 libXrender
|
||||
freetype fontconfig libXft libXt
|
||||
];
|
||||
|
||||
buildPhase = "
|
||||
additionalRpath='';
|
||||
for i in \$buildInputs ${stdenv.glibc} ${stdenv.gcc.gcc}; do
|
||||
additionalRpath=\$additionalRpath:\$i/lib;
|
||||
done
|
||||
for i in firefox-bin ; do
|
||||
oldrpath=$(patchelf --print-rpath \$i)
|
||||
patchelf --set-rpath \$oldrpath\$additionalRpath \$i
|
||||
patchelf --set-interpreter ${stdenv.glibc}/lib/ld-linux.so.2 \$i
|
||||
done
|
||||
";
|
||||
|
||||
installPhase = "
|
||||
export dontPatchELF=1;
|
||||
mkdir -p \$out
|
||||
cp -r . \$out/firefox
|
||||
mkdir -p \$out/bin
|
||||
ln -s \$out/firefox/firefox \$out/bin/firefox
|
||||
|
||||
sed -e 's@moz_libdir=.*@moz_libdir='\$out'/firefox/@' -i \$out/bin/firefox
|
||||
sed -e 's@moz_libdir=.*@&\\nexport PATH=\$PATH:${coreutils}/bin@' -i \$out/bin/firefox
|
||||
sed -e 's@`/bin/pwd@`${coreutils}/bin/pwd@' -i \$out/bin/firefox
|
||||
sed -e 's@`/bin/ls@`${coreutils}/bin/ls@' -i \$out/bin/firefox
|
||||
|
||||
strip -S \$out/firefox/*.so || true
|
||||
|
||||
echo \"running firefox -register...\"
|
||||
\$out/firefox/firefox-bin -register || false
|
||||
";
|
||||
|
||||
meta = {
|
||||
description = "Mozilla Firefox - the browser, reloaded";
|
||||
};
|
||||
|
||||
passthru = {inherit gtk;};
|
||||
}
|
||||
|
30
pkgs/applications/networking/browsers/firefox-3/builder.sh
Normal file
30
pkgs/applications/networking/browsers/firefox-3/builder.sh
Normal file
@ -0,0 +1,30 @@
|
||||
source $stdenv/setup
|
||||
|
||||
postInstall=postInstall
|
||||
postInstall() {
|
||||
|
||||
# Strip some more stuff
|
||||
strip -S $out/lib/*/* || true
|
||||
|
||||
# This fixes starting Firefox when there already is a running
|
||||
# instance. The `firefox' wrapper script actually expects to be
|
||||
# in the same directory as `run-mozilla.sh', apparently.
|
||||
libDir=$(cd $out/lib && ls -d firefox-*)
|
||||
test -n "$libDir"
|
||||
cd $out/bin
|
||||
mv firefox ../lib/$libDir/
|
||||
ln -s ../lib/$libDir/firefox .
|
||||
|
||||
# Register extensions etc.
|
||||
echo "running firefox -register..."
|
||||
(cd $out/lib/$libDir && LD_LIBRARY_PATH=. ./firefox-bin -register) || false
|
||||
|
||||
echo "running regxpcom..."
|
||||
(cd $out/lib/$libDir && LD_LIBRARY_PATH=. ./regxpcom) || false
|
||||
|
||||
# Put the Firefox icon in the right place.
|
||||
ensureDir $out/lib/$libDir/chrome/icons/default
|
||||
ln -s ../../../icons/default.xpm $out/lib/$libDir/chrome/icons/default/
|
||||
}
|
||||
|
||||
genericBuild
|
64
pkgs/applications/networking/browsers/firefox-3/default.nix
Normal file
64
pkgs/applications/networking/browsers/firefox-3/default.nix
Normal file
@ -0,0 +1,64 @@
|
||||
args: with args;
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "firefox-3.0-beta-3";
|
||||
|
||||
src = fetchurl {
|
||||
url = ftp://ftp.mozilla.org/pub/firefox/releases/3.0b3/source/firefox-3.0b3-source.tar.bz2;
|
||||
sha1 = "142f28a41077e77d61423a5ca6585a45737ff999";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
pkgconfig gtk perl zip libIDL libXi libjpeg libpng zlib cairo
|
||||
python curl coreutils dbus dbus_glib pango freetype fontconfig
|
||||
libX11 libXrender libXft libXt
|
||||
];
|
||||
|
||||
configureFlags = [
|
||||
"--enable-application=browser"
|
||||
"--enable-optimize"
|
||||
"--disable-debug"
|
||||
"--enable-strip"
|
||||
"--with-system-jpeg"
|
||||
"--with-system-zlib"
|
||||
#"--with-system-png" <-- "--with-system-png won't work because the system's libpng doesn't have APNG support"
|
||||
#"--enable-system-cairo" <-- disabled for now because Firefox needs a alpha version of Cairo
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
export dontPatchELF=1;
|
||||
|
||||
# Strip some more stuff
|
||||
strip -S $out/lib/*/* || true
|
||||
|
||||
# Fix some references to /bin paths in the Firefox shell script.
|
||||
substituteInPlace $out/bin/firefox \
|
||||
--replace /bin/pwd "$(type -tP pwd)" \
|
||||
--replace /bin/ls "$(type -tP ls)"
|
||||
|
||||
# This fixes starting Firefox when there already is a running
|
||||
# instance. The `firefox' wrapper script actually expects to be
|
||||
# in the same directory as `run-mozilla.sh', apparently.
|
||||
libDir=$(cd $out/lib && ls -d firefox-[0-9]*)
|
||||
test -n "$libDir"
|
||||
cd $out/bin
|
||||
mv firefox ../lib/$libDir/
|
||||
ln -s ../lib/$libDir/firefox .
|
||||
|
||||
# Register extensions etc.
|
||||
echo "running firefox -register..."
|
||||
(cd $out/lib/$libDir && LD_LIBRARY_PATH=. ./firefox-bin -register) || false
|
||||
|
||||
# Put the Firefox icon in the right place.
|
||||
ensureDir $out/lib/$libDir/chrome/icons/default
|
||||
ln -s ../../../icons/default.xpm $out/lib/$libDir/chrome/icons/default/
|
||||
''; # */
|
||||
|
||||
meta = {
|
||||
description = "Mozilla Firefox - the browser, reloaded";
|
||||
homepage = http://www.mozilla.com/en-US/firefox/;
|
||||
};
|
||||
|
||||
passthru = {inherit gtk;};
|
||||
}
|
||||
|
15
pkgs/development/tools/misc/ccache/default.nix
Normal file
15
pkgs/development/tools/misc/ccache/default.nix
Normal file
@ -0,0 +1,15 @@
|
||||
{stdenv, fetchurl}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "ccache-2.4";
|
||||
src = fetchurl {
|
||||
url = http://samba.org/ftp/ccache/ccache-2.4.tar.gz;
|
||||
sha256 = "435f862ca5168c346f5aa9e242174bbf19a5abcaeecfceeac2f194558827aaa0";
|
||||
};
|
||||
|
||||
meta = {
|
||||
description = "ccache, a tool that caches compilation results.";
|
||||
homepage = http://ccache.samba.org/;
|
||||
license = "GPL";
|
||||
};
|
||||
}
|
@ -1522,6 +1522,10 @@ rec {
|
||||
inherit fetchurl stdenv m4;
|
||||
};
|
||||
|
||||
ccache = import ../development/tools/misc/ccache {
|
||||
inherit fetchurl stdenv;
|
||||
};
|
||||
|
||||
ctags = import ../development/tools/misc/ctags {
|
||||
inherit fetchurl stdenv;
|
||||
};
|
||||
@ -4182,6 +4186,15 @@ rec {
|
||||
|
||||
firefoxWrapper = wrapFirefox firefox "";
|
||||
|
||||
firefox3 = lowPrio (import ../applications/networking/browsers/firefox-3 {
|
||||
inherit fetchurl stdenv pkgconfig perl zip libjpeg libpng zlib cairo
|
||||
python curl coreutils dbus dbus_glib freetype fontconfig;
|
||||
inherit (gtkLibs) gtk pango;
|
||||
inherit (gnome) libIDL;
|
||||
inherit (xlibs) libXi libX11 libXrender libXft libXt;
|
||||
#enableOfficialBranding = true;
|
||||
});
|
||||
|
||||
firefox3b1 = lowPrio (import ../applications/networking/browsers/firefox3b1 {
|
||||
inherit fetchurl stdenv pkgconfig perl zip libjpeg libpng zlib cairo
|
||||
python curl coreutils;
|
||||
|
Loading…
Reference in New Issue
Block a user