Merge branch 'master.upstream' into staging.upstream

This commit is contained in:
William A. Kennington III
2015-10-30 17:16:07 -07:00
320 changed files with 26241 additions and 2581 deletions

View File

@@ -3,6 +3,7 @@
, alsaSupport ? true, alsaLib ? null
, x11Support ? true, xlibsWrapper ? null, libXrandr ? null
, pulseaudioSupport ? true, libpulseaudio ? null
, OpenGL, CoreAudio, CoreServices, AudioUnit, Kernel, Cocoa
}:
# OSS is no longer supported, for it's much crappier than ALSA and
@@ -40,7 +41,8 @@ stdenv.mkDerivation rec {
buildInputs = let
notMingw = !(stdenv ? cross) || stdenv.cross.libc != "msvcrt";
in optional notMingw audiofile;
in optional notMingw audiofile
++ optionals stdenv.isDarwin [ OpenGL CoreAudio CoreServices AudioUnit Kernel Cocoa ];
# XXX: By default, SDL wants to dlopen() PulseAudio, in which case
# we must arrange to add it to its RPATH; however, `patchelf' seems

View File

@@ -3,6 +3,7 @@
, alsaSupport ? true, alsaLib ? null
, x11Support ? true, xlibsWrapper ? null, libXrandr ? null
, pulseaudioSupport ? true, libpulseaudio ? null
, AudioUnit, Cocoa, CoreAudio, CoreServices, ForceFeedback, OpenGL
}:
# OSS is no longer supported, for it's much crappier than ALSA and
@@ -36,7 +37,8 @@ stdenv.mkDerivation rec {
buildInputs = [ pkgconfig audiofile ] ++
stdenv.lib.optional openglSupport mesa ++
stdenv.lib.optional alsaSupport alsaLib;
stdenv.lib.optional alsaSupport alsaLib ++
stdenv.lib.optionals stdenv.isDarwin [ AudioUnit Cocoa CoreAudio CoreServices ForceFeedback OpenGL ];
# https://bugzilla.libsdl.org/show_bug.cgi?id=1431
dontDisableStatic = true;

View File

@@ -0,0 +1,20 @@
{ stdenv, fetchurl, pkgconfig, glib }:
stdenv.mkDerivation rec {
name = "ctpl-${version}";
version = "0.3.4";
src = fetchurl {
url = "http://download.tuxfamily.org/ctpl/releases/ctpl-${version}.tar.gz";
sha256 = "1yr92xv9n6kgyixwg9ps4zb404ic5pgb171k4bi3mv9p6k8gv59s";
};
buildInputs = [ pkgconfig glib ];
meta = with stdenv.lib; {
homepage = http://ctpl.tuxfamily.org/;
description = "Template engine library written in C";
platforms = platforms.linux;
maintainers = [ maintainers.lethalman ];
};
}

View File

@@ -16,6 +16,11 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ autoreconfHook pkgconfig utilmacros python ];
buildInputs = [ mesa libX11 ];
preConfigure = stdenv.lib.optional stdenv.isDarwin ''
substituteInPlace configure --replace build_glx=no build_glx=yes
substituteInPlace src/dispatch_common.h --replace "PLATFORM_HAS_GLX 0" "PLATFORM_HAS_GLX 1"
'';
meta = with stdenv.lib; {
description = "A library for handling OpenGL function pointer management";
homepage = https://github.com/anholt/libepoxy;

View File

@@ -10,6 +10,8 @@
, debugDeveloper ? false
, optimizationsDeveloper ? true
, extraWarningsDeveloper ? false
# Darwin frameworks
, Cocoa
# Inherit generics
, branch, sha256, version, ...
}:
@@ -141,7 +143,8 @@ stdenv.mkDerivation rec {
] ++ optional openglSupport mesa
++ optionals (!isDarwin) [ libvpx libpulseaudio ] # Need to be fixed on Darwin
++ optional (isLinux || isFreeBSD) libva
++ optional isLinux alsaLib;
++ optional isLinux alsaLib
++ optional isDarwin Cocoa;
enableParallelBuilding = true;

View File

@@ -1,11 +1,11 @@
{stdenv, fetchurl, libpng, libtiff, libjpeg, zlib}:
stdenv.mkDerivation {
name = "leptonica-1.69";
name = "leptonica-1.72";
src = fetchurl {
url = http://www.leptonica.org/source/leptonica-1.69.tar.gz;
sha256 = "0bd7w0zpmwwfn1cnrlyzjw3jf8x59r0rhdmvk7rigr57rnfnddry";
url = http://www.leptonica.org/source/leptonica-1.72.tar.gz;
sha256 = "0mhzvqs0im04y1cpcc1yma70hgdac1frf33h73m9z3356bfymmbr";
};
buildInputs = [ libpng libtiff libjpeg zlib ];

View File

@@ -1,5 +1,8 @@
{ stdenv, fetchurl, libjpeg, libpng, libmng, lcms1, libtiff, openexr, mesa
, libX11, pkgconfig }:
, libX11, pkgconfig
, OpenGL
}:
stdenv.mkDerivation rec {
@@ -11,7 +14,8 @@ stdenv.mkDerivation rec {
sha256 = "1zd850nn7nvkkhasrv7kn17kzgslr5ry933v6db62s4lr0zzlbv8";
};
buildInputs = [ libjpeg libpng libmng lcms1 libtiff openexr mesa libX11 ];
buildInputs = [ libjpeg libpng libmng lcms1 libtiff openexr mesa libX11 ]
++ stdenv.lib.optionals stdenv.isDarwin [ OpenGL ];
nativeBuildInputs = [ pkgconfig ];
configureFlags = [ "--enable-ILU" "--enable-ILUT" ];

View File

@@ -15,11 +15,11 @@ in
with stdenv.lib;
stdenv.mkDerivation rec {
name = "libinput-1.0.1";
name = "libinput-1.0.2";
src = fetchurl {
url = "http://www.freedesktop.org/software/libinput/${name}.tar.xz";
sha256 = "17prgxxq95i2l8a00clwwmvvskbb9xza9fmym1jvlmxl358v6bs8";
sha256 = "1fggbi8w8r7mayyk7zwqrqf3ni95y2703vcpggxqq7yjdgw0bld3";
};
configureFlags = [

View File

@@ -1,11 +1,11 @@
{ stdenv, fetchurl, automake, autoconf, libtool, pkgconfig, libzen, zlib }:
stdenv.mkDerivation rec {
version = "0.7.77";
version = "0.7.78";
name = "libmediainfo-${version}";
src = fetchurl {
url = "http://mediaarea.net/download/source/libmediainfo/${version}/libmediainfo_${version}.tar.xz";
sha256 = "1znxdn1jpqkiwshq9s514ak1z9wkrh9flky4s3q8z2xl68jpralq";
sha256 = "0ai4al5h3qbfq5f1b24ixk5v1fpln2kw1zmdj4hxjz40rj18qzka";
};
buildInputs = [ automake autoconf libtool pkgconfig libzen zlib ];

View File

@@ -27,6 +27,5 @@ stdenv.mkDerivation {
description = "Qt wrapper for ModemManager DBus API";
license = licenses.lgpl21;
platforms = platforms.linux;
maintainers = [ maintainers.jgeerds ];
};
}

View File

@@ -29,6 +29,5 @@ stdenv.mkDerivation {
description = "Qt wrapper for NetworkManager DBus API";
license = licenses.lgpl21;
platforms = platforms.linux;
maintainers = [ maintainers.jgeerds ];
};
}

View File

@@ -16,7 +16,7 @@ stdenv.mkDerivation {
meta = with stdenv.lib; {
description = "A collection of GTK+ widgets";
homepahe = http://blog.chipx86.com/tag/libsexy/;
homepage = http://blog.chipx86.com/tag/libsexy/;
license = licenses.lgpl21;
maintainers = with maintainers; [ ];
platforms = platforms.unix;

View File

@@ -2,13 +2,13 @@
stdenv.mkDerivation rec {
name = "libstrophe-${version}";
version = "0.8.7";
version = "0.8.8";
src = fetchFromGitHub {
owner = "strophe";
repo = "libstrophe";
rev = version;
sha256 = "1iic8xbcxh21dzns8m9kkz0cj5f3ppn414gnhyh4y2wcjsz6hp8l";
sha256 = "1xzyqqf99r0jfd0g3v0zwc68sac6y25v1d4m365zpc14l02midis";
};
buildInputs = [ automake autoconf openssl expat libtool pkgconfig check ];

View File

@@ -1,11 +1,11 @@
{ fetchurl, stdenv, glib, pkgconfig, udev }:
stdenv.mkDerivation rec {
name = "libwacom-0.7.1";
name = "libwacom-0.15";
src = fetchurl {
url = "mirror://sourceforge/linuxwacom/libwacom/${name}.tar.bz2";
sha256 = "1agdaa1bv5mp4l32qgsw63swnnv0p279jiy9madgw4y3d8d12dwm";
sha256 = "04vppdj99cc0ya44n8p7zjk9yyw03v6fksw0a9n1gpnnsn4wardb";
};
buildInputs = [ glib pkgconfig udev ];

View File

@@ -1,6 +1,7 @@
{ stdenv, fetchzip }:
stdenv.mkDerivation rec {
let optional = stdenv.lib.optional;
in stdenv.mkDerivation rec {
name = "lmdb-${version}";
version = "0.9.16";
@@ -11,7 +12,8 @@ stdenv.mkDerivation rec {
postUnpack = "sourceRoot=\${sourceRoot}/libraries/liblmdb";
makeFlags = "prefix=$(out)";
makeFlags = ["prefix=$(out)"]
++ optional stdenv.cc.isClang "CC=clang";
doCheck = true;
checkPhase = "make test";

View File

@@ -2,7 +2,7 @@
, python, libxml2Python, file, expat, makedepend, xorg, llvm, libffi, libvdpau
, enableTextureFloats ? false # Texture floats are patented, see docs/patents.txt
, enableExtraFeatures ? false # not maintained
, darwin
, OpenGL, apple_sdk, Xplugin
}:
let
@@ -23,11 +23,7 @@ let
presentproto
libX11 libXext libxcb libXt libxshmfence
libffi libvdpau
] ++ stdenv.lib.optionals stdenv.isDarwin [
darwin.apple_sdk.frameworks.OpenGL
darwin.apple_sdk.sdk
darwin.apple_sdk.libs.Xplugin
];
] ++ stdenv.lib.optionals stdenv.isDarwin [ OpenGL apple_sdk.sdk Xplugin ];
postUnpack = ''
ln -s darwin $sourceRoot/configs/current

View File

@@ -4,11 +4,11 @@
stdenv.mkDerivation rec {
name = "mlt-${version}";
version = "0.9.6";
version = "0.9.8";
src = fetchurl {
url = "https://github.com/mltframework/mlt/archive/v${version}.tar.gz";
sha256 = "0s8ypg0q50zfcmq527y8cbdvzxhiqidm1923k28ar8jqmjp45ssh";
sha256 = "0x0hsb05i7g70dh3jll41qlvcylailfgsr0y1dpx7hyigynxc50j";
};
buildInputs = [

View File

@@ -2,11 +2,11 @@
stdenv.mkDerivation rec {
name = "movit-${version}";
version = "1.1.3";
version = "1.2.0";
src = fetchurl {
url = "http://movit.sesse.net/${name}.tar.gz";
sha256 = "0q33h3gfw16gd9k6s3isd7ili2mifw7j1723xpdlc516gggsazw9";
sha256 = "0wyl5xl4pkw17pkxsdg8idqvsgm4fxapd0r4dw9wlxw250915nmf";
};
GTEST_DIR = "${gtest}";

View File

@@ -4,11 +4,11 @@
stdenv.mkDerivation rec {
name = "subunit-${version}";
version = "1.0.0";
version = "1.1.0";
src = fetchurl {
url = "https://launchpad.net/subunit/trunk/${version}/+download/${name}.tar.gz";
sha256 = "1fnhrrwww90746an2nz2kn9qdf9pklmaf5lm22gssl6648f2rp2m";
sha256 = "0lcah7p66c05p7xpw6ns1is0i02lh0nq8gq51mv4wyvbr6zaasa8";
};
buildInputs = [ pkgconfig check cppunit perl pythonPackages.wrapPython ];

View File

@@ -0,0 +1,142 @@
{ stdenv, lib, fetchgit, fetchFromGitHub, gyp, readline, python, which, icu
, patchelf, coreutils
, doCheck ? false
}:
assert readline != null;
let
arch = if stdenv.isArm
then if stdenv.is64bit
then"arm64"
else "arm"
else if stdenv.is64bit
then"x64"
else "ia32";
git_url = "https://chromium.googlesource.com";
clangFlag = if stdenv.isDarwin then "1" else "0";
deps = {
"build/gyp" = fetchgit {
url = "${git_url}/external/gyp.git";
rev = "5122240c5e5c4d8da12c543d82b03d6089eb77c5";
sha256 = "0mdrrhmfl4jrdmfrxmg7ywhdf9c7gv2x08fiq955fs9z8kvxqgdx";
};
"third_party/icu" = fetchgit {
url = "${git_url}/chromium/deps/icu.git";
rev = "c81a1a3989c3b66fa323e9a6ee7418d7c08297af";
sha256 = "0xrhig85vpw9hqjrhkxsr69m2xnig2bwmjhylzffrwz0783l7yhw";
};
"buildtools" = fetchgit {
url = "${git_url}/chromium/buildtools.git";
rev = "ecc8e253abac3b6186a97573871a084f4c0ca3ae";
sha256 = "1ccfnj3dp4i0z2bj09zy8aa4x749id6h058qa330li368417jwci";
};
"testing/gtest" = fetchgit {
url = "${git_url}/external/googletest.git";
rev = "23574bf2333f834ff665f894c97bef8a5b33a0a9";
sha256 = "1scyrk8d6xrsqma27q0wdrxqfa2n12k8mi9lfbsm5ivim9sr1d75";
};
"testing/gmock" = fetchgit {
url = "${git_url}/external/googlemock.git";
rev = "29763965ab52f24565299976b936d1265cb6a271";
sha256 = "0n2ajjac7myr5bgqk0x7j8281b4whkzgr1irv5nji9n3xz5i6gz4";
};
"tools/clang" = fetchgit {
url = "${git_url}/chromium/src/tools/clang.git";
rev = "73ec8804ed395b0886d6edf82a9f33583f4a7902";
sha256 = "0p2w4cgj3d4lqa8arss3j86lk0g8zhbbn5pzlcrhy5pl4xphjbk3";
};
};
in
stdenv.mkDerivation rec {
name = "v8-${version}";
version = "4.5.107";
inherit doCheck;
src = fetchFromGitHub {
owner = "v8";
repo = "v8";
rev = version;
sha256 = "0wbzi4rhm4ygsm1k4x0vwfm42z3j8ww6wz7bcvd0m7mqzayn0bw4";
};
postUnpack = ''
${lib.concatStringsSep "\n" (
lib.mapAttrsToList (n: v: ''
mkdir -p $sourceRoot/${n}
cp -r ${v}/* $sourceRoot/${n}
'') deps)}
'';
# Patches pulled from:
# https://github.com/cowboyd/libv8/tree/4.5/patches
patches = lib.optional (!doCheck) ./disable-building-tests.patch ++ [
./fPIC-for-static.patch
./build-standalone-static-library.patch
];
postPatch = ''
sed -i 's,#!/usr/bin/env python,#!${python}/bin/python,' build/gyp_v8
sed -i 's,/bin/echo,${coreutils}/bin/echo,' build/standalone.gypi
sed -i '/CR_CLANG_REVISION/ d' build/standalone.gypi
'';
configurePhase = ''
PYTHONPATH="tools/generate_shim_headers:$PYTHONPATH" \
PYTHONPATH="$(toPythonPath ${gyp}):$PYTHONPATH" \
build/gyp_v8 \
-f make \
--generator-output="out" \
-Dflock_index=0 \
-Dclang=${clangFlag} \
-Dv8_enable_i18n_support=1 \
-Duse_system_icu=1 \
-Dcomponent=shared_library \
-Dconsole=readline \
-Dv8_target_arch=${arch} \
-Dv8_use_external_startup_data=0
'';
nativeBuildInputs = [ which ];
buildInputs = [ readline python icu patchelf ];
buildFlags = [
"LINK=g++"
"-C out"
"builddir=$(CURDIR)/Release"
"BUILDTYPE=Release"
];
enableParallelBuilding = true;
# the `libv8_libplatform` target is _only_ built as a static library,
# and is expected to be statically linked in when needed.
# see the following link for further commentary:
# https://github.com/cowboyd/therubyracer/issues/391
installPhase = ''
install -vD out/Release/d8 "$out/bin/d8"
install -vD out/Release/mksnapshot "$out/bin/mksnapshot"
${if stdenv.isDarwin then ''
install -vD out/Release/lib.target/libv8.dylib "$out/lib/libv8.dylib"
install_name_tool -change /usr/local/lib/libv8.dylib $out/lib/libv8.dylib -change /usr/lib/libgcc_s.1.dylib ${stdenv.cc.cc}/lib/libgcc_s.1.dylib $out/bin/d8
install_name_tool -id $out/lib/libv8.dylib -change /usr/lib/libgcc_s.1.dylib ${stdenv.cc.cc}/lib/libgcc_s.1.dylib $out/lib/libv8.dylib
'' else ''
install -vD out/Release/lib.target/libv8.so "$out/lib/libv8.so"
''}
mkdir -p "$out/include"
cp -vr include/*.h "$out/include"
cp -vr include/libplatform "$out/include"
cp -v out/Release/*.a "$out/lib"
'';
meta = with lib; {
description = "Google's open source JavaScript engine";
maintainers = with maintainers; [ cstrahan ];
platforms = with platforms; linux;
license = licenses.bsd3;
};
}

View File

@@ -0,0 +1,14 @@
diff --git a/build/standalone.gypi b/build/standalone.gypi
index b6519c4..ef9e7c5 100644
--- a/build/standalone.gypi
+++ b/build/standalone.gypi
@@ -373,6 +373,9 @@
}],
],
'target_conditions': [
+ ['_type=="static_library"', {
+ 'standalone_static_library': 1,
+ }],
['v8_code == 0', {
'defines!': [
'DEBUG',

View File

@@ -0,0 +1,27 @@
diff --git a/Makefile b/Makefile
index 9761265..80169b2 100644
--- a/Makefile
+++ b/Makefile
@@ -248,8 +248,6 @@ NACL_ARCHES = nacl_ia32 nacl_x64
GYPFILES = third_party/icu/icu.gypi third_party/icu/icu.gyp \
build/shim_headers.gypi build/features.gypi build/standalone.gypi \
build/toolchain.gypi build/all.gyp build/mac/asan.gyp \
- test/cctest/cctest.gyp \
- test/unittests/unittests.gyp tools/gyp/v8.gyp \
tools/parser-shell.gyp testing/gmock.gyp testing/gtest.gyp \
buildtools/third_party/libc++abi/libc++abi.gyp \
buildtools/third_party/libc++/libc++.gyp samples/samples.gyp \
diff --git a/build/all.gyp b/build/all.gyp
index 4aeb507..1ff2c7a 100644
--- a/build/all.gyp
+++ b/build/all.gyp
@@ -10,8 +10,6 @@
'dependencies': [
'../samples/samples.gyp:*',
'../src/d8.gyp:d8',
- '../test/cctest/cctest.gyp:*',
- '../test/unittests/unittests.gyp:*',
],
'conditions': [
['component!="shared_library"', {

View File

@@ -0,0 +1,13 @@
diff --git a/build/standalone.gypi b/build/standalone.gypi
index 7670e5b..230518c 100644
--- a/build/standalone.gypi
+++ b/build/standalone.gypi
@@ -205,7 +205,7 @@
[ 'visibility=="hidden" and v8_enable_backtrace==0', {
'cflags': [ '-fvisibility=hidden' ],
}],
- [ 'component=="shared_library"', {
+ [ 'component=="shared_library" or component=="static_library" and (v8_target_arch=="x64" or v8_target_arch=="arm64")', {
'cflags': [ '-fPIC', ],
}],
],

View File

@@ -1,5 +1,7 @@
{ stdenv, fetchurl, setfile, rez, derez,
expat, libiconv, libjpeg, libpng, libtiff, zlib
{ stdenv, fetchurl
, expat, libiconv, libjpeg, libpng, libtiff, zlib
, setfile, rez, derez
, AGL, Cocoa, Kernel, QuickTime
}:
with stdenv.lib;
@@ -15,9 +17,20 @@ stdenv.mkDerivation rec {
patches = [ ./wx.patch ];
buildInputs = [ setfile rez derez expat libiconv libjpeg libpng libtiff zlib ];
buildInputs = [
expat libiconv libjpeg libpng libtiff zlib
Cocoa Kernel QuickTime setfile rez derez
];
propagatedBuildInputs = [ AGL ];
postPatch = ''
substituteInPlace configure --replace "-framework System" -lSystem
'';
configureFlags = [
"wx_cv_std_libfullpath=/var/empty"
"--with-macosx-version-min=10.7"
"--enable-unicode"
"--with-osx_cocoa"
"--enable-std_string"
@@ -44,6 +57,8 @@ stdenv.mkDerivation rec {
./wx-config --libs
'';
NIX_CFLAGS_COMPILE = "-Wno-undef";
doCheck = true;
enableParallelBuilding = true;

View File

@@ -1,4 +1,5 @@
{ stdenv, fetchurl, libxml2, gnutls, libxslt, pkgconfig, libgcrypt, libtool }:
{ stdenv, fetchurl, libxml2, gnutls, libxslt, pkgconfig, libgcrypt, libtool
, openssl, makeWrapper }:
let
version = "1.2.20";
@@ -11,9 +12,13 @@ stdenv.mkDerivation rec {
sha256 = "01bkbv2y3x8d1sf4dcln1x3y2jyj391s3208d9a2ndhglly5j89j";
};
buildInputs = [ libxml2 gnutls libxslt pkgconfig libgcrypt libtool ];
buildInputs = [ makeWrapper libxml2 gnutls libxslt pkgconfig libgcrypt libtool openssl ];
enableParallelBuilding = true;
doCheck = true;
postFixup = ''
wrapProgram "$out/bin/xmlsec1" --prefix LD_LIBRARY_PATH ":" "$out/lib"
'';
meta = {
homepage = http://www.aleksey.com/xmlsec;