From 8ab3f88f5c4d73ea4b9eec643c0230dedf9f5c53 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Fri, 22 May 2015 15:49:27 +0200 Subject: libseccomp: Update to 2.2.1 --- pkgs/development/libraries/libseccomp/default.nix | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libseccomp/default.nix b/pkgs/development/libraries/libseccomp/default.nix index 00655b51afc..fd5689380c1 100644 --- a/pkgs/development/libraries/libseccomp/default.nix +++ b/pkgs/development/libraries/libseccomp/default.nix @@ -1,17 +1,16 @@ -{ stdenv, fetchFromGitHub, autoreconfHook, getopt }: +{ stdenv, fetchurl, getopt }: + +let version = "2.2.1"; in stdenv.mkDerivation rec { - name = "libseccomp-${version}"; - version = "2.2.0"; + name = "libseccomp-${version}"; - src = fetchFromGitHub { - owner = "seccomp"; - repo = "libseccomp"; - rev = "v${version}"; - sha256 = "0vfd6hx92cp1jaqxxaj30r92bfm6fmamxi2yqxrl82mqism1lk84"; + src = fetchurl { + url = "https://github.com/seccomp/libseccomp/releases/download/v${version}/libseccomp-${version}.tar.gz"; + sha256 = "0h57a4l5v1aqyqrkj5gfnar8n2nxs2gzrpscym568v3qajgpi88b"; }; - buildInputs = [ autoreconfHook getopt ]; + buildInputs = [ getopt ]; patchPhase = '' patchShebangs . -- cgit 1.4.1 From 3cc04956f3076892fae011ce26dfb21bff5856bc Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 8 Sep 2015 10:48:42 +0200 Subject: libseccomp: Fix hash --- pkgs/development/libraries/libseccomp/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libseccomp/default.nix b/pkgs/development/libraries/libseccomp/default.nix index 757093f2b55..444b68a23ee 100644 --- a/pkgs/development/libraries/libseccomp/default.nix +++ b/pkgs/development/libraries/libseccomp/default.nix @@ -7,7 +7,7 @@ stdenv.mkDerivation rec { src = fetchurl { url = "https://github.com/seccomp/libseccomp/releases/download/v${version}/libseccomp-${version}.tar.gz"; - sha256 = "1vgc9xgdx6mc4fj21axlv2ym9ndnz06ylq3ps3f8210n3xksdq7y"; + sha256 = "d9b400b703cab7bb04b84b9b6e52076a630b673819d7541757bcc16467b6d49e"; }; buildInputs = [ getopt ]; -- cgit 1.4.1 From 3bada19e24a2d7a2b697d8c67b64f014275b3318 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 8 Sep 2015 14:50:50 +0200 Subject: Add libgudev This has been split from systemd. --- pkgs/development/libraries/libgudev/default.nix | 21 +++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 23 insertions(+) create mode 100644 pkgs/development/libraries/libgudev/default.nix (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libgudev/default.nix b/pkgs/development/libraries/libgudev/default.nix new file mode 100644 index 00000000000..e751c6ee6c0 --- /dev/null +++ b/pkgs/development/libraries/libgudev/default.nix @@ -0,0 +1,21 @@ +{ lib, stdenv, fetchurl, pkgconfig, udev, glib }: + +let version = "230"; in + +stdenv.mkDerivation rec { + name = "libgudev-${version}"; + + src = fetchurl { + url = "https://download.gnome.org/sources/libgudev/${version}/${name}.tar.xz"; + sha256 = "a2e77faced0c66d7498403adefcc0707105e03db71a2b2abd620025b86347c18"; + }; + + buildInputs = [ pkgconfig udev glib ]; + + meta = { + homepage = https://wiki.gnome.org/Projects/libgudev; + maintainers = [ lib.maintainers.eelco ]; + platforms = lib.platforms.linux; + license = lib.licenses.lgpl2Plus; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index a8fb4762af8..9f27d2f8884 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -7076,6 +7076,8 @@ let libgsystem = callPackage ../development/libraries/libgsystem { }; + libgudev = callPackage ../development/libraries/libgudev { }; + libguestfs = callPackage ../development/libraries/libguestfs { inherit (perlPackages) libintlperl GetoptLong SysVirt; }; -- cgit 1.4.1 From 7af1e0ae9268d382da9339776c24819cac0862a5 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 8 Sep 2015 20:21:18 +0200 Subject: libmbim: Use libgudev --- pkgs/development/libraries/libmbim/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libmbim/default.nix b/pkgs/development/libraries/libmbim/default.nix index d58f031f376..f910741c446 100644 --- a/pkgs/development/libraries/libmbim/default.nix +++ b/pkgs/development/libraries/libmbim/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, pkgconfig, glib, python, udev }: +{ stdenv, fetchurl, pkgconfig, glib, python, udev, libgudev }: stdenv.mkDerivation rec { name = "libmbim-1.12.2"; @@ -12,11 +12,11 @@ stdenv.mkDerivation rec { patchShebangs . ''; - buildInputs = [ pkgconfig glib udev python ]; + buildInputs = [ pkgconfig glib udev libgudev python ]; meta = with stdenv.lib; { homepage = http://www.freedesktop.org/software/libmbim/; - description = "talking to WWAN modems and devices which speak the Mobile Interface Broadband Model (MBIM) protocol"; + description = "Library for talking to WWAN modems and devices which speak the Mobile Interface Broadband Model (MBIM) protocol"; platforms = platforms.linux; license = licenses.gpl2; maintainers = with maintainers; [ wkennington ]; -- cgit 1.4.1 From d627db79b8a6e74ca2aa14f1d5e82feacf585a97 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 8 Sep 2015 20:22:27 +0200 Subject: libwacom: Use libgudev --- pkgs/development/libraries/libwacom/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libwacom/default.nix b/pkgs/development/libraries/libwacom/default.nix index f6244cba5cb..7a843013835 100644 --- a/pkgs/development/libraries/libwacom/default.nix +++ b/pkgs/development/libraries/libwacom/default.nix @@ -1,4 +1,4 @@ -{ fetchurl, stdenv, glib, pkgconfig, udev }: +{ fetchurl, stdenv, glib, pkgconfig, udev, libgudev }: stdenv.mkDerivation rec { name = "libwacom-0.7.1"; @@ -8,7 +8,7 @@ stdenv.mkDerivation rec { sha256 = "1agdaa1bv5mp4l32qgsw63swnnv0p279jiy9madgw4y3d8d12dwm"; }; - buildInputs = [ glib pkgconfig udev ]; + buildInputs = [ glib pkgconfig udev libgudev ]; meta = with stdenv.lib; { platforms = platforms.linux; -- cgit 1.4.1 From 4b422b9dea1bb44538a132a7792a28dc11a55649 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Fri, 11 Sep 2015 12:22:27 +0200 Subject: More libgudev dependencies --- pkgs/development/libraries/gvfs/default.nix | 8 ++++---- pkgs/tools/networking/modemmanager/default.nix | 4 ++-- pkgs/tools/networking/network-manager/default.nix | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/gvfs/default.nix b/pkgs/development/libraries/gvfs/default.nix index dcdef696ffd..d2a958faed8 100644 --- a/pkgs/development/libraries/gvfs/default.nix +++ b/pkgs/development/libraries/gvfs/default.nix @@ -1,25 +1,25 @@ { stdenv, fetchurl, pkgconfig, intltool, libtool -, glib, dbus, udev, udisks2, libgcrypt +, glib, dbus, udev, libgudev, udisks2, libgcrypt , libgphoto2, avahi, libarchive, fuse, libcdio , libxml2, libxslt, docbook_xsl, samba, libmtp , gnomeSupport ? false, gnome,libgnome_keyring, gconf, makeWrapper }: let ver_maj = "1.22"; - version = "${ver_maj}.2"; + version = "${ver_maj}.4"; in stdenv.mkDerivation rec { name = "gvfs-${version}"; src = fetchurl { url = "mirror://gnome/sources/gvfs/${ver_maj}/${name}.tar.xz"; - sha256 = "8d08c4927b6c20d990498c23280017e7033b31a386f09b4c3ce5bedd20316250"; + sha256 = "57e33faad35aba72be3822099856aca847f391626cf3ec734b42e64ba31f6484"; }; nativeBuildInputs = [ pkgconfig intltool libtool ]; buildInputs = - [ makeWrapper glib dbus.libs udev udisks2 libgcrypt + [ makeWrapper glib dbus.libs udev libgudev udisks2 libgcrypt libgphoto2 avahi libarchive fuse libcdio libxml2 libxslt docbook_xsl samba libmtp # ToDo: a ligther version of libsoup to have FTP/HTTP support? diff --git a/pkgs/tools/networking/modemmanager/default.nix b/pkgs/tools/networking/modemmanager/default.nix index b044b526873..77c71f38331 100644 --- a/pkgs/tools/networking/modemmanager/default.nix +++ b/pkgs/tools/networking/modemmanager/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, udev, polkit, dbus_glib, ppp, intltool, pkgconfig, libmbim, libqmi }: +{ stdenv, fetchurl, udev, libgudev, polkit, dbus_glib, ppp, intltool, pkgconfig, libmbim, libqmi }: stdenv.mkDerivation rec { name = "ModemManager-${version}"; @@ -11,7 +11,7 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ intltool pkgconfig ]; - buildInputs = [ udev polkit dbus_glib ppp libmbim libqmi ]; + buildInputs = [ udev libgudev polkit dbus_glib ppp libmbim libqmi ]; configureFlags = [ "--with-polkit" diff --git a/pkgs/tools/networking/network-manager/default.nix b/pkgs/tools/networking/network-manager/default.nix index cc914d6616c..30aff794baa 100644 --- a/pkgs/tools/networking/network-manager/default.nix +++ b/pkgs/tools/networking/network-manager/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchurl, intltool, wirelesstools, pkgconfig, dbus_glib, xz -, udev, libnl, libuuid, polkit, gnutls, ppp, dhcp, dhcpcd, iptables +, udev, libgudev, libnl, libuuid, polkit, gnutls, ppp, dhcp, dhcpcd, iptables , libgcrypt, dnsmasq, avahi, bind, perl, bluez5, substituteAll, readline , gobjectIntrospection, modemmanager, openresolv, libndp, newt, libsoup }: @@ -44,7 +44,7 @@ stdenv.mkDerivation rec { "--with-libsoup=yes" ]; - buildInputs = [ wirelesstools udev libnl libuuid polkit ppp libndp + buildInputs = [ wirelesstools udev libgudev libnl libuuid polkit ppp libndp xz bluez5 gobjectIntrospection modemmanager readline newt libsoup ]; propagatedBuildInputs = [ dbus_glib gnutls libgcrypt ]; -- cgit 1.4.1 From eae9889b8225a9acce42b4aa0b254ff9dca0a85c Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Tue, 4 Aug 2015 15:38:29 -0700 Subject: openssl: Major bump 1.0.1 -> 1.0.2 --- pkgs/development/libraries/openssl/1.0.2.x.nix | 84 -------------------------- pkgs/development/libraries/openssl/default.nix | 4 +- pkgs/development/web/iojs/default.nix | 4 +- pkgs/top-level/all-packages.nix | 8 --- 4 files changed, 4 insertions(+), 96 deletions(-) delete mode 100644 pkgs/development/libraries/openssl/1.0.2.x.nix (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/openssl/1.0.2.x.nix b/pkgs/development/libraries/openssl/1.0.2.x.nix deleted file mode 100644 index 28254cb390d..00000000000 --- a/pkgs/development/libraries/openssl/1.0.2.x.nix +++ /dev/null @@ -1,84 +0,0 @@ -{ stdenv, fetchurl, perl -, withCryptodev ? false, cryptodevHeaders }: - -with stdenv.lib; -let - opensslCrossSystem = attrByPath [ "openssl" "system" ] - (throw "openssl needs its platform name cross building" null) - stdenv.cross; -in -stdenv.mkDerivation rec { - name = "openssl-1.0.2d"; - - src = fetchurl { - urls = [ - "http://www.openssl.org/source/${name}.tar.gz" - "http://openssl.linux-mirror.org/source/${name}.tar.gz" - ]; - sha1 = "d01d17b44663e8ffa6a33a5a30053779d9593c3d"; - }; - - patches = optional stdenv.isCygwin ./1.0.1-cygwin64.patch; - - nativeBuildInputs = [ perl ]; - buildInputs = stdenv.lib.optional withCryptodev cryptodevHeaders; - - # On x86_64-darwin, "./config" misdetects the system as - # "darwin-i386-cc". So specify the system type explicitly. - configureScript = - if stdenv.system == "x86_64-darwin" then "./Configure darwin64-x86_64-cc" - else if stdenv.system == "x86_64-solaris" then "./Configure solaris64-x86_64-gcc" - else "./config"; - - configureFlags = [ - "shared" - "--libdir=lib" - "--openssldir=etc/ssl" - ] ++ stdenv.lib.optionals withCryptodev [ - "-DHAVE_CRYPTODEV" - "-DUSE_CRYPTODEV_DIGESTS" - ]; - - makeFlags = [ - "MANDIR=$(out)/share/man" - ]; - - # Parallel building is broken in OpenSSL. - enableParallelBuilding = false; - - postInstall = '' - # If we're building dynamic libraries, then don't install static - # libraries. - if [ -n "$(echo $out/lib/*.so $out/lib/*.dylib $out/lib/*.dll)" ]; then - rm "$out/lib/"*.a - fi - - # remove dependency on Perl at runtime - rm -r $out/etc/ssl/misc $out/bin/c_rehash - ''; - - postFixup = '' - # Check to make sure we don't depend on perl - if grep -r '${perl}' $out; then - echo "Found an erroneous dependency on perl ^^^" >&2 - exit 1 - fi - ''; - - crossAttrs = { - preConfigure='' - # It's configure does not like --build or --host - export configureFlags="${concatStringsSep " " (configureFlags ++ [ opensslCrossSystem ])}" - ''; - - configureScript = "./Configure"; - }; - - meta = { - homepage = http://www.openssl.org/; - description = "A cryptographic library that implements the SSL and TLS protocols"; - platforms = stdenv.lib.platforms.all; - maintainers = [ stdenv.lib.maintainers.simons ]; - priority = 10; # resolves collision with ‘man-pages’ - }; -} diff --git a/pkgs/development/libraries/openssl/default.nix b/pkgs/development/libraries/openssl/default.nix index ca3e7999f9b..31bd7fb2d67 100644 --- a/pkgs/development/libraries/openssl/default.nix +++ b/pkgs/development/libraries/openssl/default.nix @@ -8,14 +8,14 @@ let stdenv.cross; in stdenv.mkDerivation rec { - name = "openssl-1.0.1p"; + name = "openssl-1.0.2d"; src = fetchurl { urls = [ "http://www.openssl.org/source/${name}.tar.gz" "http://openssl.linux-mirror.org/source/${name}.tar.gz" ]; - sha1 = "9d1977cc89242cd11471269ece2ed4650947c046"; + sha256 = "671c36487785628a703374c652ad2cebea45fa920ae5681515df25d9f2c9a8c8"; }; outputs = [ "out" "man" ]; diff --git a/pkgs/development/web/iojs/default.nix b/pkgs/development/web/iojs/default.nix index 6a0c8ca512e..a44a6d6c6c4 100644 --- a/pkgs/development/web/iojs/default.nix +++ b/pkgs/development/web/iojs/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, python, utillinux, openssl_1_0_2, http-parser, zlib, libuv }: +{ stdenv, fetchurl, python, utillinux, openssl, http-parser, zlib, libuv }: let version = "3.1.0"; @@ -21,7 +21,7 @@ in stdenv.mkDerivation { # causes configure to fail, so don't add --disable-static. dontDisableStatic = true; - buildInputs = [ python openssl_1_0_2 http-parser zlib libuv ] ++ (optional stdenv.isLinux utillinux); + buildInputs = [ python openssl http-parser zlib libuv ] ++ (optional stdenv.isLinux utillinux); setupHook = ../nodejs/setup-hook.sh; passthru.interpreterName = "iojs"; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index e924feaf78e..da0a18c9ed7 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -7706,14 +7706,6 @@ let }; }; - openssl_1_0_2 = callPackage ../development/libraries/openssl/1.0.2.x.nix { - fetchurl = fetchurlBoot; - cryptodevHeaders = linuxPackages.cryptodev.override { - fetchurl = fetchurlBoot; - onlyHeaders = true; - }; - }; - openwsman = callPackage ../development/libraries/openwsman {}; ortp = callPackage ../development/libraries/ortp { }; -- cgit 1.4.1 From 3f1d497fbe331f731a3cb10632b7ebb99d489bf4 Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Thu, 20 Aug 2015 12:54:38 -0700 Subject: ncurses: 5.9 -> 6.0 --- pkgs/development/libraries/ncurses/default.nix | 24 ++++++-------- pkgs/development/libraries/ncurses/gcc-5.patch | 46 -------------------------- 2 files changed, 10 insertions(+), 60 deletions(-) delete mode 100644 pkgs/development/libraries/ncurses/gcc-5.patch (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/ncurses/default.nix b/pkgs/development/libraries/ncurses/default.nix index c505d89a6d8..046c7347f86 100644 --- a/pkgs/development/libraries/ncurses/default.nix +++ b/pkgs/development/libraries/ncurses/default.nix @@ -1,38 +1,39 @@ -{ lib, stdenv, fetchurl +{ lib, stdenv, fetchurl, pkgconfig, libtool , mouseSupport ? false , unicode ? true , gpm - -# Extra Options -, abiVersion ? "5" }: stdenv.mkDerivation rec { - name = "ncurses-5.9"; + name = "ncurses-6.0"; src = fetchurl { url = "mirror://gnu/ncurses/${name}.tar.gz"; - sha256 = "0fsn7xis81za62afan0vvm38bvgzg5wfmv1m86flqcj0nj7jjilh"; + sha256 = "0q3jck7lna77z5r42f13c4xglc7azd19pxfrjrpgp2yf615w4lgm"; }; - # gcc-5.patch should be removed after 5.9 - patches = [ ./clang.patch ./gcc-5.patch ]; + patches = [ ./clang.patch ]; configureFlags = [ "--with-shared" + "--with-cxx-shared" + "--with-libtool" "--without-debug" + "--enable-overwrite" # Needed for proper header installation "--enable-pc-files" "--enable-symlinks" ] ++ lib.optional unicode "--enable-widec"; + nativeBuildInputs = [ pkgconfig libtool ]; buildInputs = lib.optional (mouseSupport && stdenv.isLinux) gpm; preConfigure = '' configureFlagsArray+=("--includedir=$out/include") export PKG_CONFIG_LIBDIR="$out/lib/pkgconfig" mkdir -p "$PKG_CONFIG_LIBDIR" + configureFlagsArray+=("--with-pkg-config-libdir=$PKG_CONFIG_LIBDIR") '' + lib.optionalString stdenv.isCygwin '' sed -i -e 's,LIB_SUFFIX="t,LIB_SUFFIX=",' configure ''; @@ -69,7 +70,6 @@ stdenv.mkDerivation rec { for dylibtype in so dll dylib; do if [ -e "$out/lib/lib''${lib}$suffix.$dylibtype" ]; then ln -svf lib''${lib}$suffix.$dylibtype $out/lib/lib$lib$newsuffix.$dylibtype - ln -svf lib''${lib}$suffix.$dylibtype.${abiVersion} $out/lib/lib$lib$newsuffix.$dylibtype.${abiVersion} fi done for statictype in a dll.a la; do @@ -82,10 +82,6 @@ stdenv.mkDerivation rec { done ''; - preFixup = '' - rm $out/lib/*.a - ''; - meta = { description = "Free software emulation of curses in SVR4 and more"; @@ -112,6 +108,6 @@ stdenv.mkDerivation rec { passthru = { ldflags = "-lncurses"; - inherit unicode abiVersion; + inherit unicode; }; } diff --git a/pkgs/development/libraries/ncurses/gcc-5.patch b/pkgs/development/libraries/ncurses/gcc-5.patch deleted file mode 100644 index 2448229b88e..00000000000 --- a/pkgs/development/libraries/ncurses/gcc-5.patch +++ /dev/null @@ -1,46 +0,0 @@ -https://bugs.gentoo.org/545114 - -extracted from the upstream change (which had many unrelated commits in one) - -From 97bb4678dc03e753290b39bbff30ba2825df9517 Mon Sep 17 00:00:00 2001 -From: "Thomas E. Dickey" -Date: Sun, 7 Dec 2014 03:10:09 +0000 -Subject: [PATCH] ncurses 5.9 - patch 20141206 - -+ modify MKlib_gen.sh to work around change in development version of - gcc introduced here: - https://gcc.gnu.org/ml/gcc-patches/2014-06/msg02185.html - https://gcc.gnu.org/ml/gcc-patches/2014-07/msg00236.html - (reports by Marcus Shawcroft, Maohui Lei). - -diff --git a/ncurses/base/MKlib_gen.sh b/ncurses/base/MKlib_gen.sh -index d8cc3c9..b91398c 100755 ---- a/ncurses/base/MKlib_gen.sh -+++ b/ncurses/base/MKlib_gen.sh -@@ -474,11 +474,22 @@ sed -n -f $ED1 \ - -e 's/gen_$//' \ - -e 's/ / /g' >>$TMP - -+cat >$ED1 < $ED2 -+cat $ED2 >$TMP -+ - $preprocessor $TMP 2>/dev/null \ --| sed \ -- -e 's/ / /g' \ -- -e 's/^ //' \ -- -e 's/_Bool/NCURSES_BOOL/g' \ -+| sed -f $ED1 \ - | $AWK -f $AW2 \ - | sed -f $ED3 \ - | sed \ -- cgit 1.4.1 From a921167e37c19082f7cee1d20bd258fb7bc9d97e Mon Sep 17 00:00:00 2001 From: Vladimír ÄŒunát Date: Tue, 22 Sep 2015 18:44:16 +0200 Subject: pixman: bugfix update 0.32.6 -> 0.32.8, refactor It's claimed to be important on i686. http://cgit.freedesktop.org/pixman/commit/?id=8b49d4b6b460d0c92 --- pkgs/development/libraries/pixman/default.nix | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/pixman/default.nix b/pkgs/development/libraries/pixman/default.nix index ce027a0a269..30cceb59c00 100644 --- a/pkgs/development/libraries/pixman/default.nix +++ b/pkgs/development/libraries/pixman/default.nix @@ -1,26 +1,28 @@ -{ fetchurl, stdenv, pkgconfig, perl, libpng, glib /*just passthru*/ }: +{ fetchurl, stdenv, pkgconfig, libpng, glib /*just passthru*/ }: stdenv.mkDerivation rec { - name = "pixman-0.32.6"; + name = "pixman-0.32.8"; src = fetchurl { - url = "http://cairographics.org/releases/${name}.tar.gz"; - sha256 = "0129g4zdrw5hif5783li7rzcr4vpbc2cfia91azxmsk0h0xx3zix"; + url = "mirror://xorg/individual/lib/${name}.tar.bz2"; + sha1 = "5c57045622265b877c9bf02d531973eadf942140"; }; - nativeBuildInputs = [ pkgconfig perl ]; + patches = stdenv.lib.optional stdenv.isDarwin ./fix-clang36.patch; - buildInputs = [ libpng ]; # NOT in closure anyway + nativeBuildInputs = [ pkgconfig ]; + buildInputs = stdenv.lib.optional doCheck libpng; - postInstall = glib.flattenInclude; + configureFlags = stdenv.lib.optional stdenv.isArm "--disable-arm-iwmmxt"; - patches = stdenv.lib.optional stdenv.isDarwin ./fix-clang36.patch; + doCheck = true; - configureFlags = if stdenv.isArm then ["--disable-arm-iwmmxt"] else null; + postInstall = glib.flattenInclude; - meta = { + meta = with stdenv.lib; { homepage = http://pixman.org; description = "A low-level library for pixel manipulation"; - license = stdenv.lib.licenses.mit; + license = licenses.mit; + platforms = platforms.all; }; } -- cgit 1.4.1 From 283dd9fe49e754dd3c1562e3e1233d3616710bac Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Tue, 22 Sep 2015 14:29:36 -0700 Subject: wayland: 1.8.1 -> 1.9.0 --- pkgs/development/libraries/wayland/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/wayland/default.nix b/pkgs/development/libraries/wayland/default.nix index 9736d651404..0510fde811c 100644 --- a/pkgs/development/libraries/wayland/default.nix +++ b/pkgs/development/libraries/wayland/default.nix @@ -8,11 +8,11 @@ assert expat != null; stdenv.mkDerivation rec { name = "wayland-${version}"; - version = "1.8.1"; + version = "1.9.0"; src = fetchurl { url = "http://wayland.freedesktop.org/releases/${name}.tar.xz"; - sha256 = "1j3gfzn8i0xhk3j34mwb2srrscjxfyi279jhyq80mz943j6r6z7i"; + sha256 = "1yhy62vkbq8j8c9zaa6yzvn75cd99kfa8n2zfdwl80x019r711ww"; }; configureFlags = "--with-scanner --disable-documentation"; -- cgit 1.4.1 From 23f75e9bb05454d0af44fc823a19c57eafd967e3 Mon Sep 17 00:00:00 2001 From: Vladimír ÄŒunát Date: Wed, 23 Sep 2015 12:15:05 +0200 Subject: gdk-pixbuf: maintenance update 2.31.7 -> 2.32.0 --- pkgs/development/libraries/gdk-pixbuf/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/gdk-pixbuf/default.nix b/pkgs/development/libraries/gdk-pixbuf/default.nix index 754fddd101a..0971df78e66 100644 --- a/pkgs/development/libraries/gdk-pixbuf/default.nix +++ b/pkgs/development/libraries/gdk-pixbuf/default.nix @@ -2,15 +2,15 @@ , jasper, libintlOrEmpty, gobjectIntrospection, doCheck ? false }: let - ver_maj = "2.31"; - ver_min = "7"; + ver_maj = "2.32"; + ver_min = "0"; in stdenv.mkDerivation rec { name = "gdk-pixbuf-${ver_maj}.${ver_min}"; src = fetchurl { url = "mirror://gnome/sources/gdk-pixbuf/${ver_maj}/${name}.tar.xz"; - sha256 = "046n9wz16kh3rpzxaiiwphf5bihxgj4g14cjn65wwmw82q4y0dj7"; + sha256 = "0rqvj5gcs2zfyyg9llm289b0xkj4mrhzxfjpjja0wx1m6vn5axjk"; }; setupHook = ./setup-hook.sh; -- cgit 1.4.1 From 9de8f95d4bb8f0fb2bed0461a77d414857e610b3 Mon Sep 17 00:00:00 2001 From: Vladimír ÄŒunát Date: Wed, 23 Sep 2015 12:20:33 +0200 Subject: libjpeg(-turbo): maintenance update 1.4.1 -> 1.4.2 --- pkgs/development/libraries/libjpeg-turbo/default.nix | 4 ++-- pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libjpeg-turbo/default.nix b/pkgs/development/libraries/libjpeg-turbo/default.nix index 158b8825db4..3660a652e79 100644 --- a/pkgs/development/libraries/libjpeg-turbo/default.nix +++ b/pkgs/development/libraries/libjpeg-turbo/default.nix @@ -1,11 +1,11 @@ { stdenv, fetchurl, nasm }: stdenv.mkDerivation rec { - name = "libjpeg-turbo-1.4.1"; + name = "libjpeg-turbo-1.4.2"; src = fetchurl { url = "mirror://sourceforge/libjpeg-turbo/${name}.tar.gz"; - sha256 = "027vz97064bjmwj7gdw2p47y1437w08j54frpgzmnql5rvabmxab"; + sha256 = "0gi349hp1x7mb98s4mf66sb2xay2kjjxj9ihrriw0yiy0k9va6sj"; }; buildInputs = [ nasm ]; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 417011e156f..72e95ee9d97 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -7081,7 +7081,7 @@ let libjpeg_original = callPackage ../development/libraries/libjpeg { }; libjpeg_turbo = callPackage ../development/libraries/libjpeg-turbo { }; - libjpeg = if (stdenv.isLinux) then libjpeg_turbo else libjpeg_original; # some problems, both on FreeBSD and Darwin + libjpeg = if stdenv.isLinux then libjpeg_turbo else libjpeg_original; # some problems, both on FreeBSD and Darwin libjpeg62 = callPackage ../development/libraries/libjpeg/62.nix { libtool = libtool_1_5; -- cgit 1.4.1 From cd7c494bb29d171b4d05d81484ca6d63375bfd4d Mon Sep 17 00:00:00 2001 From: Vladimír ÄŒunát Date: Wed, 23 Sep 2015 12:23:45 +0200 Subject: pango: feature update 1.36.8 -> 1.38.0 Tested rebuilding the most important pango users, without any problems. --- pkgs/development/libraries/pango/default.nix | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/pango/default.nix b/pkgs/development/libraries/pango/default.nix index 87187667a92..6944b55a721 100644 --- a/pkgs/development/libraries/pango/default.nix +++ b/pkgs/development/libraries/pango/default.nix @@ -3,26 +3,26 @@ }: let - ver_maj = "1.36"; - ver_min = "8"; + ver_maj = "1.38"; + ver_min = "0"; in stdenv.mkDerivation rec { name = "pango-${ver_maj}.${ver_min}"; src = fetchurl { url = "mirror://gnome/sources/pango/${ver_maj}/${name}.tar.xz"; - sha256 = "01rdzjh68w8l5zn0648yibyarj8p6g7yfn59nw5awaz1i8dvbnqq"; + sha256 = "0v12gi7f01iq3z852pclpnmkbcksbvpcmiazmklkx1dd9fbpakhx"; }; buildInputs = with stdenv.lib; [ gobjectIntrospection ] - ++ optionals stdenv.isDarwin [ fontconfig ]; + ++ optional stdenv.isDarwin fontconfig; nativeBuildInputs = [ pkgconfig ]; propagatedBuildInputs = [ x11 glib cairo libpng fontconfig freetype harfbuzz ] ++ libintlOrEmpty; enableParallelBuilding = true; - doCheck = false; # test-layout fails on 1.36.8 + doCheck = false; # test-layout fails on 1.38.0 # jww (2014-05-05): The tests currently fail on Darwin: # # ERROR:testiter.c:139:iter_char_test: assertion failed: (extents.width == x1 - x0) @@ -31,7 +31,7 @@ stdenv.mkDerivation rec { postInstall = "rm -rf $out/share/gtk-doc"; - meta = { + meta = with stdenv.lib; { description = "A library for laying out and rendering of text, with an emphasis on internationalization"; longDescription = '' @@ -43,9 +43,9 @@ stdenv.mkDerivation rec { ''; homepage = http://www.pango.org/; - license = stdenv.lib.licenses.lgpl2Plus; + license = licenses.lgpl2Plus; - maintainers = with stdenv.lib.maintainers; [ raskin urkud ]; - hydraPlatforms = stdenv.lib.platforms.linux ++ stdenv.lib.platforms.darwin; + maintainers = with maintainers; [ raskin urkud ]; + platforms = with platforms; linux ++ darwin; }; } -- cgit 1.4.1 From ff9a70266b7f778eba504ae68928e7fd92bd0705 Mon Sep 17 00:00:00 2001 From: Vladimír ÄŒunát Date: Wed, 23 Sep 2015 12:33:46 +0200 Subject: at-spi2-*: small updates 2.16.0 -> 2.18.0 --- pkgs/development/libraries/at-spi2-atk/default.nix | 4 ++-- pkgs/development/libraries/at-spi2-core/default.nix | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/at-spi2-atk/default.nix b/pkgs/development/libraries/at-spi2-atk/default.nix index 940fc2bb6cc..84c0b5f56aa 100644 --- a/pkgs/development/libraries/at-spi2-atk/default.nix +++ b/pkgs/development/libraries/at-spi2-atk/default.nix @@ -2,14 +2,14 @@ , intltool, dbus_glib, at_spi2_core, libSM }: stdenv.mkDerivation rec { - versionMajor = "2.16"; + versionMajor = "2.18"; versionMinor = "0"; moduleName = "at-spi2-atk"; name = "${moduleName}-${versionMajor}.${versionMinor}"; src = fetchurl { url = "mirror://gnome/sources/${moduleName}/${versionMajor}/${name}.tar.xz"; - sha256 = "1y9gfz1iz3wpja7s000f0bmyyvc6im5fcdl6bxwbz0v3qdgc9vvq"; + sha256 = "0xgkrnx04vaklbkzc7bzym9s0qhj8aiz4knqlxgx3vxnacsb6vaa"; }; buildInputs = [ python pkgconfig popt atk libX11 libICE xlibs.libXtst libXi diff --git a/pkgs/development/libraries/at-spi2-core/default.nix b/pkgs/development/libraries/at-spi2-core/default.nix index 0fc28185501..b49d1ddb804 100644 --- a/pkgs/development/libraries/at-spi2-core/default.nix +++ b/pkgs/development/libraries/at-spi2-core/default.nix @@ -2,14 +2,14 @@ , libX11, xextproto, libSM, libICE, libXtst, libXi, gobjectIntrospection }: stdenv.mkDerivation rec { - versionMajor = "2.16"; + versionMajor = "2.18"; versionMinor = "0"; moduleName = "at-spi2-core"; name = "${moduleName}-${versionMajor}.${versionMinor}"; src = fetchurl { url = "mirror://gnome/sources/${moduleName}/${versionMajor}/${name}.tar.xz"; - sha256 = "1l3l39mw23zyjlcqidvkyqlr4gwbhplzw2hcv3qvn6p8ikxpf2qw"; + sha256 = "0xna0gnlqvzy6209klirywcm7ianazshg6pkk828g07bnrywgvhs"; }; outputs = [ "out" "doc" ]; -- cgit 1.4.1 From e7605dd08b460bc824b1f568c62b20a50d3fa18b Mon Sep 17 00:00:00 2001 From: Jude Taylor Date: Wed, 23 Sep 2015 16:13:29 -0700 Subject: add nodejs-4.1.0 --- pkgs/development/libraries/libuv/default.nix | 1 + pkgs/development/web/nodejs/no-xcode-4.1.0.patch | 95 ++++++++++++++++++++++++ pkgs/development/web/nodejs/v4_1_0.nix | 53 +++++++++++++ pkgs/top-level/all-packages.nix | 7 +- 4 files changed, 155 insertions(+), 1 deletion(-) create mode 100644 pkgs/development/web/nodejs/no-xcode-4.1.0.patch create mode 100644 pkgs/development/web/nodejs/v4_1_0.nix (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libuv/default.nix b/pkgs/development/libraries/libuv/default.nix index 8052f0bc731..2a35264799b 100644 --- a/pkgs/development/libraries/libuv/default.nix +++ b/pkgs/development/libraries/libuv/default.nix @@ -109,4 +109,5 @@ in mapAttrs (v: h: mkWithAutotools stable (toVersion v) h) { v1_2_0 = "1nbp8qpgw64gl9nrjzxw0ndv1m64cfms0cy5a2883vw6877kizmx"; v1_6_1 = "10w9pjbmqcv03v04rnjd8mdh886j7v4y0svdsdklz69zskgdvvqg"; + v1_7_5 = "18x6cy2xn31am97vn6jli7kmb2fbp4c8kmv7jm97vggh0x55flsc"; } diff --git a/pkgs/development/web/nodejs/no-xcode-4.1.0.patch b/pkgs/development/web/nodejs/no-xcode-4.1.0.patch new file mode 100644 index 00000000000..137158b01b7 --- /dev/null +++ b/pkgs/development/web/nodejs/no-xcode-4.1.0.patch @@ -0,0 +1,95 @@ +diff --git a/configure b/configure +index d199975..66d903b 100755 +--- a/configure ++++ b/configure +@@ -734,7 +734,7 @@ def configure_library(lib, output): + # libpath needs to be provided ahead libraries + if pkg_libpath: + output['libraries'] += ( +- filter(None, map(str.strip, pkg_cflags.split('-L')))) ++ pkg_libpath.split()) + + default_libs = getattr(options, shared_lib + '_libname') + default_libs = map('-l{0}'.format, default_libs.split(',')) +diff --git a/tools/gyp/pylib/gyp/xcode_emulation.py b/tools/gyp/pylib/gyp/xcode_emulation.py +index c002b11..fefb765 100644 +--- a/tools/gyp/pylib/gyp/xcode_emulation.py ++++ b/tools/gyp/pylib/gyp/xcode_emulation.py +@@ -446,10 +446,17 @@ class XcodeSettings(object): + + def _XcodeSdkPath(self, sdk_root): + if sdk_root not in XcodeSettings._sdk_path_cache: +- sdk_path = self._GetSdkVersionInfoItem(sdk_root, 'Path') +- XcodeSettings._sdk_path_cache[sdk_root] = sdk_path +- if sdk_root: +- XcodeSettings._sdk_root_cache[sdk_path] = sdk_root ++ try: ++ sdk_path = self._GetSdkVersionInfoItem(sdk_root, 'Path') ++ XcodeSettings._sdk_path_cache[sdk_root] = sdk_path ++ if sdk_root: ++ XcodeSettings._sdk_root_cache[sdk_path] = sdk_root ++ except: ++ # if this fails it's because xcodebuild failed, which means ++ # the user is probably on a CLT-only system, where there ++ # is no valid SDK root ++ XcodeSettings._sdk_path_cache[sdk_root] = None ++ + return XcodeSettings._sdk_path_cache[sdk_root] + + def _AppendPlatformVersionMinFlags(self, lst): +@@ -572,10 +579,12 @@ class XcodeSettings(object): + framework_root = sdk_root + else: + framework_root = '' +- config = self.spec['configurations'][self.configname] +- framework_dirs = config.get('mac_framework_dirs', []) +- for directory in framework_dirs: +- cflags.append('-F' + directory.replace('$(SDKROOT)', framework_root)) ++ ++ if 'SDKROOT' in self._Settings(): ++ config = self.spec['configurations'][self.configname] ++ framework_dirs = config.get('mac_framework_dirs', []) ++ for directory in framework_dirs: ++ cflags.append('-F' + directory.replace('$(SDKROOT)', framework_root)) + + self.configname = None + return cflags +@@ -826,10 +835,12 @@ class XcodeSettings(object): + sdk_root = self._SdkPath() + if not sdk_root: + sdk_root = '' +- config = self.spec['configurations'][self.configname] +- framework_dirs = config.get('mac_framework_dirs', []) +- for directory in framework_dirs: +- ldflags.append('-F' + directory.replace('$(SDKROOT)', sdk_root)) ++ ++ if 'SDKROOT' in self._Settings(): ++ config = self.spec['configurations'][self.configname] ++ framework_dirs = config.get('mac_framework_dirs', []) ++ for directory in framework_dirs: ++ ldflags.append('-F' + directory.replace('$(SDKROOT)', sdk_root)) + + is_extension = self._IsIosAppExtension() or self._IsIosWatchKitExtension() + if sdk_root and is_extension: +@@ -1032,7 +1043,11 @@ class XcodeSettings(object): + sdk_root = self._SdkPath(config_name) + if not sdk_root: + sdk_root = '' +- return l.replace('$(SDKROOT)', sdk_root) ++ ++ if self._SdkPath(): ++ return l.replace('$(SDKROOT)', sdk_root) ++ else: ++ return l + + def AdjustLibraries(self, libraries, config_name=None): + """Transforms entries like 'Cocoa.framework' in libraries into entries like +@@ -1248,7 +1263,7 @@ def XcodeVersion(): + if version: + version = re.match(r'(\d\.\d\.?\d*)', version).groups()[0] + else: +- raise GypError("No Xcode or CLT version detected!") ++ version = "7.0.0" + # The CLT has no build information, so we return an empty string. + version_list = [version, ''] + version = version_list[0] diff --git a/pkgs/development/web/nodejs/v4_1_0.nix b/pkgs/development/web/nodejs/v4_1_0.nix new file mode 100644 index 00000000000..de8fa5f6bd3 --- /dev/null +++ b/pkgs/development/web/nodejs/v4_1_0.nix @@ -0,0 +1,53 @@ +{ stdenv, fetchurl, openssl, python, zlib, libuv, v8, utillinux, http-parser +, pkgconfig, runCommand, which, libtool +}: + +let + version = "4.1.0"; + + deps = { + inherit openssl zlib libuv; + + # disabled system v8 because v8 3.14 no longer receives security fixes + # we fall back to nodejs' internal v8 copy which receives backports for now + # inherit v8 + } // (stdenv.lib.optionalAttrs (!stdenv.isDarwin) { + inherit http-parser; + }); + + inherit (stdenv.lib) concatMap optional optionals maintainers licenses platforms; +in stdenv.mkDerivation { + name = "nodejs-${version}"; + + src = fetchurl { + url = "http://nodejs.org/dist/v${version}/node-v${version}.tar.gz"; + sha256 = "025lqmhvl7xpx1ip97jwkz21a97sw9zb4zi3y7fgfag59vv0ac25"; + }; + + configureFlags = map (name: "--shared-${name}") (builtins.attrNames deps) ++ [ "--without-dtrace" ]; + + dontDisableStatic = true; + + prePatch = '' + patchShebangs . + ''; + + patches = stdenv.lib.optional stdenv.isDarwin ./no-xcode-4.1.0.patch; + + buildInputs = [ python which ] ++ (builtins.attrValues deps) + ++ optional stdenv.isLinux utillinux + ++ optionals stdenv.isDarwin [ openssl libtool ]; + setupHook = ./setup-hook.sh; + + enableParallelBuilding = true; + + passthru.interpreterName = "nodejs"; + + meta = { + description = "Event-driven I/O framework for the V8 JavaScript engine"; + homepage = http://nodejs.org; + license = licenses.mit; + maintainers = [ maintainers.goibhniu maintainers.havvy ]; + platforms = platforms.linux ++ platforms.darwin; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index a5f1f09c355..bccccc12bae 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -2006,6 +2006,11 @@ let ninka = callPackage ../development/tools/misc/ninka { }; + nodejs-4_1 = callPackage ../development/web/nodejs/v4_1_0.nix { + libuv = libuvVersions.v1_7_5; + openssl = openssl_1_0_2; + }; + nodejs-0_12 = callPackage ../development/web/nodejs { libuv = libuvVersions.v1_6_1; }; @@ -2019,8 +2024,8 @@ let else nodejs-0_12; + nodePackages_4_1 = recurseIntoAttrs (callPackage ./node-packages.nix { self = nodePackages_4_1; nodejs = nodejs-4_1; }); nodePackages_0_12 = callPackage ./node-packages.nix { self = nodePackages_0_12; nodejs = nodejs-0_12; }; - nodePackages_0_10 = callPackage ./node-packages.nix { self = nodePackages_0_10; nodejs = nodejs-0_10; }; nodePackages = if stdenv.system == "armv5tel-linux" then -- cgit 1.4.1 From 09d336ea5ec198663011eac93b30649fcc5f294c Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Wed, 23 Sep 2015 20:49:03 -0700 Subject: libarchive: Support lzo --- pkgs/development/libraries/libarchive/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libarchive/default.nix b/pkgs/development/libraries/libarchive/default.nix index 1ec253dccd6..837db32ea4b 100644 --- a/pkgs/development/libraries/libarchive/default.nix +++ b/pkgs/development/libraries/libarchive/default.nix @@ -1,4 +1,4 @@ -{ fetchurl, stdenv, acl, openssl, libxml2, attr, zlib, bzip2, e2fsprogs, xz +{ fetchurl, stdenv, acl, openssl, libxml2, attr, zlib, bzip2, e2fsprogs, xz, lzo , sharutils }: stdenv.mkDerivation rec { @@ -18,7 +18,7 @@ stdenv.mkDerivation rec { # ^ it's CVE-2015-2304 specific to libarchive ]; - buildInputs = [ sharutils libxml2 zlib bzip2 openssl xz ] ++ + buildInputs = [ sharutils libxml2 zlib bzip2 openssl xz lzo ] ++ stdenv.lib.optionals stdenv.isLinux [ e2fsprogs attr acl ]; preBuild = if stdenv.isCygwin then '' -- cgit 1.4.1 From 9e15068099a5b522660cbee3944a4022a436364a Mon Sep 17 00:00:00 2001 From: Robbin C Date: Mon, 21 Sep 2015 11:56:10 +0800 Subject: ctpp2: init at 2.8.3. This adds ctpp2, a high performance templating engine. --- pkgs/development/libraries/ctpp2/default.nix | 24 ++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 26 insertions(+) create mode 100644 pkgs/development/libraries/ctpp2/default.nix (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/ctpp2/default.nix b/pkgs/development/libraries/ctpp2/default.nix new file mode 100644 index 00000000000..ab5cd2beff3 --- /dev/null +++ b/pkgs/development/libraries/ctpp2/default.nix @@ -0,0 +1,24 @@ +{ stdenv, fetchurl, cmake, gcc48 }: + +stdenv.mkDerivation rec { + name = "ctpp2"; + version = "2.8.3"; + + src = fetchurl { + url = "http://ctpp.havoc.ru/download/ctpp2-${version}.tar.gz"; + sha256 = "1z22zfw9lb86z4hcan9hlvji49c9b7vznh7gjm95gnvsh43zsgx8"; + }; + + buildInputs = [ cmake gcc48 ]; + + patchPhase = '' + # include to fix undefined getcwd + sed -ie 's//\n#include /' src/CTPP2FileSourceLoader.cpp + ''; + + meta = { + description = "A high performance templating engine"; + homepage = http://ctpp.havoc.ru; + maintiainers = with stdenv.lib.maintainers; [ robbinch ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 8041eaf758f..6ca93f2c4f9 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6030,6 +6030,8 @@ let ctl = callPackage ../development/libraries/ctl { }; + ctpp2 = callPackage ../development/libraries/ctpp2 { }; + cpp-netlib = callPackage ../development/libraries/cpp-netlib { }; cppunit = callPackage ../development/libraries/cppunit { }; -- cgit 1.4.1 From b1f4a7ef3212919466dd97b087f6351c677a53ae Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 10:28:51 +0200 Subject: webkitgtk: 2.8.5 -> 2.10.0 --- pkgs/development/libraries/webkitgtk/default.nix | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/webkitgtk/default.nix b/pkgs/development/libraries/webkitgtk/default.nix index 0e67f5d3d1a..d60fbca6141 100644 --- a/pkgs/development/libraries/webkitgtk/default.nix +++ b/pkgs/development/libraries/webkitgtk/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchurl, perl, python, ruby, bison, gperf, cmake -, pkgconfig, gettext, gobjectIntrospection +, pkgconfig, gettext, gobjectIntrospection, libnotify , gtk2, gtk3, wayland, libwebp, enchant , libxml2, libsoup, libsecret, libxslt, harfbuzz, libpthreadstubs , enableGeoLocation ? true, geoclue2, sqlite @@ -11,7 +11,7 @@ assert enableGeoLocation -> geoclue2 != null; with stdenv.lib; stdenv.mkDerivation rec { name = "webkitgtk-${version}"; - version = "2.8.5"; + version = "2.10.0"; meta = { description = "Web content rendering engine, GTK+ port"; @@ -25,12 +25,12 @@ stdenv.mkDerivation rec { src = fetchurl { url = "http://webkitgtk.org/releases/${name}.tar.xz"; - sha256 = "082dw0d8jxvsapx30ypmy5h2srzfzi42c3zr9pbkzx1m959hq7rx"; + sha256 = "0vb8ca6dd9hxb5ycp54bdyykp10blbq5b6qkbak4yf9mxwi5ccj2"; }; patches = [ ./finding-harfbuzz-icu.patch ]; - cmakeFlags = [ "-DPORT=GTK" ]; + cmakeFlags = [ "-DPORT=GTK" "-DUSE_LIBHYPHEN=0" ]; # XXX: WebKit2 missing include path for gst-plugins-base. # Filled: https://bugs.webkit.org/show_bug.cgi?id=148894 @@ -42,7 +42,7 @@ stdenv.mkDerivation rec { ]; buildInputs = [ - gtk2 wayland libwebp enchant + gtk2 wayland libwebp enchant libnotify libxml2 libsecret libxslt harfbuzz libpthreadstubs gst-plugins-base ] ++ optional enableGeoLocation geoclue2; @@ -51,5 +51,5 @@ stdenv.mkDerivation rec { libsoup gtk3 ]; - enableParallelBuilding = true; # build problems on Hydra + enableParallelBuilding = true; } -- cgit 1.4.1 From 6bb4df642ec3e4f59124a49636d457dab7c33490 Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 10:29:21 +0200 Subject: glib: 2.44.1 -> 2.46.0 --- pkgs/development/libraries/glib/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/glib/default.nix b/pkgs/development/libraries/glib/default.nix index fb9c361c530..137fe943637 100644 --- a/pkgs/development/libraries/glib/default.nix +++ b/pkgs/development/libraries/glib/default.nix @@ -39,8 +39,8 @@ let ln -sr -t "$out/include/" "$out"/lib/*/include/* 2>/dev/null || true ''; - ver_maj = "2.44"; - ver_min = "1"; + ver_maj = "2.46"; + ver_min = "0"; in stdenv.mkDerivation rec { @@ -48,7 +48,7 @@ stdenv.mkDerivation rec { src = fetchurl { url = "mirror://gnome/sources/glib/${ver_maj}/${name}.tar.xz"; - sha256 = "01yabrfp64i11mrks3p1gcks99lw0zm7f5vhkc53sl4amyndw4c8"; + sha256 = "b1cee83469ae7d80f17c267c37f090414e93960bd62d2b254a5a96fbc5baacb4"; }; patches = optional stdenv.isDarwin ./darwin-compilation.patch ++ optional doCheck ./skip-timer-test.patch; -- cgit 1.4.1 From 63ccbf55b2de793246e19502166f24c407e90ddc Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 10:30:14 +0200 Subject: atk: 2.16.0 -> 2.18.0 --- pkgs/development/libraries/atk/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/atk/default.nix b/pkgs/development/libraries/atk/default.nix index d5e442c738c..dcb90aa16cd 100644 --- a/pkgs/development/libraries/atk/default.nix +++ b/pkgs/development/libraries/atk/default.nix @@ -1,7 +1,7 @@ { stdenv, fetchurl, pkgconfig, perl, glib, libintlOrEmpty, gobjectIntrospection }: let - ver_maj = "2.16"; + ver_maj = "2.18"; ver_min = "0"; in stdenv.mkDerivation rec { @@ -9,7 +9,7 @@ stdenv.mkDerivation rec { src = fetchurl { url = "mirror://gnome/sources/atk/${ver_maj}/${name}.tar.xz"; - sha256 = "0qp5i91kfk6rhrlam3s8ha0cz88lkyp89vsyn4pb5856c1h9hpq9"; + sha256 = "ce6c48d77bf951083029d5a396dd552d836fff3c1715d3a7022e917e46d0c92b"; }; buildInputs = libintlOrEmpty; -- cgit 1.4.1 From 6858ca17db98846f1e541ac28ee9d5ec98d8c789 Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 10:31:16 +0200 Subject: gobject-introspection: 1.44.0 -> 1.46.0 --- pkgs/development/libraries/gobject-introspection/default.nix | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/gobject-introspection/default.nix b/pkgs/development/libraries/gobject-introspection/default.nix index 50fddd9da9f..f429e1dc6c3 100644 --- a/pkgs/development/libraries/gobject-introspection/default.nix +++ b/pkgs/development/libraries/gobject-introspection/default.nix @@ -5,7 +5,7 @@ # In that case its about 6MB which could be separated let - ver_maj = "1.44"; + ver_maj = "1.46"; ver_min = "0"; in stdenv.mkDerivation rec { @@ -13,7 +13,7 @@ stdenv.mkDerivation rec { src = fetchurl { url = "mirror://gnome/sources/gobject-introspection/${ver_maj}/${name}.tar.xz"; - sha256 = "1b972qg2yb51sdavfvb6kc19akwc15c1bwnbg81vadxamql2q33g"; + sha256 = "6658bd3c2b8813eb3e2511ee153238d09ace9d309e4574af27443d87423e4233"; }; buildInputs = [ flex bison pkgconfig python ] @@ -25,6 +25,10 @@ stdenv.mkDerivation rec { # other dependencies). configureFlags = [ "--disable-tests" ]; + preConfigure = '' + sed 's|/usr/bin/env ||' -i tools/g-ir-tool-template.in + ''; + postInstall = "rm -rf $out/share/gtk-doc"; setupHook = ./setup-hook.sh; -- cgit 1.4.1 From 8b3e6b5f62f0a6419e782187943d11fdc417409b Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 10:31:59 +0200 Subject: at-spi2-core: 2.16.0 -> 2.18.0 --- pkgs/development/libraries/at-spi2-core/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/at-spi2-core/default.nix b/pkgs/development/libraries/at-spi2-core/default.nix index 0fc28185501..7cf29aaca86 100644 --- a/pkgs/development/libraries/at-spi2-core/default.nix +++ b/pkgs/development/libraries/at-spi2-core/default.nix @@ -2,14 +2,14 @@ , libX11, xextproto, libSM, libICE, libXtst, libXi, gobjectIntrospection }: stdenv.mkDerivation rec { - versionMajor = "2.16"; + versionMajor = "2.18"; versionMinor = "0"; moduleName = "at-spi2-core"; name = "${moduleName}-${versionMajor}.${versionMinor}"; src = fetchurl { url = "mirror://gnome/sources/${moduleName}/${versionMajor}/${name}.tar.xz"; - sha256 = "1l3l39mw23zyjlcqidvkyqlr4gwbhplzw2hcv3qvn6p8ikxpf2qw"; + sha256 = "1aeec77db6eb8087049af39a07f55756c55319f739d2998030fe6f4ced03ca76"; }; outputs = [ "out" "doc" ]; -- cgit 1.4.1 From 0688a56a49a548960e948a1ce54b80a7ea9c6fef Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 10:32:15 +0200 Subject: at-spi2-atk: 2.16.0 -> 2.18.0 --- pkgs/development/libraries/at-spi2-atk/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/at-spi2-atk/default.nix b/pkgs/development/libraries/at-spi2-atk/default.nix index 940fc2bb6cc..4a018f0b405 100644 --- a/pkgs/development/libraries/at-spi2-atk/default.nix +++ b/pkgs/development/libraries/at-spi2-atk/default.nix @@ -2,14 +2,14 @@ , intltool, dbus_glib, at_spi2_core, libSM }: stdenv.mkDerivation rec { - versionMajor = "2.16"; + versionMajor = "2.18"; versionMinor = "0"; moduleName = "at-spi2-atk"; name = "${moduleName}-${versionMajor}.${versionMinor}"; src = fetchurl { url = "mirror://gnome/sources/${moduleName}/${versionMajor}/${name}.tar.xz"; - sha256 = "1y9gfz1iz3wpja7s000f0bmyyvc6im5fcdl6bxwbz0v3qdgc9vvq"; + sha256 = "4a6db33453b6efd15fa7d84ef2a3421262a053f57f1df6e7a2536d02bacdf375"; }; buildInputs = [ python pkgconfig popt atk libX11 libICE xlibs.libXtst libXi -- cgit 1.4.1 From 4c9b91b2a27964ce34c466ead0bad5d4b7b91ed9 Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 10:32:37 +0200 Subject: gdk-pixbuf: 2.31.6 -> 2.32.0 --- pkgs/development/libraries/gdk-pixbuf/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/gdk-pixbuf/default.nix b/pkgs/development/libraries/gdk-pixbuf/default.nix index 5f5a0496954..82fe45d25e4 100644 --- a/pkgs/development/libraries/gdk-pixbuf/default.nix +++ b/pkgs/development/libraries/gdk-pixbuf/default.nix @@ -2,15 +2,15 @@ , jasper, libintlOrEmpty, gobjectIntrospection }: let - ver_maj = "2.31"; - ver_min = "6"; + ver_maj = "2.32"; + ver_min = "0"; in stdenv.mkDerivation rec { name = "gdk-pixbuf-${ver_maj}.${ver_min}"; src = fetchurl { url = "mirror://gnome/sources/gdk-pixbuf/${ver_maj}/${name}.tar.xz"; - sha256 = "062x2gqd7p6yxhxlib1ha4l3gk9ihcj080hrwwv9vmlmybb064hi"; + sha256 = "537655ec3635740e949457bafe61ae44ce0e5642a2529a9ef7ee0bcd5e911b67"; }; setupHook = ./setup-hook.sh; -- cgit 1.4.1 From 0a40884e3c589dfdeb42521076892b0d2f6180eb Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 10:32:50 +0200 Subject: pango: 1.36.8 -> 1.38.0 --- pkgs/development/libraries/pango/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/pango/default.nix b/pkgs/development/libraries/pango/default.nix index 87187667a92..12b38fd6db7 100644 --- a/pkgs/development/libraries/pango/default.nix +++ b/pkgs/development/libraries/pango/default.nix @@ -3,15 +3,15 @@ }: let - ver_maj = "1.36"; - ver_min = "8"; + ver_maj = "1.38"; + ver_min = "0"; in stdenv.mkDerivation rec { name = "pango-${ver_maj}.${ver_min}"; src = fetchurl { url = "mirror://gnome/sources/pango/${ver_maj}/${name}.tar.xz"; - sha256 = "01rdzjh68w8l5zn0648yibyarj8p6g7yfn59nw5awaz1i8dvbnqq"; + sha256 = "1d4e75974bad853ee9ac5fc5caee5e7ab235abbd945d51d01f3806e04e7c226c"; }; buildInputs = with stdenv.lib; [ gobjectIntrospection ] -- cgit 1.4.1 From 48ac26f51250c97fda720520d96505afa9dc53c8 Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 10:33:07 +0200 Subject: gtk+: 3.16.6 -> 3.18.0 --- pkgs/development/libraries/gtk+/3.x.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/gtk+/3.x.nix b/pkgs/development/libraries/gtk+/3.x.nix index 5fb70ac05ea..9bf95d015dd 100644 --- a/pkgs/development/libraries/gtk+/3.x.nix +++ b/pkgs/development/libraries/gtk+/3.x.nix @@ -9,8 +9,8 @@ assert xineramaSupport -> xlibs.libXinerama != null; assert cupsSupport -> cups != null; let - ver_maj = "3.16"; - ver_min = "6"; + ver_maj = "3.18"; + ver_min = "0"; version = "${ver_maj}.${ver_min}"; in stdenv.mkDerivation rec { @@ -18,7 +18,7 @@ stdenv.mkDerivation rec { src = fetchurl { url = "mirror://gnome/sources/gtk+/${ver_maj}/gtk+-${version}.tar.xz"; - sha256 = "1gpzlnfrifc17yfk0zki6b2vmsfpf5cmrbh232s6iaan11np44jd"; + sha256 = "7fb8ae257403317d3852bad28d064d35f67e978b1fed8b71d5997e87204271b9"; }; nativeBuildInputs = [ pkgconfig gettext gobjectIntrospection perl ]; -- cgit 1.4.1 From bb16eb8f9da042abd773a3696a05ad1981b12d62 Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 10:34:03 +0200 Subject: cogl: init 1.22.0 --- pkgs/development/libraries/cogl/1.22.nix | 56 ++++++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 58 insertions(+) create mode 100644 pkgs/development/libraries/cogl/1.22.nix (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/cogl/1.22.nix b/pkgs/development/libraries/cogl/1.22.nix new file mode 100644 index 00000000000..ce4fda5bd46 --- /dev/null +++ b/pkgs/development/libraries/cogl/1.22.nix @@ -0,0 +1,56 @@ +{ stdenv, fetchurl, pkgconfig, mesa_noglu, glib, gdk_pixbuf, xorg, libintlOrEmpty +, pangoSupport ? true, pango, cairo, gobjectIntrospection +, gstreamerSupport ? true, gst_all_1 }: + +let + ver_maj = "1.22"; + ver_min = "0"; +in +stdenv.mkDerivation rec { + name = "cogl-${ver_maj}.${ver_min}"; + + src = fetchurl { + url = "mirror://gnome/sources/cogl/${ver_maj}/${name}.tar.xz"; + sha256 = "689dfb5d14fc1106e9d2ded0f7930dcf7265d0bc84fa846b4f03941633eeaa91"; + }; + + nativeBuildInputs = [ pkgconfig ]; + + configureFlags = [ + "--enable-introspection" + "--enable-kms-egl-platform" + ] ++ stdenv.lib.optional gstreamerSupport "--enable-cogl-gst" + ++ stdenv.lib.optionals (!stdenv.isDarwin) [ "--enable-gles1" "--enable-gles2" ]; + + propagatedBuildInputs = with xorg; [ + glib gdk_pixbuf gobjectIntrospection + mesa_noglu libXrandr libXfixes libXcomposite libXdamage + ] + ++ libintlOrEmpty + ++ stdenv.lib.optionals gstreamerSupport [ gst_all_1.gstreamer + gst_all_1.gst-plugins-base ]; + + buildInputs = stdenv.lib.optionals pangoSupport [ pango cairo ]; + + COGL_PANGO_DEP_CFLAGS + = stdenv.lib.optionalString (stdenv.isDarwin && pangoSupport) + "-I${pango}/include/pango-1.0 -I${cairo}/include/cairo"; + + NIX_LDFLAGS = stdenv.lib.optionalString stdenv.isDarwin "-lintl"; + + #doCheck = true; # all tests fail (no idea why) + + meta = with stdenv.lib; { + description = "A small open source library for using 3D graphics hardware for rendering"; + maintainers = with maintainers; [ lovek323 ]; + + longDescription = '' + Cogl is a small open source library for using 3D graphics hardware for + rendering. The API departs from the flat state machine style of OpenGL + and is designed to make it easy to write orthogonal components that can + render without stepping on each other's toes. + ''; + + platforms = stdenv.lib.platforms.mesaPlatforms; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 4891ec8d4ba..1eb556515b7 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6018,6 +6018,8 @@ let cogl_1_20 = callPackage ../development/libraries/cogl/1.20.nix { }; + cogl_1_22 = callPackage ../development/libraries/cogl/1.22.nix { }; + coin3d = callPackage ../development/libraries/coin3d { }; CoinMP = callPackage ../development/libraries/CoinMP { }; -- cgit 1.4.1 From 41fc49ed7e94d9a0aef044a6ea34c142e376d3f7 Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 10:34:25 +0200 Subject: clutter: init 1.24.0 --- pkgs/development/libraries/clutter/1.24.nix | 52 +++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 4 +++ 2 files changed, 56 insertions(+) create mode 100644 pkgs/development/libraries/clutter/1.24.nix (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/clutter/1.24.nix b/pkgs/development/libraries/clutter/1.24.nix new file mode 100644 index 00000000000..b9d45b6c62b --- /dev/null +++ b/pkgs/development/libraries/clutter/1.24.nix @@ -0,0 +1,52 @@ +{ stdenv, fetchurl, glib, pkgconfig, mesa, libX11, libXext, libXfixes +, libXdamage, libXcomposite, libXi, cogl, pango, atk, json_glib, +gobjectIntrospection +}: + +let + ver_maj = "1.24"; + ver_min = "0"; +in +stdenv.mkDerivation rec { + name = "clutter-${ver_maj}.${ver_min}"; + + src = fetchurl { + url = "mirror://gnome/sources/clutter/${ver_maj}/${name}.tar.xz"; + sha256 = "85c87d5745b97af7633776419a47421aae7cea66c1b870f88cc5e06a4c5626e6"; + }; + + nativeBuildInputs = [ pkgconfig ]; + propagatedBuildInputs = + [ libX11 mesa libXext libXfixes libXdamage libXcomposite libXi cogl pango + atk json_glib gobjectIntrospection + ]; + + configureFlags = [ "--enable-introspection" ]; # needed by muffin AFAIK + + #doCheck = true; # no tests possible without a display + + meta = { + description = "Clutter, a library for creating fast, dynamic graphical user interfaces"; + + longDescription = + '' Clutter is free software library for creating fast, compelling, + portable, and dynamic graphical user interfaces. It is a core part + of MeeGo, and is supported by the open source community. Its + development is sponsored by Intel. + + Clutter uses OpenGL for rendering (and optionally OpenGL|ES for use + on mobile and embedded platforms), but wraps an easy to use, + efficient, flexible API around GL's complexity. + + Clutter enforces no particular user interface style, but provides a + rich, generic foundation for higher-level toolkits tailored to + specific needs. + ''; + + license = stdenv.lib.licenses.lgpl2Plus; + homepage = http://www.clutter-project.org/; + + maintainers = with stdenv.lib.maintainers; [ urkud lethalman ]; + platforms = stdenv.lib.platforms.mesaPlatforms; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 1eb556515b7..56fadb5ce10 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6000,6 +6000,10 @@ let cogl = cogl_1_20; }; + clutter_1_24 = callPackage ../development/libraries/clutter/1.24.nix { + cogl = cogl_1_22; + }; + clutter-gst = callPackage ../development/libraries/clutter-gst { }; clutter-gst_3_0 = callPackage ../development/libraries/clutter-gst/3.0.nix { -- cgit 1.4.1 From e43d3b711400c43b6366e896a5186bc90287f256 Mon Sep 17 00:00:00 2001 From: Jude Taylor Date: Fri, 25 Sep 2015 02:33:21 -0700 Subject: fix faulty include in libpsl --- pkgs/development/libraries/libpsl/default.nix | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libpsl/default.nix b/pkgs/development/libraries/libpsl/default.nix index 58de331c0c5..7d4d4503c54 100644 --- a/pkgs/development/libraries/libpsl/default.nix +++ b/pkgs/development/libraries/libpsl/default.nix @@ -28,6 +28,10 @@ in stdenv.mkDerivation { buildInputs = [ icu libxslt ]; nativeBuildInputs = [ autoreconfHook docbook_xsl gtk_doc pkgconfig ]; + postPatch = '' + substituteInPlace src/psl.c --replace bits/stat.h sys/stat.h + ''; + preAutoreconf = '' mkdir m4 gtkdocize -- cgit 1.4.1 From 72aa4582851271e027453d5caf932b6acebc4414 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Fri, 25 Sep 2015 11:38:26 +0200 Subject: Revert "pcre: Fix patch method" This reverts commit fb30776a77122b687fd5f758672311dbcbd81cc2. --- pkgs/development/libraries/pcre/default.nix | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/pcre/default.nix b/pkgs/development/libraries/pcre/default.nix index f32af2a0e1e..5a55db53348 100644 --- a/pkgs/development/libraries/pcre/default.nix +++ b/pkgs/development/libraries/pcre/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, autoreconfHook, unicodeSupport ? true, cplusplusSupport ? true +{ stdenv, fetchurl, unicodeSupport ? true, cplusplusSupport ? true , windows ? null }: @@ -12,12 +12,8 @@ stdenv.mkDerivation rec { sha256 = "17bqykp604p7376wj3q2nmjdhrb6v1ny8q08zdwi7qvc02l9wrsi"; }; - nativeBuildInputs = [ autoreconfHook ]; - # A bundle of fixes which should be removed for 8.38 - patchPhase = '' - patch -p0 -i ${./fixes.patch} - ''; + patches = [ ./fixes.patch ]; outputs = [ "out" "doc" "man" ]; -- cgit 1.4.1 From 298ec05e74f1e375e3929a1442e3473b384ad77b Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Fri, 25 Sep 2015 11:38:34 +0200 Subject: Revert "pcre: Updates to fix a number of vulnerabilities" This reverts commit 453b986d2f1061dd04f7a2f198c4e5276ddc8d8f. Such large patches should not be included in the repo. --- pkgs/development/libraries/pcre/default.nix | 3 - pkgs/development/libraries/pcre/fixes.patch | 3538 --------------------------- 2 files changed, 3541 deletions(-) delete mode 100644 pkgs/development/libraries/pcre/fixes.patch (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/pcre/default.nix b/pkgs/development/libraries/pcre/default.nix index 5a55db53348..a34f3e5e132 100644 --- a/pkgs/development/libraries/pcre/default.nix +++ b/pkgs/development/libraries/pcre/default.nix @@ -12,9 +12,6 @@ stdenv.mkDerivation rec { sha256 = "17bqykp604p7376wj3q2nmjdhrb6v1ny8q08zdwi7qvc02l9wrsi"; }; - # A bundle of fixes which should be removed for 8.38 - patches = [ ./fixes.patch ]; - outputs = [ "out" "doc" "man" ]; configureFlags = '' diff --git a/pkgs/development/libraries/pcre/fixes.patch b/pkgs/development/libraries/pcre/fixes.patch deleted file mode 100644 index 3b39128d7e4..00000000000 --- a/pkgs/development/libraries/pcre/fixes.patch +++ /dev/null @@ -1,3538 +0,0 @@ -Index: pcre_jit_compile.c -=================================================================== ---- pcre_jit_compile.c (revision 1554) -+++ pcre_jit_compile.c (working copy) -@@ -1064,6 +1064,7 @@ - pcre_uchar *end = NULL; - int private_data_ptr = *private_data_start; - int space, size, bracketlen; -+BOOL repeat_check = TRUE; - - while (cc < ccend) - { -@@ -1071,9 +1072,10 @@ - size = 0; - bracketlen = 0; - if (private_data_ptr > SLJIT_MAX_LOCAL_SIZE) -- return; -+ break; - -- if (*cc == OP_ONCE || *cc == OP_ONCE_NC || *cc == OP_BRA || *cc == OP_CBRA || *cc == OP_COND) -+ if (repeat_check && (*cc == OP_ONCE || *cc == OP_ONCE_NC || *cc == OP_BRA || *cc == OP_CBRA || *cc == OP_COND)) -+ { - if (detect_repeat(common, cc)) - { - /* These brackets are converted to repeats, so no global -@@ -1081,6 +1083,8 @@ - if (cc >= end) - end = bracketend(cc); - } -+ } -+ repeat_check = TRUE; - - switch(*cc) - { -@@ -1136,6 +1140,13 @@ - bracketlen = 1 + LINK_SIZE + IMM2_SIZE; - break; - -+ case OP_BRAZERO: -+ case OP_BRAMINZERO: -+ case OP_BRAPOSZERO: -+ repeat_check = FALSE; -+ size = 1; -+ break; -+ - CASE_ITERATOR_PRIVATE_DATA_1 - space = 1; - size = -2; -@@ -1162,12 +1173,17 @@ - size = 1; - break; - -- CASE_ITERATOR_TYPE_PRIVATE_DATA_2B -+ case OP_TYPEUPTO: - if (cc[1 + IMM2_SIZE] != OP_ANYNL && cc[1 + IMM2_SIZE] != OP_EXTUNI) - space = 2; - size = 1 + IMM2_SIZE; - break; - -+ case OP_TYPEMINUPTO: -+ space = 2; -+ size = 1 + IMM2_SIZE; -+ break; -+ - case OP_CLASS: - case OP_NCLASS: - size += 1 + 32 / sizeof(pcre_uchar); -@@ -1316,6 +1332,13 @@ - cc += 1 + LINK_SIZE + IMM2_SIZE; - break; - -+ case OP_THEN: -+ stack_restore = TRUE; -+ if (common->control_head_ptr != 0) -+ *needs_control_head = TRUE; -+ cc ++; -+ break; -+ - default: - stack_restore = TRUE; - /* Fall through. */ -@@ -2220,6 +2243,7 @@ - SLJIT_ASSERT_STOP(); - break; - } -+ SLJIT_ASSERT(current > (sljit_sw*)current[-1]); - current = (sljit_sw*)current[-1]; - } - return -1; -@@ -3209,7 +3233,7 @@ - bytes[0] = len; - } - --static int scan_prefix(compiler_common *common, pcre_uchar *cc, pcre_uint32 *chars, pcre_uint8 *bytes, int max_chars) -+static int scan_prefix(compiler_common *common, pcre_uchar *cc, pcre_uint32 *chars, pcre_uint8 *bytes, int max_chars, pcre_uint32 *rec_count) - { - /* Recursive function, which scans prefix literals. */ - BOOL last, any, caseless; -@@ -3227,9 +3251,14 @@ - repeat = 1; - while (TRUE) - { -+ if (*rec_count == 0) -+ return 0; -+ (*rec_count)--; -+ - last = TRUE; - any = FALSE; - caseless = FALSE; -+ - switch (*cc) - { - case OP_CHARI: -@@ -3291,7 +3320,7 @@ - #ifdef SUPPORT_UTF - if (common->utf && HAS_EXTRALEN(*cc)) len += GET_EXTRALEN(*cc); - #endif -- max_chars = scan_prefix(common, cc + len, chars, bytes, max_chars); -+ max_chars = scan_prefix(common, cc + len, chars, bytes, max_chars, rec_count); - if (max_chars == 0) - return consumed; - last = FALSE; -@@ -3314,7 +3343,7 @@ - alternative = cc + GET(cc, 1); - while (*alternative == OP_ALT) - { -- max_chars = scan_prefix(common, alternative + 1 + LINK_SIZE, chars, bytes, max_chars); -+ max_chars = scan_prefix(common, alternative + 1 + LINK_SIZE, chars, bytes, max_chars, rec_count); - if (max_chars == 0) - return consumed; - alternative += GET(alternative, 1); -@@ -3556,6 +3585,7 @@ - int range_right = -1, range_len = 3 - 1; - sljit_ub *update_table = NULL; - BOOL in_range; -+pcre_uint32 rec_count; - - for (i = 0; i < MAX_N_CHARS; i++) - { -@@ -3564,7 +3594,8 @@ - bytes[i * MAX_N_BYTES] = 0; - } - --max = scan_prefix(common, common->start, chars, bytes, MAX_N_CHARS); -+rec_count = 10000; -+max = scan_prefix(common, common->start, chars, bytes, MAX_N_CHARS, &rec_count); - - if (max <= 1) - return FALSE; -@@ -4311,8 +4342,10 @@ - case 4: - if ((ranges[1] - ranges[0]) == (ranges[3] - ranges[2]) - && (ranges[0] | (ranges[2] - ranges[0])) == ranges[2] -+ && (ranges[1] & (ranges[2] - ranges[0])) == 0 - && is_powerof2(ranges[2] - ranges[0])) - { -+ SLJIT_ASSERT((ranges[0] & (ranges[2] - ranges[0])) == 0 && (ranges[2] & ranges[3] & (ranges[2] - ranges[0])) != 0); - OP2(SLJIT_OR, TMP1, 0, TMP1, 0, SLJIT_IMM, ranges[2] - ranges[0]); - if (ranges[2] + 1 != ranges[3]) - { -@@ -4900,9 +4933,10 @@ - if (!check_class_ranges(common, (const pcre_uint8 *)cc, FALSE, TRUE, list)) - { - #ifdef COMPILE_PCRE8 -- SLJIT_ASSERT(common->utf); -+ jump = NULL; -+ if (common->utf) - #endif -- jump = CMP(SLJIT_GREATER, TMP1, 0, SLJIT_IMM, 255); -+ jump = CMP(SLJIT_GREATER, TMP1, 0, SLJIT_IMM, 255); - - OP2(SLJIT_AND, TMP2, 0, TMP1, 0, SLJIT_IMM, 0x7); - OP2(SLJIT_LSHR, TMP1, 0, TMP1, 0, SLJIT_IMM, 3); -@@ -4911,7 +4945,10 @@ - OP2(SLJIT_AND | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, TMP2, 0); - add_jump(compiler, list, JUMP(SLJIT_NOT_ZERO)); - -- JUMPHERE(jump); -+#ifdef COMPILE_PCRE8 -+ if (common->utf) -+#endif -+ JUMPHERE(jump); - } - - OP1(SLJIT_MOV, TMP1, 0, TMP3, 0); -@@ -7665,6 +7702,10 @@ - OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0); - } - -+ /* Even if the match is empty, we need to reset the control head. */ -+ if (needs_control_head) -+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_SP), common->control_head_ptr, SLJIT_MEM1(STACK_TOP), STACK(stack)); -+ - if (opcode == OP_SBRAPOS || opcode == OP_SCBRAPOS) - add_jump(compiler, &emptymatch, CMP(SLJIT_EQUAL, TMP1, 0, STR_PTR, 0)); - -@@ -7692,6 +7733,10 @@ - OP1(SLJIT_MOV, SLJIT_MEM1(TMP2), (framesize + 1) * sizeof(sljit_sw), STR_PTR, 0); - } - -+ /* Even if the match is empty, we need to reset the control head. */ -+ if (needs_control_head) -+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_SP), common->control_head_ptr, SLJIT_MEM1(STACK_TOP), STACK(stack)); -+ - if (opcode == OP_SBRAPOS || opcode == OP_SCBRAPOS) - add_jump(compiler, &emptymatch, CMP(SLJIT_EQUAL, TMP1, 0, STR_PTR, 0)); - -@@ -7704,9 +7749,6 @@ - } - } - -- if (needs_control_head) -- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_SP), common->control_head_ptr, SLJIT_MEM1(STACK_TOP), STACK(stack)); -- - JUMPTO(SLJIT_JUMP, loop); - flush_stubs(common); - -@@ -8441,8 +8483,7 @@ - OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), STR_PTR, 0); - } - BACKTRACK_AS(braminzero_backtrack)->matchingpath = LABEL(); -- if (cc[1] > OP_ASSERTBACK_NOT) -- count_match(common); -+ count_match(common); - break; - - case OP_ONCE: -@@ -9624,7 +9665,7 @@ - DEFINE_COMPILER; - pcre_uchar *cc = common->start + common->currententry->start; - pcre_uchar *ccbegin = cc + 1 + LINK_SIZE + (*cc == OP_BRA ? 0 : IMM2_SIZE); --pcre_uchar *ccend = bracketend(cc); -+pcre_uchar *ccend = bracketend(cc) - (1 + LINK_SIZE); - BOOL needs_control_head; - int framesize = get_framesize(common, cc, NULL, TRUE, &needs_control_head); - int private_data_size = get_private_data_copy_length(common, ccbegin, ccend, needs_control_head); -@@ -9648,6 +9689,7 @@ - - sljit_emit_fast_enter(compiler, TMP2, 0); - allocate_stack(common, private_data_size + framesize + alternativesize); -+count_match(common); - OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(private_data_size + framesize + alternativesize - 1), TMP2, 0); - copy_private_data(common, ccbegin, ccend, TRUE, private_data_size + framesize + alternativesize, framesize + alternativesize, needs_control_head); - if (needs_control_head) -@@ -9992,6 +10034,7 @@ - OP1(SLJIT_MOV_UI, TMP1, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, limit_match)); - OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(TMP2), SLJIT_OFFSETOF(struct sljit_stack, base)); - OP1(SLJIT_MOV, STACK_LIMIT, 0, SLJIT_MEM1(TMP2), SLJIT_OFFSETOF(struct sljit_stack, limit)); -+OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 1); - OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_SP), LIMIT_MATCH, TMP1, 0); - - if (mode == JIT_PARTIAL_SOFT_COMPILE) -Index: RunGrepTest -=================================================================== ---- RunGrepTest (revision 1554) -+++ RunGrepTest (working copy) -@@ -512,6 +512,14 @@ - (cd $srcdir; $valgrind $pcregrep --line-offsets '(?<=\Ka)' $builddir/testtemp1grep) >>testtrygrep 2>&1 - echo "RC=$?" >>testtrygrep - -+echo "---------------------------- Test 108 ------------------------------" >>testtrygrep -+(cd $srcdir; $valgrind $pcregrep -lq PATTERN ./testdata/grepinput ./testdata/grepinputx) >>testtrygrep -+echo "RC=$?" >>testtrygrep -+ -+echo "---------------------------- Test 109 -----------------------------" >>testtrygrep -+(cd $srcdir; $valgrind $pcregrep -cq lazy ./testdata/grepinput*) >>testtrygrep -+echo "RC=$?" >>testtrygrep -+ - # Now compare the results. - - $cf $srcdir/testdata/grepoutput testtrygrep -Index: pcre_compile.c -=================================================================== ---- pcre_compile.c (revision 1554) -+++ pcre_compile.c (working copy) -@@ -174,7 +174,7 @@ - -ESC_Z, CHAR_LEFT_SQUARE_BRACKET, - CHAR_BACKSLASH, CHAR_RIGHT_SQUARE_BRACKET, - CHAR_CIRCUMFLEX_ACCENT, CHAR_UNDERSCORE, -- CHAR_GRAVE_ACCENT, 7, -+ CHAR_GRAVE_ACCENT, ESC_a, - -ESC_b, 0, - -ESC_d, ESC_e, - ESC_f, 0, -@@ -202,9 +202,9 @@ - /* 68 */ 0, 0, '|', ',', '%', '_', '>', '?', - /* 70 */ 0, 0, 0, 0, 0, 0, 0, 0, - /* 78 */ 0, '`', ':', '#', '@', '\'', '=', '"', --/* 80 */ 0, 7, -ESC_b, 0, -ESC_d, ESC_e, ESC_f, 0, -+/* 80 */ 0, ESC_a, -ESC_b, 0, -ESC_d, ESC_e, ESC_f, 0, - /* 88 */-ESC_h, 0, 0, '{', 0, 0, 0, 0, --/* 90 */ 0, 0, -ESC_k, 'l', 0, ESC_n, 0, -ESC_p, -+/* 90 */ 0, 0, -ESC_k, 0, 0, ESC_n, 0, -ESC_p, - /* 98 */ 0, ESC_r, 0, '}', 0, 0, 0, 0, - /* A0 */ 0, '~', -ESC_s, ESC_tee, 0,-ESC_v, -ESC_w, 0, - /* A8 */ 0,-ESC_z, 0, 0, 0, '[', 0, 0, -@@ -219,6 +219,12 @@ - /* F0 */ 0, 0, 0, 0, 0, 0, 0, 0, - /* F8 */ 0, 0, 0, 0, 0, 0, 0, 0 - }; -+ -+/* We also need a table of characters that may follow \c in an EBCDIC -+environment for characters 0-31. */ -+ -+static unsigned char ebcdic_escape_c[] = "@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_"; -+ - #endif - - -@@ -458,7 +464,7 @@ - "range out of order in character class\0" - "nothing to repeat\0" - /* 10 */ -- "operand of unlimited repeat could match the empty string\0" /** DEAD **/ -+ "internal error: invalid forward reference offset\0" - "internal error: unexpected repeat\0" - "unrecognized character after (? or (?-\0" - "POSIX named classes are supported only within a class\0" -@@ -527,7 +533,11 @@ - "different names for subpatterns of the same number are not allowed\0" - "(*MARK) must have an argument\0" - "this version of PCRE is not compiled with Unicode property support\0" -+#ifndef EBCDIC - "\\c must be followed by an ASCII character\0" -+#else -+ "\\c must be followed by a letter or one of [\\]^_?\0" -+#endif - "\\k is not followed by a braced, angle-bracketed, or quoted name\0" - /* 70 */ - "internal error: unknown opcode in find_fixedlength()\0" -@@ -1425,7 +1435,16 @@ - c ^= 0x40; - #else /* EBCDIC coding */ - if (c >= CHAR_a && c <= CHAR_z) c += 64; -- c ^= 0xC0; -+ if (c == CHAR_QUESTION_MARK) -+ c = ('\\' == 188 && '`' == 74)? 0x5f : 0xff; -+ else -+ { -+ for (i = 0; i < 32; i++) -+ { -+ if (c == ebcdic_escape_c[i]) break; -+ } -+ if (i < 32) c = i; else *errorcodeptr = ERR68; -+ } - #endif - break; - -@@ -1799,7 +1818,7 @@ - case OP_ASSERTBACK: - case OP_ASSERTBACK_NOT: - do cc += GET(cc, 1); while (*cc == OP_ALT); -- cc += PRIV(OP_lengths)[*cc]; -+ cc += 1 + LINK_SIZE; - break; - - /* Skip over things that don't match chars */ -@@ -2487,7 +2506,7 @@ - if (c == OP_BRA || c == OP_BRAPOS || - c == OP_CBRA || c == OP_CBRAPOS || - c == OP_ONCE || c == OP_ONCE_NC || -- c == OP_COND) -+ c == OP_COND || c == OP_SCOND) - { - BOOL empty_branch; - if (GET(code, 1) == 0) return TRUE; /* Hit unclosed bracket */ -@@ -3886,11 +3905,11 @@ - The problem in trying to be exactly like Perl is in the handling of escapes. We - have to be sure that [abc[:x\]pqr] is *not* treated as containing a POSIX - class, but [abc[:x\]pqr:]] is (so that an error can be generated). The code --below handles the special case of \], but does not try to do any other escape --processing. This makes it different from Perl for cases such as [:l\ower:] --where Perl recognizes it as the POSIX class "lower" but PCRE does not recognize --"l\ower". This is a lesser evil than not diagnosing bad classes when Perl does, --I think. -+below handles the special cases \\ and \], but does not try to do any other -+escape processing. This makes it different from Perl for cases such as -+[:l\ower:] where Perl recognizes it as the POSIX class "lower" but PCRE does -+not recognize "l\ower". This is a lesser evil than not diagnosing bad classes -+when Perl does, I think. - - A user pointed out that PCRE was rejecting [:a[:digit:]] whereas Perl was not. - It seems that the appearance of a nested POSIX class supersedes an apparent -@@ -3917,21 +3936,16 @@ - terminator = *(++ptr); /* compiler warns about "non-constant" initializer. */ - for (++ptr; *ptr != CHAR_NULL; ptr++) - { -- if (*ptr == CHAR_BACKSLASH && ptr[1] == CHAR_RIGHT_SQUARE_BRACKET) -+ if (*ptr == CHAR_BACKSLASH && -+ (ptr[1] == CHAR_RIGHT_SQUARE_BRACKET || -+ ptr[1] == CHAR_BACKSLASH)) - ptr++; -- else if (*ptr == CHAR_RIGHT_SQUARE_BRACKET) return FALSE; -- else -+ else if ((*ptr == CHAR_LEFT_SQUARE_BRACKET && ptr[1] == terminator) || -+ *ptr == CHAR_RIGHT_SQUARE_BRACKET) return FALSE; -+ else if (*ptr == terminator && ptr[1] == CHAR_RIGHT_SQUARE_BRACKET) - { -- if (*ptr == terminator && ptr[1] == CHAR_RIGHT_SQUARE_BRACKET) -- { -- *endptr = ptr; -- return TRUE; -- } -- if (*ptr == CHAR_LEFT_SQUARE_BRACKET && -- (ptr[1] == CHAR_COLON || ptr[1] == CHAR_DOT || -- ptr[1] == CHAR_EQUALS_SIGN) && -- check_posix_syntax(ptr, endptr)) -- return FALSE; -+ *endptr = ptr; -+ return TRUE; - } - } - return FALSE; -@@ -3985,11 +3999,12 @@ - is called, the partially compiled regex must be temporarily terminated with - OP_END. - --This function has been extended with the possibility of forward references for --recursions and subroutine calls. It must also check the list of such references --for the group we are dealing with. If it finds that one of the recursions in --the current group is on this list, it adjusts the offset in the list, not the --value in the reference (which is a group number). -+This function has been extended to cope with forward references for recursions -+and subroutine calls. It must check the list of such references for the -+group we are dealing with. If it finds that one of the recursions in the -+current group is on this list, it does not adjust the value in the reference -+(which is a group number). After the group has been scanned, all the offsets in -+the forward reference list for the group are adjusted. - - Arguments: - group points to the start of the group -@@ -4005,29 +4020,21 @@ - adjust_recurse(pcre_uchar *group, int adjust, BOOL utf, compile_data *cd, - size_t save_hwm_offset) - { -+int offset; -+pcre_uchar *hc; - pcre_uchar *ptr = group; - - while ((ptr = (pcre_uchar *)find_recurse(ptr, utf)) != NULL) - { -- int offset; -- pcre_uchar *hc; -- -- /* See if this recursion is on the forward reference list. If so, adjust the -- reference. */ -- - for (hc = (pcre_uchar *)cd->start_workspace + save_hwm_offset; hc < cd->hwm; - hc += LINK_SIZE) - { - offset = (int)GET(hc, 0); -- if (cd->start_code + offset == ptr + 1) -- { -- PUT(hc, 0, offset + adjust); -- break; -- } -+ if (cd->start_code + offset == ptr + 1) break; - } - -- /* Otherwise, adjust the recursion offset if it's after the start of this -- group. */ -+ /* If we have not found this recursion on the forward reference list, adjust -+ the recursion's offset if it's after the start of this group. */ - - if (hc >= cd->hwm) - { -@@ -4037,6 +4044,15 @@ - - ptr += 1 + LINK_SIZE; - } -+ -+/* Now adjust all forward reference offsets for the group. */ -+ -+for (hc = (pcre_uchar *)cd->start_workspace + save_hwm_offset; hc < cd->hwm; -+ hc += LINK_SIZE) -+ { -+ offset = (int)GET(hc, 0); -+ PUT(hc, 0, offset + adjust); -+ } - } - - -@@ -4465,7 +4481,7 @@ - const pcre_uchar *nestptr = NULL; - pcre_uchar *previous = NULL; - pcre_uchar *previous_callout = NULL; --size_t save_hwm_offset = 0; -+size_t item_hwm_offset = 0; - pcre_uint8 classbits[32]; - - /* We can fish out the UTF-8 setting once and for all into a BOOL, but we -@@ -4623,8 +4639,7 @@ - /* In the real compile phase, just check the workspace used by the forward - reference list. */ - -- else if (cd->hwm > cd->start_workspace + cd->workspace_size - -- WORK_SIZE_SAFETY_MARGIN) -+ else if (cd->hwm > cd->start_workspace + cd->workspace_size) - { - *errorcodeptr = ERR52; - goto FAILED; -@@ -4767,6 +4782,7 @@ - zeroreqchar = reqchar; - zeroreqcharflags = reqcharflags; - previous = code; -+ item_hwm_offset = cd->hwm - cd->start_workspace; - *code++ = ((options & PCRE_DOTALL) != 0)? OP_ALLANY: OP_ANY; - break; - -@@ -4818,6 +4834,7 @@ - /* Handle a real character class. */ - - previous = code; -+ item_hwm_offset = cd->hwm - cd->start_workspace; - - /* PCRE supports POSIX class stuff inside a class. Perl gives an error if - they are encountered at the top level, so we'll do that too. */ -@@ -5195,9 +5212,9 @@ - cd, PRIV(vspace_list)); - continue; - --#ifdef SUPPORT_UCP - case ESC_p: - case ESC_P: -+#ifdef SUPPORT_UCP - { - BOOL negated; - unsigned int ptype = 0, pdata = 0; -@@ -5211,6 +5228,9 @@ - class_has_8bitchar--; /* Undo! */ - continue; - } -+#else -+ *errorcodeptr = ERR45; -+ goto FAILED; - #endif - /* Unrecognized escapes are faulted if PCRE is running in its - strict mode. By default, for compatibility with Perl, they are -@@ -5930,7 +5950,7 @@ - { - register int i; - int len = (int)(code - previous); -- size_t base_hwm_offset = save_hwm_offset; -+ size_t base_hwm_offset = item_hwm_offset; - pcre_uchar *bralink = NULL; - pcre_uchar *brazeroptr = NULL; - -@@ -5985,7 +6005,7 @@ - if (repeat_max <= 1) /* Covers 0, 1, and unlimited */ - { - *code = OP_END; -- adjust_recurse(previous, 1, utf, cd, save_hwm_offset); -+ adjust_recurse(previous, 1, utf, cd, item_hwm_offset); - memmove(previous + 1, previous, IN_UCHARS(len)); - code++; - if (repeat_max == 0) -@@ -6009,7 +6029,7 @@ - { - int offset; - *code = OP_END; -- adjust_recurse(previous, 2 + LINK_SIZE, utf, cd, save_hwm_offset); -+ adjust_recurse(previous, 2 + LINK_SIZE, utf, cd, item_hwm_offset); - memmove(previous + 2 + LINK_SIZE, previous, IN_UCHARS(len)); - code += 2 + LINK_SIZE; - *previous++ = OP_BRAZERO + repeat_type; -@@ -6254,6 +6274,12 @@ - while (*scode == OP_ALT); - } - -+ /* A conditional group with only one branch has an implicit empty -+ alternative branch. */ -+ -+ if (*bracode == OP_COND && bracode[GET(bracode,1)] != OP_ALT) -+ *bracode = OP_SCOND; -+ - /* Handle possessive quantifiers. */ - - if (possessive_quantifier) -@@ -6267,11 +6293,11 @@ - { - int nlen = (int)(code - bracode); - *code = OP_END; -- adjust_recurse(bracode, 1 + LINK_SIZE, utf, cd, save_hwm_offset); -+ adjust_recurse(bracode, 1 + LINK_SIZE, utf, cd, item_hwm_offset); - memmove(bracode + 1 + LINK_SIZE, bracode, IN_UCHARS(nlen)); - code += 1 + LINK_SIZE; - nlen += 1 + LINK_SIZE; -- *bracode = OP_BRAPOS; -+ *bracode = (*bracode == OP_COND)? OP_BRAPOS : OP_SBRAPOS; - *code++ = OP_KETRPOS; - PUTINC(code, 0, nlen); - PUT(bracode, 1, nlen); -@@ -6401,7 +6427,7 @@ - else - { - *code = OP_END; -- adjust_recurse(tempcode, 1 + LINK_SIZE, utf, cd, save_hwm_offset); -+ adjust_recurse(tempcode, 1 + LINK_SIZE, utf, cd, item_hwm_offset); - memmove(tempcode + 1 + LINK_SIZE, tempcode, IN_UCHARS(len)); - code += 1 + LINK_SIZE; - len += 1 + LINK_SIZE; -@@ -6450,7 +6476,7 @@ - - default: - *code = OP_END; -- adjust_recurse(tempcode, 1 + LINK_SIZE, utf, cd, save_hwm_offset); -+ adjust_recurse(tempcode, 1 + LINK_SIZE, utf, cd, item_hwm_offset); - memmove(tempcode + 1 + LINK_SIZE, tempcode, IN_UCHARS(len)); - code += 1 + LINK_SIZE; - len += 1 + LINK_SIZE; -@@ -6623,7 +6649,7 @@ - newoptions = options; - skipbytes = 0; - bravalue = OP_CBRA; -- save_hwm_offset = cd->hwm - cd->start_workspace; -+ item_hwm_offset = cd->hwm - cd->start_workspace; - reset_bracount = FALSE; - - /* Deal with the extended parentheses; all are introduced by '?', and the -@@ -6641,6 +6667,7 @@ - /* ------------------------------------------------------------ */ - case CHAR_VERTICAL_LINE: /* Reset capture count for each branch */ - reset_bracount = TRUE; -+ cd->dupgroups = TRUE; /* Record (?| encountered */ - /* Fall through */ - - /* ------------------------------------------------------------ */ -@@ -6741,6 +6768,12 @@ - { - while (IS_DIGIT(*ptr)) - { -+ if (recno > INT_MAX / 10 - 1) /* Integer overflow */ -+ { -+ while (IS_DIGIT(*ptr)) ptr++; -+ *errorcodeptr = ERR61; -+ goto FAILED; -+ } - recno = recno * 10 + (int)(*ptr - CHAR_0); - ptr++; - } -@@ -6769,7 +6802,7 @@ - ptr++; - } - namelen = (int)(ptr - name); -- if (lengthptr != NULL) *lengthptr += IMM2_SIZE; -+ if (lengthptr != NULL) skipbytes += IMM2_SIZE; - } - - /* Check the terminator */ -@@ -6875,6 +6908,11 @@ - *errorcodeptr = ERR15; - goto FAILED; - } -+ if (recno > INT_MAX / 10 - 1) /* Integer overflow */ -+ { -+ *errorcodeptr = ERR61; -+ goto FAILED; -+ } - recno = recno * 10 + name[i] - CHAR_0; - } - if (recno == 0) recno = RREF_ANY; -@@ -7151,7 +7189,8 @@ - if (lengthptr != NULL) - { - named_group *ng; -- -+ recno = 0; -+ - if (namelen == 0) - { - *errorcodeptr = ERR62; -@@ -7168,20 +7207,6 @@ - goto FAILED; - } - -- /* The name table does not exist in the first pass; instead we must -- scan the list of names encountered so far in order to get the -- number. If the name is not found, set the value to 0 for a forward -- reference. */ -- -- ng = cd->named_groups; -- for (i = 0; i < cd->names_found; i++, ng++) -- { -- if (namelen == ng->length && -- STRNCMP_UC_UC(name, ng->name, namelen) == 0) -- break; -- } -- recno = (i < cd->names_found)? ng->number : 0; -- - /* Count named back references. */ - - if (!is_recurse) cd->namedrefcount++; -@@ -7191,6 +7216,56 @@ - 16-bit data item. */ - - *lengthptr += IMM2_SIZE; -+ -+ /* If this is a forward reference and we are within a (?|...) group, -+ the reference may end up as the number of a group which we are -+ currently inside, that is, it could be a recursive reference. In the -+ real compile this will be picked up and the reference wrapped with -+ OP_ONCE to make it atomic, so we must space in case this occurs. */ -+ -+ /* In fact, this can happen for a non-forward reference because -+ another group with the same number might be created later. This -+ issue is fixed "properly" in PCRE2. As PCRE1 is now in maintenance -+ only mode, we finesse the bug by allowing more memory always. */ -+ -+ *lengthptr += 2 + 2*LINK_SIZE; -+ -+ /* It is even worse than that. The current reference may be to an -+ existing named group with a different number (so apparently not -+ recursive) but which later on is also attached to a group with the -+ current number. This can only happen if $(| has been previous -+ encountered. In that case, we allow yet more memory, just in case. -+ (Again, this is fixed "properly" in PCRE2. */ -+ -+ if (cd->dupgroups) *lengthptr += 4 + 4*LINK_SIZE; -+ -+ /* Otherwise, check for recursion here. The name table does not exist -+ in the first pass; instead we must scan the list of names encountered -+ so far in order to get the number. If the name is not found, leave -+ the value of recno as 0 for a forward reference. */ -+ -+ else -+ { -+ ng = cd->named_groups; -+ for (i = 0; i < cd->names_found; i++, ng++) -+ { -+ if (namelen == ng->length && -+ STRNCMP_UC_UC(name, ng->name, namelen) == 0) -+ { -+ open_capitem *oc; -+ recno = ng->number; -+ if (is_recurse) break; -+ for (oc = cd->open_caps; oc != NULL; oc = oc->next) -+ { -+ if (oc->number == recno) -+ { -+ oc->flag = TRUE; -+ break; -+ } -+ } -+ } -+ } -+ } - } - - /* In the real compile, search the name table. We check the name -@@ -7237,8 +7312,6 @@ - for (i++; i < cd->names_found; i++) - { - if (STRCMP_UC_UC(slot + IMM2_SIZE, cslot + IMM2_SIZE) != 0) break; -- -- - count++; - cslot += cd->name_entry_size; - } -@@ -7247,6 +7320,7 @@ - { - if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE; - previous = code; -+ item_hwm_offset = cd->hwm - cd->start_workspace; - *code++ = ((options & PCRE_CASELESS) != 0)? OP_DNREFI : OP_DNREF; - PUT2INC(code, 0, index); - PUT2INC(code, 0, count); -@@ -7284,9 +7358,14 @@ - - - /* ------------------------------------------------------------ */ -- case CHAR_R: /* Recursion */ -- ptr++; /* Same as (?0) */ -- /* Fall through */ -+ case CHAR_R: /* Recursion, same as (?0) */ -+ recno = 0; -+ if (*(++ptr) != CHAR_RIGHT_PARENTHESIS) -+ { -+ *errorcodeptr = ERR29; -+ goto FAILED; -+ } -+ goto HANDLE_RECURSION; - - - /* ------------------------------------------------------------ */ -@@ -7323,7 +7402,15 @@ - - recno = 0; - while(IS_DIGIT(*ptr)) -+ { -+ if (recno > INT_MAX / 10 - 1) /* Integer overflow */ -+ { -+ while (IS_DIGIT(*ptr)) ptr++; -+ *errorcodeptr = ERR61; -+ goto FAILED; -+ } - recno = recno * 10 + *ptr++ - CHAR_0; -+ } - - if (*ptr != (pcre_uchar)terminator) - { -@@ -7360,6 +7447,7 @@ - HANDLE_RECURSION: - - previous = code; -+ item_hwm_offset = cd->hwm - cd->start_workspace; - called = cd->start_code; - - /* When we are actually compiling, find the bracket that is being -@@ -7561,7 +7649,11 @@ - previous = NULL; - cd->iscondassert = FALSE; - } -- else previous = code; -+ else -+ { -+ previous = code; -+ item_hwm_offset = cd->hwm - cd->start_workspace; -+ } - - *code = bravalue; - tempcode = code; -@@ -7809,7 +7901,7 @@ - const pcre_uchar *p; - pcre_uint32 cf; - -- save_hwm_offset = cd->hwm - cd->start_workspace; /* Normally this is set when '(' is read */ -+ item_hwm_offset = cd->hwm - cd->start_workspace; /* Normally this is set when '(' is read */ - terminator = (*(++ptr) == CHAR_LESS_THAN_SIGN)? - CHAR_GREATER_THAN_SIGN : CHAR_APOSTROPHE; - -@@ -7838,7 +7930,7 @@ - if (*p != (pcre_uchar)terminator) - { - *errorcodeptr = ERR57; -- break; -+ goto FAILED; - } - ptr++; - goto HANDLE_NUMERICAL_RECURSION; -@@ -7853,7 +7945,7 @@ - ptr[1] != CHAR_APOSTROPHE && ptr[1] != CHAR_LEFT_CURLY_BRACKET)) - { - *errorcodeptr = ERR69; -- break; -+ goto FAILED; - } - is_recurse = FALSE; - terminator = (*(++ptr) == CHAR_LESS_THAN_SIGN)? -@@ -7877,6 +7969,7 @@ - HANDLE_REFERENCE: - if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE; - previous = code; -+ item_hwm_offset = cd->hwm - cd->start_workspace; - *code++ = ((options & PCRE_CASELESS) != 0)? OP_REFI : OP_REF; - PUT2INC(code, 0, recno); - cd->backref_map |= (recno < 32)? (1 << recno) : 1; -@@ -7906,6 +7999,7 @@ - if (!get_ucp(&ptr, &negated, &ptype, &pdata, errorcodeptr)) - goto FAILED; - previous = code; -+ item_hwm_offset = cd->hwm - cd->start_workspace; - *code++ = ((escape == ESC_p) != negated)? OP_PROP : OP_NOTPROP; - *code++ = ptype; - *code++ = pdata; -@@ -7946,6 +8040,7 @@ - - { - previous = (escape > ESC_b && escape < ESC_Z)? code : NULL; -+ item_hwm_offset = cd->hwm - cd->start_workspace; - *code++ = (!utf && escape == ESC_C)? OP_ALLANY : escape; - } - } -@@ -7989,6 +8084,7 @@ - - ONE_CHAR: - previous = code; -+ item_hwm_offset = cd->hwm - cd->start_workspace; - - /* For caseless UTF-8 mode when UCP support is available, check whether - this character has more than one other case. If so, generate a special -@@ -9164,6 +9260,7 @@ - cd->name_entry_size = 0; - cd->name_table = NULL; - cd->dupnames = FALSE; -+cd->dupgroups = FALSE; - cd->namedrefcount = 0; - cd->start_code = cworkspace; - cd->hwm = cworkspace; -@@ -9198,7 +9295,7 @@ - - DPRINTF(("end pre-compile: length=%d workspace=%d\n", length, - (int)(cd->hwm - cworkspace))); -- -+ - if (length > MAX_PATTERN_SIZE) - { - errorcode = ERR20; -@@ -9336,6 +9433,16 @@ - int offset, recno; - cd->hwm -= LINK_SIZE; - offset = GET(cd->hwm, 0); -+ -+ /* Check that the hwm handling hasn't gone wrong. This whole area is -+ rewritten in PCRE2 because there are some obscure cases. */ -+ -+ if (offset == 0 || codestart[offset-1] != OP_RECURSE) -+ { -+ errorcode = ERR10; -+ break; -+ } -+ - recno = GET(codestart, offset); - if (recno != prev_recno) - { -@@ -9366,7 +9473,7 @@ - "const" attribute if the cast (pcre_uchar *)codestart is used directly in the - function call. */ - --if ((options & PCRE_NO_AUTO_POSSESS) == 0) -+if (errorcode == 0 && (options & PCRE_NO_AUTO_POSSESS) == 0) - { - pcre_uchar *temp = (pcre_uchar *)codestart; - auto_possessify(temp, utf, cd); -@@ -9380,7 +9487,7 @@ - exceptional ones forgo this. We scan the pattern to check that they are fixed - length, and set their lengths. */ - --if (cd->check_lookbehind) -+if (errorcode == 0 && cd->check_lookbehind) - { - pcre_uchar *cc = (pcre_uchar *)codestart; - -@@ -9593,4 +9700,3 @@ - } - - /* End of pcre_compile.c */ -- -Index: ChangeLog -=================================================================== ---- ChangeLog (revision 1554) -+++ ChangeLog (working copy) -@@ -1,6 +1,162 @@ - ChangeLog for PCRE - ------------------ - -+Note that the PCRE 8.xx series (PCRE1) is now in a bugfix-only state. All -+development is happening in the PCRE2 10.xx series. -+ -+Version 8.38 xx-xxx-xxxx -+------------------------ -+ -+1. If a group that contained a recursive back reference also contained a -+ forward reference subroutine call followed by a non-forward-reference -+ subroutine call, for example /.((?2)(?R)\1)()/, pcre2_compile() failed to -+ compile correct code, leading to undefined behaviour or an internally -+ detected error. This bug was discovered by the LLVM fuzzer. -+ -+2. Quantification of certain items (e.g. atomic back references) could cause -+ incorrect code to be compiled when recursive forward references were -+ involved. For example, in this pattern: /(?1)()((((((\1++))\x85)+)|))/. -+ This bug was discovered by the LLVM fuzzer. -+ -+3. A repeated conditional group whose condition was a reference by name caused -+ a buffer overflow if there was more than one group with the given name. -+ This bug was discovered by the LLVM fuzzer. -+ -+4. A recursive back reference by name within a group that had the same name as -+ another group caused a buffer overflow. For example: -+ /(?J)(?'d'(?'d'\g{d}))/. This bug was discovered by the LLVM fuzzer. -+ -+5. A forward reference by name to a group whose number is the same as the -+ current group, for example in this pattern: /(?|(\k'Pm')|(?'Pm'))/, caused -+ a buffer overflow at compile time. This bug was discovered by the LLVM -+ fuzzer. -+ -+6. A lookbehind assertion within a set of mutually recursive subpatterns could -+ provoke a buffer overflow. This bug was discovered by the LLVM fuzzer. -+ -+7. Another buffer overflow bug involved duplicate named groups with a -+ reference between their definition, with a group that reset capture -+ numbers, for example: /(?J:(?|(?'R')(\k'R')|((?'R'))))/. This has been -+ fixed by always allowing for more memory, even if not needed. (A proper fix -+ is implemented in PCRE2, but it involves more refactoring.) -+ -+8. There was no check for integer overflow in subroutine calls such as (?123). -+ -+9. The table entry for \l in EBCDIC environments was incorrect, leading to its -+ being treated as a literal 'l' instead of causing an error. -+ -+10. There was a buffer overflow if pcre_exec() was called with an ovector of -+ size 1. This bug was found by american fuzzy lop. -+ -+11. If a non-capturing group containing a conditional group that could match -+ an empty string was repeated, it was not identified as matching an empty -+ string itself. For example: /^(?:(?(1)x|)+)+$()/. -+ -+12. In an EBCDIC environment, pcretest was mishandling the escape sequences -+ \a and \e in test subject lines. -+ -+13. In an EBCDIC environment, \a in a pattern was converted to the ASCII -+ instead of the EBCDIC value. -+ -+14. The handling of \c in an EBCDIC environment has been revised so that it is -+ now compatible with the specification in Perl's perlebcdic page. -+ -+15. The EBCDIC character 0x41 is a non-breaking space, equivalent to 0xa0 in -+ ASCII/Unicode. This has now been added to the list of characters that are -+ recognized as white space in EBCDIC. -+ -+16. When PCRE was compiled without UCP support, the use of \p and \P gave an -+ error (correctly) when used outside a class, but did not give an error -+ within a class. -+ -+17. \h within a class was incorrectly compiled in EBCDIC environments. -+ -+18. A pattern with an unmatched closing parenthesis that contained a backward -+ assertion which itself contained a forward reference caused buffer -+ overflow. And example pattern is: /(?=di(?<=(?1))|(?=(.))))/. -+ -+19. JIT should return with error when the compiled pattern requires more stack -+ space than the maximum. -+ -+20. A possessively repeated conditional group that could match an empty string, -+ for example, /(?(R))*+/, was incorrectly compiled. -+ -+21. Fix infinite recursion in the JIT compiler when certain patterns such as -+ /(?:|a|){100}x/ are analysed. -+ -+22. Some patterns with character classes involving [: and \\ were incorrectly -+ compiled and could cause reading from uninitialized memory or an incorrect -+ error diagnosis. -+ -+23. Pathological patterns containing many nested occurrences of [: caused -+ pcre_compile() to run for a very long time. -+ -+24. A conditional group with only one branch has an implicit empty alternative -+ branch and must therefore be treated as potentially matching an empty -+ string. -+ -+25. If (?R was followed by - or + incorrect behaviour happened instead of a -+ diagnostic. -+ -+26. Arrange to give up on finding the minimum matching length for overly -+ complex patterns. -+ -+27. Similar to (4) above: in a pattern with duplicated named groups and an -+ occurrence of (?| it is possible for an apparently non-recursive back -+ reference to become recursive if a later named group with the relevant -+ number is encountered. This could lead to a buffer overflow. Wen Guanxing -+ from Venustech ADLAB discovered this bug. -+ -+28. If pcregrep was given the -q option with -c or -l, or when handling a -+ binary file, it incorrectly wrote output to stdout. -+ -+29. The JIT compiler did not restore the control verb head in case of *THEN -+ control verbs. This issue was found by Karl Skomski with a custom LLVM -+ fuzzer. -+ -+30. Error messages for syntax errors following \g and \k were giving inaccurate -+ offsets in the pattern. -+ -+31. Added a check for integer overflow in conditions (?() and -+ (?(R). This omission was discovered by Karl Skomski with the LLVM -+ fuzzer. -+ -+32. Handling recursive references such as (?2) when the reference is to a group -+ later in the pattern uses code that is very hacked about and error-prone. -+ It has been re-written for PCRE2. Here in PCRE1, a check has been added to -+ give an internal error if it is obvious that compiling has gone wrong. -+ -+33. The JIT compiler should not check repeats after a {0,1} repeat byte code. -+ This issue was found by Karl Skomski with a custom LLVM fuzzer. -+ -+34. The JIT compiler should restore the control chain for empty possessive -+ repeats. This issue was found by Karl Skomski with a custom LLVM fuzzer. -+ -+35. Match limit check added to JIT recursion. This issue was found by Karl -+ Skomski with a custom LLVM fuzzer. -+ -+36. Yet another case similar to 27 above has been circumvented by an -+ unconditional allocation of extra memory. This issue is fixed "properly" in -+ PCRE2 by refactoring the way references are handled. Wen Guanxing -+ from Venustech ADLAB discovered this bug. -+ -+37. Fix two assertion fails in JIT. These issues were found by Karl Skomski -+ with a custom LLVM fuzzer. -+ -+38. Fixed a corner case of range optimization in JIT. -+ -+39. An incorrect error "overran compiling workspace" was given if there were -+ exactly enough group forward references such that the last one extended -+ into the workspace safety margin. The next one would have expanded the -+ workspace. The test for overflow was not including the safety margin. -+ -+40. A match limit issue is fixed in JIT which was found by Karl Skomski -+ with a custom LLVM fuzzer. -+ -+41. Remove the use of /dev/null in testdata/testinput2, because it doesn't -+ work under Windows. (Why has it taken so long for anyone to notice?) -+ -+ - Version 8.37 28-April-2015 - -------------------------- - -Index: pcretest.c -=================================================================== ---- pcretest.c (revision 1554) -+++ pcretest.c (working copy) -@@ -4621,9 +4621,9 @@ - - else switch ((c = *p++)) - { -- case 'a': c = 7; break; -+ case 'a': c = CHAR_BEL; break; - case 'b': c = '\b'; break; -- case 'e': c = 27; break; -+ case 'e': c = CHAR_ESC; break; - case 'f': c = '\f'; break; - case 'n': c = '\n'; break; - case 'r': c = '\r'; break; -Index: sljit/sljitLir.c -=================================================================== ---- sljit/sljitLir.c (revision 1554) -+++ sljit/sljitLir.c (working copy) -@@ -845,8 +845,8 @@ - } - - static SLJIT_CONST char* op0_names[] = { -- (char*)"breakpoint", (char*)"nop", -- (char*)"lumul", (char*)"lsmul", (char*)"ludiv", (char*)"lsdiv", -+ (char*)"breakpoint", (char*)"nop", (char*)"lumul", (char*)"lsmul", -+ (char*)"udivmod", (char*)"sdivmod", (char*)"udivi", (char*)"sdivi" - }; - - static SLJIT_CONST char* op1_names[] = { -@@ -1036,7 +1036,7 @@ - { - #if (defined SLJIT_ARGUMENT_CHECKS && SLJIT_ARGUMENT_CHECKS) - CHECK_ARGUMENT((op >= SLJIT_BREAKPOINT && op <= SLJIT_LSMUL) -- || ((op & ~SLJIT_INT_OP) >= SLJIT_LUDIV && (op & ~SLJIT_INT_OP) <= SLJIT_LSDIV)); -+ || ((op & ~SLJIT_INT_OP) >= SLJIT_UDIVMOD && (op & ~SLJIT_INT_OP) <= SLJIT_SDIVI)); - CHECK_ARGUMENT(op < SLJIT_LUMUL || compiler->scratches >= 2); - #endif - #if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) -@@ -1447,6 +1447,8 @@ - - static SLJIT_INLINE CHECK_RETURN_TYPE check_sljit_get_local_base(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw offset) - { -+ SLJIT_UNUSED_ARG(offset); -+ - #if (defined SLJIT_ARGUMENT_CHECKS && SLJIT_ARGUMENT_CHECKS) - FUNCTION_CHECK_DST(dst, dstw); - #endif -@@ -1462,6 +1464,8 @@ - - static SLJIT_INLINE CHECK_RETURN_TYPE check_sljit_emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw init_value) - { -+ SLJIT_UNUSED_ARG(init_value); -+ - #if (defined SLJIT_ARGUMENT_CHECKS && SLJIT_ARGUMENT_CHECKS) - FUNCTION_CHECK_DST(dst, dstw); - #endif -Index: sljit/sljitNativeSPARC_common.c -=================================================================== ---- sljit/sljitNativeSPARC_common.c (revision 1554) -+++ sljit/sljitNativeSPARC_common.c (working copy) -@@ -777,20 +777,25 @@ - #else - #error "Implementation required" - #endif -- case SLJIT_LUDIV: -- case SLJIT_LSDIV: -+ case SLJIT_UDIVMOD: -+ case SLJIT_SDIVMOD: -+ case SLJIT_UDIVI: -+ case SLJIT_SDIVI: -+ SLJIT_COMPILE_ASSERT((SLJIT_UDIVMOD & 0x2) == 0 && SLJIT_UDIVI - 0x2 == SLJIT_UDIVMOD, bad_div_opcode_assignments); - #if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32) -- if (op == SLJIT_LUDIV) -+ if ((op | 0x2) == SLJIT_UDIVI) - FAIL_IF(push_inst(compiler, WRY | S1(0), MOVABLE_INS)); - else { - FAIL_IF(push_inst(compiler, SRA | D(TMP_REG1) | S1(SLJIT_R0) | IMM(31), DR(TMP_REG1))); - FAIL_IF(push_inst(compiler, WRY | S1(TMP_REG1), MOVABLE_INS)); - } -- FAIL_IF(push_inst(compiler, OR | D(TMP_REG2) | S1(0) | S2(SLJIT_R0), DR(TMP_REG2))); -- FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? UDIV : SDIV) | D(SLJIT_R0) | S1(SLJIT_R0) | S2(SLJIT_R1), DR(SLJIT_R0))); -+ if (op <= SLJIT_SDIVMOD) -+ FAIL_IF(push_inst(compiler, OR | D(TMP_REG2) | S1(0) | S2(SLJIT_R0), DR(TMP_REG2))); -+ FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_UDIVI ? UDIV : SDIV) | D(SLJIT_R0) | S1(SLJIT_R0) | S2(SLJIT_R1), DR(SLJIT_R0))); -+ if (op >= SLJIT_UDIVI) -+ return SLJIT_SUCCESS; - FAIL_IF(push_inst(compiler, SMUL | D(SLJIT_R1) | S1(SLJIT_R0) | S2(SLJIT_R1), DR(SLJIT_R1))); -- FAIL_IF(push_inst(compiler, SUB | D(SLJIT_R1) | S1(TMP_REG2) | S2(SLJIT_R1), DR(SLJIT_R1))); -- return SLJIT_SUCCESS; -+ return push_inst(compiler, SUB | D(SLJIT_R1) | S1(TMP_REG2) | S2(SLJIT_R1), DR(SLJIT_R1)); - #else - #error "Implementation required" - #endif -Index: sljit/sljitNativeMIPS_common.c -=================================================================== ---- sljit/sljitNativeMIPS_common.c (revision 1554) -+++ sljit/sljitNativeMIPS_common.c (working copy) -@@ -1053,8 +1053,11 @@ - #endif - FAIL_IF(push_inst(compiler, MFLO | D(SLJIT_R0), DR(SLJIT_R0))); - return push_inst(compiler, MFHI | D(SLJIT_R1), DR(SLJIT_R1)); -- case SLJIT_LUDIV: -- case SLJIT_LSDIV: -+ case SLJIT_UDIVMOD: -+ case SLJIT_SDIVMOD: -+ case SLJIT_UDIVI: -+ case SLJIT_SDIVI: -+ SLJIT_COMPILE_ASSERT((SLJIT_UDIVMOD & 0x2) == 0 && SLJIT_UDIVI - 0x2 == SLJIT_UDIVMOD, bad_div_opcode_assignments); - #if !(defined SLJIT_MIPS_R1 && SLJIT_MIPS_R1) - FAIL_IF(push_inst(compiler, NOP, UNMOVABLE_INS)); - FAIL_IF(push_inst(compiler, NOP, UNMOVABLE_INS)); -@@ -1062,15 +1065,15 @@ - - #if (defined SLJIT_CONFIG_MIPS_64 && SLJIT_CONFIG_MIPS_64) - if (int_op) -- FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? DIVU : DIV) | S(SLJIT_R0) | T(SLJIT_R1), MOVABLE_INS)); -+ FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_UDIVI ? DIVU : DIV) | S(SLJIT_R0) | T(SLJIT_R1), MOVABLE_INS)); - else -- FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? DDIVU : DDIV) | S(SLJIT_R0) | T(SLJIT_R1), MOVABLE_INS)); -+ FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_UDIVI ? DDIVU : DDIV) | S(SLJIT_R0) | T(SLJIT_R1), MOVABLE_INS)); - #else -- FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? DIVU : DIV) | S(SLJIT_R0) | T(SLJIT_R1), MOVABLE_INS)); -+ FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_UDIVI ? DIVU : DIV) | S(SLJIT_R0) | T(SLJIT_R1), MOVABLE_INS)); - #endif - - FAIL_IF(push_inst(compiler, MFLO | D(SLJIT_R0), DR(SLJIT_R0))); -- return push_inst(compiler, MFHI | D(SLJIT_R1), DR(SLJIT_R1)); -+ return (op >= SLJIT_UDIVI) ? SLJIT_SUCCESS : push_inst(compiler, MFHI | D(SLJIT_R1), DR(SLJIT_R1)); - } - - return SLJIT_SUCCESS; -Index: sljit/sljitNativeARM_32.c -=================================================================== ---- sljit/sljitNativeARM_32.c (revision 1554) -+++ sljit/sljitNativeARM_32.c (working copy) -@@ -1833,18 +1833,33 @@ - | (reg_map[SLJIT_R0] << 8) - | reg_map[TMP_REG1]); - #endif -- case SLJIT_LUDIV: -- case SLJIT_LSDIV: -- if (compiler->scratches >= 3) -+ case SLJIT_UDIVMOD: -+ case SLJIT_SDIVMOD: -+ case SLJIT_UDIVI: -+ case SLJIT_SDIVI: -+ SLJIT_COMPILE_ASSERT((SLJIT_UDIVMOD & 0x2) == 0 && SLJIT_UDIVI - 0x2 == SLJIT_UDIVMOD, bad_div_opcode_assignments); -+ SLJIT_COMPILE_ASSERT(reg_map[2] == 1 && reg_map[3] == 2, bad_register_mapping); -+ -+ if ((op >= SLJIT_UDIVI) && (compiler->scratches >= 3)) { - FAIL_IF(push_inst(compiler, 0xe52d2008 /* str r2, [sp, #-8]! */)); -+ FAIL_IF(push_inst(compiler, 0xe58d1004 /* str r1, [sp, #4] */)); -+ } -+ else if ((op >= SLJIT_UDIVI) || (compiler->scratches >= 3)) -+ FAIL_IF(push_inst(compiler, 0xe52d0008 | (op >= SLJIT_UDIVI ? 0x1000 : 0x2000) /* str r1/r2, [sp, #-8]! */)); -+ - #if defined(__GNUC__) - FAIL_IF(sljit_emit_ijump(compiler, SLJIT_FAST_CALL, SLJIT_IMM, -- (op == SLJIT_LUDIV ? SLJIT_FUNC_OFFSET(__aeabi_uidivmod) : SLJIT_FUNC_OFFSET(__aeabi_idivmod)))); -+ ((op | 0x2) == SLJIT_UDIVI ? SLJIT_FUNC_OFFSET(__aeabi_uidivmod) : SLJIT_FUNC_OFFSET(__aeabi_idivmod)))); - #else - #error "Software divmod functions are needed" - #endif -- if (compiler->scratches >= 3) -- return push_inst(compiler, 0xe49d2008 /* ldr r2, [sp], #8 */); -+ -+ if ((op >= SLJIT_UDIVI) && (compiler->scratches >= 3)) { -+ FAIL_IF(push_inst(compiler, 0xe59d1004 /* ldr r1, [sp, #4] */)); -+ FAIL_IF(push_inst(compiler, 0xe49d2008 /* ldr r2, [sp], #8 */)); -+ } -+ else if ((op >= SLJIT_UDIVI) || (compiler->scratches >= 3)) -+ return push_inst(compiler, 0xe49d0008 | (op >= SLJIT_UDIVI ? 0x1000 : 0x2000) /* ldr r1/r2, [sp], #8 */); - return SLJIT_SUCCESS; - } - -Index: sljit/sljitLir.h -=================================================================== ---- sljit/sljitLir.h (revision 1554) -+++ sljit/sljitLir.h (working copy) -@@ -687,7 +687,7 @@ - #define SLJIT_OP0_BASE 0 - - /* Flags: - (never set any flags) -- Note: breakpoint instruction is not supported by all architectures (namely ppc) -+ Note: breakpoint instruction is not supported by all architectures (e.g. ppc) - It falls back to SLJIT_NOP in those cases. */ - #define SLJIT_BREAKPOINT (SLJIT_OP0_BASE + 0) - /* Flags: - (never set any flags) -@@ -696,24 +696,42 @@ - #define SLJIT_NOP (SLJIT_OP0_BASE + 1) - /* Flags: - (may destroy flags) - Unsigned multiplication of SLJIT_R0 and SLJIT_R1. -- Result goes to SLJIT_R1:SLJIT_R0 (high:low) word */ -+ Result is placed into SLJIT_R1:SLJIT_R0 (high:low) word */ - #define SLJIT_LUMUL (SLJIT_OP0_BASE + 2) - /* Flags: - (may destroy flags) - Signed multiplication of SLJIT_R0 and SLJIT_R1. -- Result goes to SLJIT_R1:SLJIT_R0 (high:low) word */ -+ Result is placed into SLJIT_R1:SLJIT_R0 (high:low) word */ - #define SLJIT_LSMUL (SLJIT_OP0_BASE + 3) - /* Flags: I - (may destroy flags) - Unsigned divide of the value in SLJIT_R0 by the value in SLJIT_R1. -- The result is placed in SLJIT_R0 and the remainder goes to SLJIT_R1. -- Note: if SLJIT_R1 contains 0, the behaviour is undefined. */ --#define SLJIT_LUDIV (SLJIT_OP0_BASE + 4) --#define SLJIT_ILUDIV (SLJIT_LUDIV | SLJIT_INT_OP) -+ The result is placed into SLJIT_R0 and the remainder into SLJIT_R1. -+ Note: if SLJIT_R1 is 0, the behaviour is undefined. */ -+#define SLJIT_UDIVMOD (SLJIT_OP0_BASE + 4) -+#define SLJIT_IUDIVMOD (SLJIT_UDIVMOD | SLJIT_INT_OP) - /* Flags: I - (may destroy flags) - Signed divide of the value in SLJIT_R0 by the value in SLJIT_R1. -- The result is placed in SLJIT_R0 and the remainder goes to SLJIT_R1. -- Note: if SLJIT_R1 contains 0, the behaviour is undefined. */ --#define SLJIT_LSDIV (SLJIT_OP0_BASE + 5) --#define SLJIT_ILSDIV (SLJIT_LSDIV | SLJIT_INT_OP) -+ The result is placed into SLJIT_R0 and the remainder into SLJIT_R1. -+ Note: if SLJIT_R1 is 0, the behaviour is undefined. -+ Note: if SLJIT_R1 is -1 and SLJIT_R0 is integer min (0x800..00), -+ the behaviour is undefined. */ -+#define SLJIT_SDIVMOD (SLJIT_OP0_BASE + 5) -+#define SLJIT_ISDIVMOD (SLJIT_SDIVMOD | SLJIT_INT_OP) -+/* Flags: I - (may destroy flags) -+ Unsigned divide of the value in SLJIT_R0 by the value in SLJIT_R1. -+ The result is placed into SLJIT_R0. SLJIT_R1 preserves its value. -+ Note: if SLJIT_R1 is 0, the behaviour is undefined. -+ Note: SLJIT_SDIV is single precision divide. */ -+#define SLJIT_UDIVI (SLJIT_OP0_BASE + 6) -+#define SLJIT_IUDIVI (SLJIT_UDIVI | SLJIT_INT_OP) -+/* Flags: I - (may destroy flags) -+ Signed divide of the value in SLJIT_R0 by the value in SLJIT_R1. -+ The result is placed into SLJIT_R0. SLJIT_R1 preserves its value. -+ Note: if SLJIT_R1 is 0, the behaviour is undefined. -+ Note: if SLJIT_R1 is -1 and SLJIT_R0 is integer min (0x800..00), -+ the behaviour is undefined. -+ Note: SLJIT_SDIV is single precision divide. */ -+#define SLJIT_SDIVI (SLJIT_OP0_BASE + 7) -+#define SLJIT_ISDIVI (SLJIT_SDIVI | SLJIT_INT_OP) - - SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op); - -@@ -851,34 +869,6 @@ - sljit_si src1, sljit_sw src1w, - sljit_si src2, sljit_sw src2w); - --/* The following function is a helper function for sljit_emit_op_custom. -- It returns with the real machine register index ( >=0 ) of any SLJIT_R, -- SLJIT_S and SLJIT_SP registers. -- -- Note: it returns with -1 for virtual registers (only on x86-32). */ -- --SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg); -- --/* The following function is a helper function for sljit_emit_op_custom. -- It returns with the real machine register index of any SLJIT_FLOAT register. -- -- Note: the index is always an even number on ARM (except ARM-64), MIPS, and SPARC. */ -- --SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_float_register_index(sljit_si reg); -- --/* Any instruction can be inserted into the instruction stream by -- sljit_emit_op_custom. It has a similar purpose as inline assembly. -- The size parameter must match to the instruction size of the target -- architecture: -- -- x86: 0 < size <= 15. The instruction argument can be byte aligned. -- Thumb2: if size == 2, the instruction argument must be 2 byte aligned. -- if size == 4, the instruction argument must be 4 byte aligned. -- Otherwise: size must be 4 and instruction argument must be 4 byte aligned. */ -- --SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler, -- void *instruction, sljit_si size); -- - /* Returns with non-zero if fpu is available. */ - - SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_is_fpu_available(void); -@@ -1196,4 +1186,64 @@ - - #endif /* !(defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL) */ - -+/* --------------------------------------------------------------------- */ -+/* CPU specific functions */ -+/* --------------------------------------------------------------------- */ -+ -+/* The following function is a helper function for sljit_emit_op_custom. -+ It returns with the real machine register index ( >=0 ) of any SLJIT_R, -+ SLJIT_S and SLJIT_SP registers. -+ -+ Note: it returns with -1 for virtual registers (only on x86-32). */ -+ -+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg); -+ -+/* The following function is a helper function for sljit_emit_op_custom. -+ It returns with the real machine register index of any SLJIT_FLOAT register. -+ -+ Note: the index is always an even number on ARM (except ARM-64), MIPS, and SPARC. */ -+ -+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_float_register_index(sljit_si reg); -+ -+/* Any instruction can be inserted into the instruction stream by -+ sljit_emit_op_custom. It has a similar purpose as inline assembly. -+ The size parameter must match to the instruction size of the target -+ architecture: -+ -+ x86: 0 < size <= 15. The instruction argument can be byte aligned. -+ Thumb2: if size == 2, the instruction argument must be 2 byte aligned. -+ if size == 4, the instruction argument must be 4 byte aligned. -+ Otherwise: size must be 4 and instruction argument must be 4 byte aligned. */ -+ -+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler, -+ void *instruction, sljit_si size); -+ -+#if (defined SLJIT_CONFIG_X86 && SLJIT_CONFIG_X86) -+ -+/* Returns with non-zero if sse2 is available. */ -+ -+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_x86_is_sse2_available(void); -+ -+/* Returns with non-zero if cmov instruction is available. */ -+ -+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_x86_is_cmov_available(void); -+ -+/* Emit a conditional mov instruction on x86 CPUs. This instruction -+ moves src to destination, if the condition is satisfied. Unlike -+ other arithmetic instructions, destination must be a register. -+ Before such instructions are emitted, cmov support should be -+ checked by sljit_x86_is_cmov_available function. -+ type must be between SLJIT_EQUAL and SLJIT_S_ORDERED -+ dst_reg must be a valid register and it can be combined -+ with SLJIT_INT_OP to perform 32 bit arithmetic -+ Flags: I - (never set any flags) -+ */ -+ -+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_x86_emit_cmov(struct sljit_compiler *compiler, -+ sljit_si type, -+ sljit_si dst_reg, -+ sljit_si src, sljit_sw srcw); -+ -+#endif -+ - #endif /* _SLJIT_LIR_H_ */ -Index: sljit/sljitNativeARM_64.c -=================================================================== ---- sljit/sljitNativeARM_64.c (revision 1554) -+++ sljit/sljitNativeARM_64.c (working copy) -@@ -1087,7 +1087,8 @@ - saved_regs_size += sizeof(sljit_sw); - } - local_size -= saved_regs_size + SLJIT_LOCALS_OFFSET; -- FAIL_IF(push_inst(compiler, SUBI | RD(TMP_SP) | RN(TMP_SP) | (saved_regs_size << 10))); -+ if (saved_regs_size > 0) -+ FAIL_IF(push_inst(compiler, SUBI | RD(TMP_SP) | RN(TMP_SP) | (saved_regs_size << 10))); - } - - tmp = saveds < SLJIT_NUMBER_OF_SAVED_REGISTERS ? (SLJIT_S0 + 1 - saveds) : SLJIT_FIRST_SAVED_REG; -@@ -1094,7 +1095,12 @@ - prev = -1; - for (i = SLJIT_S0; i >= tmp; i--) { - if (prev == -1) { -- prev = i; -+ if (!(offs & (1 << 15))) { -+ prev = i; -+ continue; -+ } -+ FAIL_IF(push_inst(compiler, STRI | RT(i) | RN(TMP_SP) | (offs >> 5))); -+ offs += 1 << 15; - continue; - } - FAIL_IF(push_inst(compiler, STP | RT(prev) | RT2(i) | RN(TMP_SP) | offs)); -@@ -1104,7 +1110,12 @@ - - for (i = scratches; i >= SLJIT_FIRST_SAVED_REG; i--) { - if (prev == -1) { -- prev = i; -+ if (!(offs & (1 << 15))) { -+ prev = i; -+ continue; -+ } -+ FAIL_IF(push_inst(compiler, STRI | RT(i) | RN(TMP_SP) | (offs >> 5))); -+ offs += 1 << 15; - continue; - } - FAIL_IF(push_inst(compiler, STP | RT(prev) | RT2(i) | RN(TMP_SP) | offs)); -@@ -1112,8 +1123,7 @@ - prev = -1; - } - -- if (prev != -1) -- FAIL_IF(push_inst(compiler, STRI | RT(prev) | RN(TMP_SP) | (offs >> 5))); -+ SLJIT_ASSERT(prev == -1); - - if (compiler->local_size > (63 * sizeof(sljit_sw))) { - /* The local_size is already adjusted by the saved registers. */ -@@ -1188,7 +1198,12 @@ - prev = -1; - for (i = SLJIT_S0; i >= tmp; i--) { - if (prev == -1) { -- prev = i; -+ if (!(offs & (1 << 15))) { -+ prev = i; -+ continue; -+ } -+ FAIL_IF(push_inst(compiler, LDRI | RT(i) | RN(TMP_SP) | (offs >> 5))); -+ offs += 1 << 15; - continue; - } - FAIL_IF(push_inst(compiler, LDP | RT(prev) | RT2(i) | RN(TMP_SP) | offs)); -@@ -1198,7 +1213,12 @@ - - for (i = compiler->scratches; i >= SLJIT_FIRST_SAVED_REG; i--) { - if (prev == -1) { -- prev = i; -+ if (!(offs & (1 << 15))) { -+ prev = i; -+ continue; -+ } -+ FAIL_IF(push_inst(compiler, LDRI | RT(i) | RN(TMP_SP) | (offs >> 5))); -+ offs += 1 << 15; - continue; - } - FAIL_IF(push_inst(compiler, LDP | RT(prev) | RT2(i) | RN(TMP_SP) | offs)); -@@ -1206,13 +1226,12 @@ - prev = -1; - } - -- if (prev != -1) -- FAIL_IF(push_inst(compiler, LDRI | RT(prev) | RN(TMP_SP) | (offs >> 5))); -+ SLJIT_ASSERT(prev == -1); - - if (compiler->local_size <= (63 * sizeof(sljit_sw))) { - FAIL_IF(push_inst(compiler, LDP_PST | 29 | RT2(TMP_LR) - | RN(TMP_SP) | (((local_size >> 3) & 0x7f) << 15))); -- } else { -+ } else if (saved_regs_size > 0) { - FAIL_IF(push_inst(compiler, ADDI | RD(TMP_SP) | RN(TMP_SP) | (saved_regs_size << 10))); - } - -@@ -1242,12 +1261,15 @@ - FAIL_IF(push_inst(compiler, ORR | RD(TMP_REG1) | RN(TMP_ZERO) | RM(SLJIT_R0))); - FAIL_IF(push_inst(compiler, MADD | RD(SLJIT_R0) | RN(SLJIT_R0) | RM(SLJIT_R1) | RT2(TMP_ZERO))); - return push_inst(compiler, (op == SLJIT_LUMUL ? UMULH : SMULH) | RD(SLJIT_R1) | RN(TMP_REG1) | RM(SLJIT_R1)); -- case SLJIT_LUDIV: -- case SLJIT_LSDIV: -+ case SLJIT_UDIVMOD: -+ case SLJIT_SDIVMOD: - FAIL_IF(push_inst(compiler, (ORR ^ inv_bits) | RD(TMP_REG1) | RN(TMP_ZERO) | RM(SLJIT_R0))); -- FAIL_IF(push_inst(compiler, ((op == SLJIT_LUDIV ? UDIV : SDIV) ^ inv_bits) | RD(SLJIT_R0) | RN(SLJIT_R0) | RM(SLJIT_R1))); -+ FAIL_IF(push_inst(compiler, ((op == SLJIT_UDIVMOD ? UDIV : SDIV) ^ inv_bits) | RD(SLJIT_R0) | RN(SLJIT_R0) | RM(SLJIT_R1))); - FAIL_IF(push_inst(compiler, (MADD ^ inv_bits) | RD(SLJIT_R1) | RN(SLJIT_R0) | RM(SLJIT_R1) | RT2(TMP_ZERO))); - return push_inst(compiler, (SUB ^ inv_bits) | RD(SLJIT_R1) | RN(TMP_REG1) | RM(SLJIT_R1)); -+ case SLJIT_UDIVI: -+ case SLJIT_SDIVI: -+ return push_inst(compiler, ((op == SLJIT_UDIVI ? UDIV : SDIV) ^ inv_bits) | RD(SLJIT_R0) | RN(SLJIT_R0) | RM(SLJIT_R1)); - } - - return SLJIT_SUCCESS; -Index: sljit/sljitNativeARM_T2_32.c -=================================================================== ---- sljit/sljitNativeARM_T2_32.c (revision 1554) -+++ sljit/sljitNativeARM_T2_32.c (working copy) -@@ -1239,6 +1239,9 @@ - - SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op) - { -+ sljit_sw saved_reg_list[3]; -+ sljit_sw saved_reg_count; -+ - CHECK_ERROR(); - CHECK(check_sljit_emit_op0(compiler, op)); - -@@ -1255,24 +1258,53 @@ - | (reg_map[SLJIT_R0] << 12) - | (reg_map[SLJIT_R0] << 16) - | reg_map[SLJIT_R1]); -- case SLJIT_LUDIV: -- case SLJIT_LSDIV: -- if (compiler->scratches >= 4) { -- FAIL_IF(push_inst32(compiler, 0xf84d2d04 /* str r2, [sp, #-4]! */)); -- FAIL_IF(push_inst32(compiler, 0xf84dcd04 /* str ip, [sp, #-4]! */)); -- } else if (compiler->scratches >= 3) -- FAIL_IF(push_inst32(compiler, 0xf84d2d08 /* str r2, [sp, #-8]! */)); -+ case SLJIT_UDIVMOD: -+ case SLJIT_SDIVMOD: -+ case SLJIT_UDIVI: -+ case SLJIT_SDIVI: -+ SLJIT_COMPILE_ASSERT((SLJIT_UDIVMOD & 0x2) == 0 && SLJIT_UDIVI - 0x2 == SLJIT_UDIVMOD, bad_div_opcode_assignments); -+ SLJIT_COMPILE_ASSERT(reg_map[2] == 1 && reg_map[3] == 2 && reg_map[4] == 12, bad_register_mapping); -+ -+ saved_reg_count = 0; -+ if (compiler->scratches >= 4) -+ saved_reg_list[saved_reg_count++] = 12; -+ if (compiler->scratches >= 3) -+ saved_reg_list[saved_reg_count++] = 2; -+ if (op >= SLJIT_UDIVI) -+ saved_reg_list[saved_reg_count++] = 1; -+ -+ if (saved_reg_count > 0) { -+ FAIL_IF(push_inst32(compiler, 0xf84d0d00 | (saved_reg_count >= 3 ? 16 : 8) -+ | (saved_reg_list[0] << 12) /* str rX, [sp, #-8/-16]! */)); -+ if (saved_reg_count >= 2) { -+ SLJIT_ASSERT(saved_reg_list[1] < 8); -+ FAIL_IF(push_inst16(compiler, 0x9001 | (saved_reg_list[1] << 8) /* str rX, [sp, #4] */)); -+ } -+ if (saved_reg_count >= 3) { -+ SLJIT_ASSERT(saved_reg_list[2] < 8); -+ FAIL_IF(push_inst16(compiler, 0x9002 | (saved_reg_list[2] << 8) /* str rX, [sp, #8] */)); -+ } -+ } -+ - #if defined(__GNUC__) - FAIL_IF(sljit_emit_ijump(compiler, SLJIT_FAST_CALL, SLJIT_IMM, -- (op == SLJIT_LUDIV ? SLJIT_FUNC_OFFSET(__aeabi_uidivmod) : SLJIT_FUNC_OFFSET(__aeabi_idivmod)))); -+ ((op | 0x2) == SLJIT_UDIVI ? SLJIT_FUNC_OFFSET(__aeabi_uidivmod) : SLJIT_FUNC_OFFSET(__aeabi_idivmod)))); - #else - #error "Software divmod functions are needed" - #endif -- if (compiler->scratches >= 4) { -- FAIL_IF(push_inst32(compiler, 0xf85dcb04 /* ldr ip, [sp], #4 */)); -- return push_inst32(compiler, 0xf85d2b04 /* ldr r2, [sp], #4 */); -- } else if (compiler->scratches >= 3) -- return push_inst32(compiler, 0xf85d2b08 /* ldr r2, [sp], #8 */); -+ -+ if (saved_reg_count > 0) { -+ if (saved_reg_count >= 3) { -+ SLJIT_ASSERT(saved_reg_list[2] < 8); -+ FAIL_IF(push_inst16(compiler, 0x9802 | (saved_reg_list[2] << 8) /* ldr rX, [sp, #8] */)); -+ } -+ if (saved_reg_count >= 2) { -+ SLJIT_ASSERT(saved_reg_list[1] < 8); -+ FAIL_IF(push_inst16(compiler, 0x9801 | (saved_reg_list[1] << 8) /* ldr rX, [sp, #4] */)); -+ } -+ return push_inst32(compiler, 0xf85d0b00 | (saved_reg_count >= 3 ? 16 : 8) -+ | (saved_reg_list[0] << 12) /* ldr rX, [sp], #8/16 */); -+ } - return SLJIT_SUCCESS; - } - -Index: sljit/sljitNativePPC_common.c -=================================================================== ---- sljit/sljitNativePPC_common.c (revision 1554) -+++ sljit/sljitNativePPC_common.c (working copy) -@@ -1267,22 +1267,23 @@ - FAIL_IF(push_inst(compiler, MULLW | D(SLJIT_R0) | A(TMP_REG1) | B(SLJIT_R1))); - return push_inst(compiler, (op == SLJIT_LUMUL ? MULHWU : MULHW) | D(SLJIT_R1) | A(TMP_REG1) | B(SLJIT_R1)); - #endif -- case SLJIT_LUDIV: -- case SLJIT_LSDIV: -+ case SLJIT_UDIVMOD: -+ case SLJIT_SDIVMOD: - FAIL_IF(push_inst(compiler, OR | S(SLJIT_R0) | A(TMP_REG1) | B(SLJIT_R0))); - #if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64) -- if (int_op) { -- FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? DIVWU : DIVW) | D(SLJIT_R0) | A(TMP_REG1) | B(SLJIT_R1))); -- FAIL_IF(push_inst(compiler, MULLW | D(SLJIT_R1) | A(SLJIT_R0) | B(SLJIT_R1))); -- } else { -- FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? DIVDU : DIVD) | D(SLJIT_R0) | A(TMP_REG1) | B(SLJIT_R1))); -- FAIL_IF(push_inst(compiler, MULLD | D(SLJIT_R1) | A(SLJIT_R0) | B(SLJIT_R1))); -- } -- return push_inst(compiler, SUBF | D(SLJIT_R1) | A(SLJIT_R1) | B(TMP_REG1)); -+ FAIL_IF(push_inst(compiler, (int_op ? (op == SLJIT_UDIVMOD ? DIVWU : DIVW) : (op == SLJIT_UDIVMOD ? DIVDU : DIVD)) | D(SLJIT_R0) | A(SLJIT_R0) | B(SLJIT_R1))); -+ FAIL_IF(push_inst(compiler, (int_op ? MULLW : MULLD) | D(SLJIT_R1) | A(SLJIT_R0) | B(SLJIT_R1))); - #else -- FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? DIVWU : DIVW) | D(SLJIT_R0) | A(TMP_REG1) | B(SLJIT_R1))); -+ FAIL_IF(push_inst(compiler, (op == SLJIT_UDIVMOD ? DIVWU : DIVW) | D(SLJIT_R0) | A(SLJIT_R0) | B(SLJIT_R1))); - FAIL_IF(push_inst(compiler, MULLW | D(SLJIT_R1) | A(SLJIT_R0) | B(SLJIT_R1))); -+#endif - return push_inst(compiler, SUBF | D(SLJIT_R1) | A(SLJIT_R1) | B(TMP_REG1)); -+ case SLJIT_UDIVI: -+ case SLJIT_SDIVI: -+#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64) -+ return push_inst(compiler, (int_op ? (op == SLJIT_UDIVI ? DIVWU : DIVW) : (op == SLJIT_UDIVI ? DIVDU : DIVD)) | D(SLJIT_R0) | A(SLJIT_R0) | B(SLJIT_R1)); -+#else -+ return push_inst(compiler, (op == SLJIT_UDIVI ? DIVWU : DIVW) | D(SLJIT_R0) | A(SLJIT_R0) | B(SLJIT_R1)); - #endif - } - -Index: sljit/sljitNativeX86_common.c -=================================================================== ---- sljit/sljitNativeX86_common.c (revision 1554) -+++ sljit/sljitNativeX86_common.c (working copy) -@@ -273,7 +273,9 @@ - #endif - static sljit_si cpu_has_cmov = -1; - --#if defined(_MSC_VER) && _MSC_VER >= 1400 -+#ifdef _WIN32_WCE -+#include -+#elif defined(_MSC_VER) && _MSC_VER >= 1400 - #include - #endif - -@@ -742,8 +744,10 @@ - break; - case SLJIT_LUMUL: - case SLJIT_LSMUL: -- case SLJIT_LUDIV: -- case SLJIT_LSDIV: -+ case SLJIT_UDIVMOD: -+ case SLJIT_SDIVMOD: -+ case SLJIT_UDIVI: -+ case SLJIT_SDIVI: - compiler->flags_saved = 0; - #if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) - #ifdef _WIN64 -@@ -761,9 +765,10 @@ - #endif - compiler->mode32 = op & SLJIT_INT_OP; - #endif -+ SLJIT_COMPILE_ASSERT((SLJIT_UDIVMOD & 0x2) == 0 && SLJIT_UDIVI - 0x2 == SLJIT_UDIVMOD, bad_div_opcode_assignments); - - op = GET_OPCODE(op); -- if (op == SLJIT_LUDIV) { -+ if ((op | 0x2) == SLJIT_UDIVI) { - #if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || defined(_WIN64) - EMIT_MOV(compiler, TMP_REG1, 0, SLJIT_R1, 0); - inst = emit_x86_instruction(compiler, 1, SLJIT_R1, 0, SLJIT_R1, 0); -@@ -774,7 +779,7 @@ - *inst = XOR_r_rm; - } - -- if (op == SLJIT_LSDIV) { -+ if ((op | 0x2) == SLJIT_SDIVI) { - #if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || defined(_WIN64) - EMIT_MOV(compiler, TMP_REG1, 0, SLJIT_R1, 0); - #endif -@@ -805,10 +810,10 @@ - FAIL_IF(!inst); - INC_SIZE(2); - *inst++ = GROUP_F7; -- *inst = MOD_REG | ((op >= SLJIT_LUDIV) ? reg_map[TMP_REG1] : reg_map[SLJIT_R1]); -+ *inst = MOD_REG | ((op >= SLJIT_UDIVMOD) ? reg_map[TMP_REG1] : reg_map[SLJIT_R1]); - #else - #ifdef _WIN64 -- size = (!compiler->mode32 || op >= SLJIT_LUDIV) ? 3 : 2; -+ size = (!compiler->mode32 || op >= SLJIT_UDIVMOD) ? 3 : 2; - #else - size = (!compiler->mode32) ? 3 : 2; - #endif -@@ -817,11 +822,11 @@ - INC_SIZE(size); - #ifdef _WIN64 - if (!compiler->mode32) -- *inst++ = REX_W | ((op >= SLJIT_LUDIV) ? REX_B : 0); -- else if (op >= SLJIT_LUDIV) -+ *inst++ = REX_W | ((op >= SLJIT_UDIVMOD) ? REX_B : 0); -+ else if (op >= SLJIT_UDIVMOD) - *inst++ = REX_B; - *inst++ = GROUP_F7; -- *inst = MOD_REG | ((op >= SLJIT_LUDIV) ? reg_lmap[TMP_REG1] : reg_lmap[SLJIT_R1]); -+ *inst = MOD_REG | ((op >= SLJIT_UDIVMOD) ? reg_lmap[TMP_REG1] : reg_lmap[SLJIT_R1]); - #else - if (!compiler->mode32) - *inst++ = REX_W; -@@ -836,15 +841,21 @@ - case SLJIT_LSMUL: - *inst |= IMUL; - break; -- case SLJIT_LUDIV: -+ case SLJIT_UDIVMOD: -+ case SLJIT_UDIVI: - *inst |= DIV; - break; -- case SLJIT_LSDIV: -+ case SLJIT_SDIVMOD: -+ case SLJIT_SDIVI: - *inst |= IDIV; - break; - } - #if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) && !defined(_WIN64) -- EMIT_MOV(compiler, SLJIT_R1, 0, TMP_REG1, 0); -+ if (op <= SLJIT_SDIVMOD) -+ EMIT_MOV(compiler, SLJIT_R1, 0, TMP_REG1, 0); -+#else -+ if (op >= SLJIT_UDIVI) -+ EMIT_MOV(compiler, SLJIT_R1, 0, TMP_REG1, 0); - #endif - break; - } -@@ -1905,60 +1916,62 @@ - return SLJIT_SUCCESS; - } - -- if (FAST_IS_REG(src1)) { -+ if (!(src1 & SLJIT_IMM)) { - if (src2 & SLJIT_IMM) { - #if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) - if (IS_HALFWORD(src2w) || compiler->mode32) { -- inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, 0); -+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, src1w); - FAIL_IF(!inst); - *inst = GROUP_F7; - } - else { - FAIL_IF(emit_load_imm64(compiler, TMP_REG2, src2w)); -- inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, src1, 0); -+ inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, src1, src1w); - FAIL_IF(!inst); - *inst = TEST_rm_r; - } - #else -- inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, 0); -+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, src1w); - FAIL_IF(!inst); - *inst = GROUP_F7; - #endif -+ return SLJIT_SUCCESS; - } -- else { -+ else if (FAST_IS_REG(src1)) { - inst = emit_x86_instruction(compiler, 1, src1, 0, src2, src2w); - FAIL_IF(!inst); - *inst = TEST_rm_r; -+ return SLJIT_SUCCESS; - } -- return SLJIT_SUCCESS; - } - -- if (FAST_IS_REG(src2)) { -+ if (!(src2 & SLJIT_IMM)) { - if (src1 & SLJIT_IMM) { - #if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) - if (IS_HALFWORD(src1w) || compiler->mode32) { -- inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src1w, src2, 0); -+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src1w, src2, src2w); - FAIL_IF(!inst); - *inst = GROUP_F7; - } - else { - FAIL_IF(emit_load_imm64(compiler, TMP_REG2, src1w)); -- inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, src2, 0); -+ inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, src2, src2w); - FAIL_IF(!inst); - *inst = TEST_rm_r; - } - #else -- inst = emit_x86_instruction(compiler, 1, src1, src1w, src2, 0); -+ inst = emit_x86_instruction(compiler, 1, src1, src1w, src2, src2w); - FAIL_IF(!inst); - *inst = GROUP_F7; - #endif -+ return SLJIT_SUCCESS; - } -- else { -+ else if (FAST_IS_REG(src2)) { - inst = emit_x86_instruction(compiler, 1, src2, 0, src1, src1w); - FAIL_IF(!inst); - *inst = TEST_rm_r; -+ return SLJIT_SUCCESS; - } -- return SLJIT_SUCCESS; - } - - EMIT_MOV(compiler, TMP_REG1, 0, src1, src1w); -@@ -2923,3 +2936,69 @@ - { - *(sljit_sw*)addr = new_constant; - } -+ -+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_x86_is_sse2_available(void) -+{ -+#if (defined SLJIT_DETECT_SSE2 && SLJIT_DETECT_SSE2) -+ if (cpu_has_sse2 == -1) -+ get_cpu_features(); -+ return cpu_has_sse2; -+#else -+ return 1; -+#endif -+} -+ -+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_x86_is_cmov_available(void) -+{ -+ if (cpu_has_cmov == -1) -+ get_cpu_features(); -+ return cpu_has_cmov; -+} -+ -+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_x86_emit_cmov(struct sljit_compiler *compiler, -+ sljit_si type, -+ sljit_si dst_reg, -+ sljit_si src, sljit_sw srcw) -+{ -+ sljit_ub* inst; -+ -+ CHECK_ERROR(); -+#if (defined SLJIT_ARGUMENT_CHECKS && SLJIT_ARGUMENT_CHECKS) -+ CHECK_ARGUMENT(sljit_x86_is_cmov_available()); -+ CHECK_ARGUMENT(!(type & ~(0xff | SLJIT_INT_OP))); -+ CHECK_ARGUMENT((type & 0xff) >= SLJIT_EQUAL && (type & 0xff) <= SLJIT_D_ORDERED); -+ CHECK_ARGUMENT(FUNCTION_CHECK_IS_REG(dst_reg & ~SLJIT_INT_OP)); -+ FUNCTION_CHECK_SRC(src, srcw); -+#endif -+#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) -+ if (SLJIT_UNLIKELY(!!compiler->verbose)) { -+ fprintf(compiler->verbose, " x86_cmov%s %s%s, ", -+ !(dst_reg & SLJIT_INT_OP) ? "" : ".i", -+ JUMP_PREFIX(type), jump_names[type & 0xff]); -+ sljit_verbose_reg(compiler, dst_reg & ~SLJIT_INT_OP); -+ fprintf(compiler->verbose, ", "); -+ sljit_verbose_param(compiler, src, srcw); -+ fprintf(compiler->verbose, "\n"); -+ } -+#endif -+ -+ ADJUST_LOCAL_OFFSET(src, srcw); -+ CHECK_EXTRA_REGS(src, srcw, (void)0); -+ -+#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) -+ compiler->mode32 = dst_reg & SLJIT_INT_OP; -+#endif -+ dst_reg &= ~SLJIT_INT_OP; -+ -+ if (SLJIT_UNLIKELY(src & SLJIT_IMM)) { -+ EMIT_MOV(compiler, TMP_REG1, 0, SLJIT_IMM, srcw); -+ src = TMP_REG1; -+ srcw = 0; -+ } -+ -+ inst = emit_x86_instruction(compiler, 2, dst_reg, 0, src, srcw); -+ FAIL_IF(!inst); -+ *inst++ = GROUP_0F; -+ *inst = get_jump_code(type & 0xff) - 0x40; -+ return SLJIT_SUCCESS; -+} -Index: sljit/sljitConfigInternal.h -=================================================================== ---- sljit/sljitConfigInternal.h (revision 1554) -+++ sljit/sljitConfigInternal.h (working copy) -@@ -468,8 +468,13 @@ - - #ifndef SLJIT_CALL - --#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) -+#if (defined SLJIT_USE_CDECL_CALLING_CONVENTION && SLJIT_USE_CDECL_CALLING_CONVENTION) - -+/* Force cdecl. */ -+#define SLJIT_CALL -+ -+#elif (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) -+ - #if defined(__GNUC__) && !defined(__APPLE__) - - #define SLJIT_CALL __attribute__ ((fastcall)) -@@ -608,6 +613,12 @@ - #define SLJIT_LOCALS_OFFSET_BASE ((23 + 1) * sizeof(sljit_sw)) - #endif - -+#elif (defined SLJIT_CONFIG_TILEGX && SLJIT_CONFIG_TILEGX) -+ -+#define SLJIT_NUMBER_OF_REGISTERS 10 -+#define SLJIT_NUMBER_OF_SAVED_REGISTERS 5 -+#define SLJIT_LOCALS_OFFSET_BASE 0 -+ - #elif (defined SLJIT_CONFIG_UNSUPPORTED && SLJIT_CONFIG_UNSUPPORTED) - - #define SLJIT_NUMBER_OF_REGISTERS 0 -Index: sljit/sljitConfig.h -=================================================================== ---- sljit/sljitConfig.h (revision 1554) -+++ sljit/sljitConfig.h (working copy) -@@ -96,6 +96,15 @@ - #define SLJIT_EXECUTABLE_ALLOCATOR 1 - #endif - -+/* Force cdecl calling convention even if a better calling -+ convention (e.g. fastcall) is supported by the C compiler. -+ If this option is enabled, C functions without -+ SLJIT_CALL can also be called from JIT code. */ -+#ifndef SLJIT_USE_CDECL_CALLING_CONVENTION -+/* Disabled by default */ -+#define SLJIT_USE_CDECL_CALLING_CONVENTION 0 -+#endif -+ - /* Return with error when an invalid argument is passed. */ - #ifndef SLJIT_ARGUMENT_CHECKS - /* Disabled by default */ -Index: sljit/sljitNativeTILEGX_64.c -=================================================================== ---- sljit/sljitNativeTILEGX_64.c (revision 1554) -+++ sljit/sljitNativeTILEGX_64.c (working copy) -@@ -35,21 +35,21 @@ - #define SIMM_16BIT_MIN (-0x8000) - #define SIMM_17BIT_MAX (0xffff) - #define SIMM_17BIT_MIN (-0x10000) --#define SIMM_32BIT_MIN (-0x80000000) - #define SIMM_32BIT_MAX (0x7fffffff) --#define SIMM_48BIT_MIN (0x800000000000L) -+#define SIMM_32BIT_MIN (-0x7fffffff - 1) - #define SIMM_48BIT_MAX (0x7fffffff0000L) -+#define SIMM_48BIT_MIN (-0x800000000000L) - #define IMM16(imm) ((imm) & 0xffff) - - #define UIMM_16BIT_MAX (0xffff) - --#define TMP_REG1 (SLJIT_NO_REGISTERS + 1) --#define TMP_REG2 (SLJIT_NO_REGISTERS + 2) --#define TMP_REG3 (SLJIT_NO_REGISTERS + 3) --#define ADDR_TMP (SLJIT_NO_REGISTERS + 4) -+#define TMP_REG1 (SLJIT_NUMBER_OF_REGISTERS + 2) -+#define TMP_REG2 (SLJIT_NUMBER_OF_REGISTERS + 3) -+#define TMP_REG3 (SLJIT_NUMBER_OF_REGISTERS + 4) -+#define ADDR_TMP (SLJIT_NUMBER_OF_REGISTERS + 5) - #define PIC_ADDR_REG TMP_REG2 - --static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 5] = { -+static SLJIT_CONST sljit_ub reg_map[SLJIT_NUMBER_OF_REGISTERS + 6] = { - 63, 0, 1, 2, 3, 4, 30, 31, 32, 33, 34, 54, 5, 16, 6, 7 - }; - -@@ -58,11 +58,6 @@ - #define TMP_REG2_mapped 16 - #define TMP_REG3_mapped 6 - #define ADDR_TMP_mapped 7 --#define SLJIT_SAVED_REG1_mapped 30 --#define SLJIT_SAVED_REG2_mapped 31 --#define SLJIT_SAVED_REG3_mapped 32 --#define SLJIT_SAVED_EREG1_mapped 33 --#define SLJIT_SAVED_EREG2_mapped 34 - - /* Flags are keept in volatile registers. */ - #define EQUAL_FLAG 8 -@@ -399,6 +394,9 @@ - #define SUB(dst, srca, srcb) \ - push_3_buffer(compiler, TILEGX_OPC_SUB, dst, srca, srcb, __LINE__) - -+#define MUL(dst, srca, srcb) \ -+ push_3_buffer(compiler, TILEGX_OPC_MULX, dst, srca, srcb, __LINE__) -+ - #define NOR(dst, srca, srcb) \ - push_3_buffer(compiler, TILEGX_OPC_NOR, dst, srca, srcb, __LINE__) - -@@ -547,8 +545,8 @@ - - const struct Format* match = NULL; - const struct Format *b = NULL; -- unsigned int i = 0; -- for (i; i < sizeof formats / sizeof formats[0]; i++) { -+ unsigned int i; -+ for (i = 0; i < sizeof formats / sizeof formats[0]; i++) { - b = &formats[i]; - if ((b->pipe_mask & compatible_pipes) == b->pipe_mask) { - match = b; -@@ -625,7 +623,6 @@ - - static sljit_si update_buffer(struct sljit_compiler *compiler) - { -- int count; - int i; - int orig_index = inst_buf_index; - struct jit_instr inst0 = inst_buf[0]; -@@ -738,8 +735,10 @@ - - static sljit_si flush_buffer(struct sljit_compiler *compiler) - { -- while (inst_buf_index != 0) -- update_buffer(compiler); -+ while (inst_buf_index != 0) { -+ FAIL_IF(update_buffer(compiler)); -+ } -+ return SLJIT_SUCCESS; - } - - static sljit_si push_4_buffer(struct sljit_compiler *compiler, tilegx_mnemonic opc, int op0, int op1, int op2, int op3, int line) -@@ -787,6 +786,7 @@ - case TILEGX_OPC_ADD: - case TILEGX_OPC_AND: - case TILEGX_OPC_SUB: -+ case TILEGX_OPC_MULX: - case TILEGX_OPC_OR: - case TILEGX_OPC_XOR: - case TILEGX_OPC_NOR: -@@ -905,7 +905,6 @@ - sljit_sw diff; - sljit_uw target_addr; - sljit_ins *inst; -- sljit_ins saved_inst; - - if (jump->flags & SLJIT_REWRITABLE_JUMP) - return code_ptr; -@@ -1009,7 +1008,7 @@ - struct sljit_const *const_; - - CHECK_ERROR_PTR(); -- check_sljit_generate_code(compiler); -+ CHECK_PTR(check_sljit_generate_code(compiler)); - reverse_buf(compiler); - - code = (sljit_ins *)SLJIT_MALLOC_EXEC(compiler->size * sizeof(sljit_ins)); -@@ -1178,13 +1177,13 @@ - sljit_si fscratches, sljit_si fsaveds, sljit_si local_size) - { - sljit_ins base; -- sljit_ins bundle = 0; -- -+ sljit_si i, tmp; -+ - CHECK_ERROR(); -- check_sljit_emit_enter(compiler, options, args, scratches, saveds, fscratches, fsaveds, local_size); -+ CHECK(check_sljit_emit_enter(compiler, options, args, scratches, saveds, fscratches, fsaveds, local_size)); - set_emit_enter(compiler, options, args, scratches, saveds, fscratches, fsaveds, local_size); - -- local_size += (saveds + 1) * sizeof(sljit_sw); -+ local_size += GET_SAVED_REGISTERS_SIZE(scratches, saveds, 1); - local_size = (local_size + 7) & ~7; - compiler->local_size = local_size; - -@@ -1200,46 +1199,41 @@ - local_size = 0; - } - -+ /* Save the return address. */ - FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 8)); - FAIL_IF(ST_ADD(ADDR_TMP_mapped, RA, -8)); - -- if (saveds >= 1) -- FAIL_IF(ST_ADD(ADDR_TMP_mapped, SLJIT_SAVED_REG1_mapped, -8)); -+ /* Save the S registers. */ -+ tmp = saveds < SLJIT_NUMBER_OF_SAVED_REGISTERS ? (SLJIT_S0 + 1 - saveds) : SLJIT_FIRST_SAVED_REG; -+ for (i = SLJIT_S0; i >= tmp; i--) { -+ FAIL_IF(ST_ADD(ADDR_TMP_mapped, reg_map[i], -8)); -+ } - -- if (saveds >= 2) -- FAIL_IF(ST_ADD(ADDR_TMP_mapped, SLJIT_SAVED_REG2_mapped, -8)); -+ /* Save the R registers that need to be reserved. */ -+ for (i = scratches; i >= SLJIT_FIRST_SAVED_REG; i--) { -+ FAIL_IF(ST_ADD(ADDR_TMP_mapped, reg_map[i], -8)); -+ } - -- if (saveds >= 3) -- FAIL_IF(ST_ADD(ADDR_TMP_mapped, SLJIT_SAVED_REG3_mapped, -8)); -+ /* Move the arguments to S registers. */ -+ for (i = 0; i < args; i++) { -+ FAIL_IF(ADD(reg_map[SLJIT_S0 - i], i, ZERO)); -+ } - -- if (saveds >= 4) -- FAIL_IF(ST_ADD(ADDR_TMP_mapped, SLJIT_SAVED_EREG1_mapped, -8)); -- -- if (saveds >= 5) -- FAIL_IF(ST_ADD(ADDR_TMP_mapped, SLJIT_SAVED_EREG2_mapped, -8)); -- -- if (args >= 1) -- FAIL_IF(ADD(SLJIT_SAVED_REG1_mapped, 0, ZERO)); -- -- if (args >= 2) -- FAIL_IF(ADD(SLJIT_SAVED_REG2_mapped, 1, ZERO)); -- -- if (args >= 3) -- FAIL_IF(ADD(SLJIT_SAVED_REG3_mapped, 2, ZERO)); -- - return SLJIT_SUCCESS; - } - --SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, -+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_set_context(struct sljit_compiler *compiler, - sljit_si options, sljit_si args, sljit_si scratches, sljit_si saveds, - sljit_si fscratches, sljit_si fsaveds, sljit_si local_size) - { -- CHECK_ERROR_VOID(); -- check_sljit_set_context(compiler, options, args, scratches, saveds, fscratches, fsaveds, local_size); -+ CHECK_ERROR(); -+ CHECK(check_sljit_set_context(compiler, options, args, scratches, saveds, fscratches, fsaveds, local_size)); - set_set_context(compiler, options, args, scratches, saveds, fscratches, fsaveds, local_size); - -- local_size += (saveds + 1) * sizeof(sljit_sw); -+ local_size += GET_SAVED_REGISTERS_SIZE(scratches, saveds, 1); - compiler->local_size = (local_size + 7) & ~7; -+ -+ return SLJIT_SUCCESS; - } - - SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_return(struct sljit_compiler *compiler, sljit_si op, sljit_si src, sljit_sw srcw) -@@ -1246,10 +1240,11 @@ - { - sljit_si local_size; - sljit_ins base; -- int addr_initialized = 0; -+ sljit_si i, tmp; -+ sljit_si saveds; - - CHECK_ERROR(); -- check_sljit_emit_return(compiler, op, src, srcw); -+ CHECK(check_sljit_emit_return(compiler, op, src, srcw)); - - FAIL_IF(emit_mov_before_return(compiler, op, src, srcw)); - -@@ -1263,52 +1258,22 @@ - local_size = 0; - } - -+ /* Restore the return address. */ - FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 8)); -- FAIL_IF(LD(RA, ADDR_TMP_mapped)); -+ FAIL_IF(LD_ADD(RA, ADDR_TMP_mapped, -8)); - -- if (compiler->saveds >= 5) { -- FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 48)); -- addr_initialized = 1; -- -- FAIL_IF(LD_ADD(SLJIT_SAVED_EREG2_mapped, ADDR_TMP_mapped, 8)); -+ /* Restore the S registers. */ -+ saveds = compiler->saveds; -+ tmp = saveds < SLJIT_NUMBER_OF_SAVED_REGISTERS ? (SLJIT_S0 + 1 - saveds) : SLJIT_FIRST_SAVED_REG; -+ for (i = SLJIT_S0; i >= tmp; i--) { -+ FAIL_IF(LD_ADD(reg_map[i], ADDR_TMP_mapped, -8)); - } - -- if (compiler->saveds >= 4) { -- if (addr_initialized == 0) { -- FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 40)); -- addr_initialized = 1; -- } -- -- FAIL_IF(LD_ADD(SLJIT_SAVED_EREG1_mapped, ADDR_TMP_mapped, 8)); -+ /* Restore the R registers that need to be reserved. */ -+ for (i = compiler->scratches; i >= SLJIT_FIRST_SAVED_REG; i--) { -+ FAIL_IF(LD_ADD(reg_map[i], ADDR_TMP_mapped, -8)); - } - -- if (compiler->saveds >= 3) { -- if (addr_initialized == 0) { -- FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 32)); -- addr_initialized = 1; -- } -- -- FAIL_IF(LD_ADD(SLJIT_SAVED_REG3_mapped, ADDR_TMP_mapped, 8)); -- } -- -- if (compiler->saveds >= 2) { -- if (addr_initialized == 0) { -- FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 24)); -- addr_initialized = 1; -- } -- -- FAIL_IF(LD_ADD(SLJIT_SAVED_REG2_mapped, ADDR_TMP_mapped, 8)); -- } -- -- if (compiler->saveds >= 1) { -- if (addr_initialized == 0) { -- FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 16)); -- /* addr_initialized = 1; no need to initialize as it's the last one. */ -- } -- -- FAIL_IF(LD_ADD(SLJIT_SAVED_REG1_mapped, ADDR_TMP_mapped, 8)); -- } -- - if (compiler->local_size <= SIMM_16BIT_MAX) - FAIL_IF(ADDLI(SLJIT_LOCALS_REG_mapped, SLJIT_LOCALS_REG_mapped, compiler->local_size)); - else -@@ -1585,7 +1550,7 @@ - SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_enter(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw) - { - CHECK_ERROR(); -- check_sljit_emit_fast_enter(compiler, dst, dstw); -+ CHECK(check_sljit_emit_fast_enter(compiler, dst, dstw)); - ADJUST_LOCAL_OFFSET(dst, dstw); - - /* For UNUSED dst. Uncommon, but possible. */ -@@ -1602,7 +1567,7 @@ - SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_return(struct sljit_compiler *compiler, sljit_si src, sljit_sw srcw) - { - CHECK_ERROR(); -- check_sljit_emit_fast_return(compiler, src, srcw); -+ CHECK(check_sljit_emit_fast_return(compiler, src, srcw)); - ADJUST_LOCAL_OFFSET(src, srcw); - - if (FAST_IS_REG(src)) -@@ -1636,9 +1601,11 @@ - if (op == SLJIT_MOV_SI) - return BFEXTS(reg_map[dst], reg_map[src2], 0, 31); - -- return BFEXTU(reg_map[dst], reg_map[src2], 0, 31); -- } else if (dst != src2) -- SLJIT_ASSERT_STOP(); -+ return BFEXTU(reg_map[dst], reg_map[src2], 0, 31); -+ } else if (dst != src2) { -+ SLJIT_ASSERT(src2 == 0); -+ return ADD(reg_map[dst], reg_map[src2], ZERO); -+ } - - return SLJIT_SUCCESS; - -@@ -1650,8 +1617,10 @@ - return BFEXTS(reg_map[dst], reg_map[src2], 0, 7); - - return BFEXTU(reg_map[dst], reg_map[src2], 0, 7); -- } else if (dst != src2) -- SLJIT_ASSERT_STOP(); -+ } else if (dst != src2) { -+ SLJIT_ASSERT(src2 == 0); -+ return ADD(reg_map[dst], reg_map[src2], ZERO); -+ } - - return SLJIT_SUCCESS; - -@@ -1663,8 +1632,10 @@ - return BFEXTS(reg_map[dst], reg_map[src2], 0, 15); - - return BFEXTU(reg_map[dst], reg_map[src2], 0, 15); -- } else if (dst != src2) -- SLJIT_ASSERT_STOP(); -+ } else if (dst != src2) { -+ SLJIT_ASSERT(src2 == 0); -+ return ADD(reg_map[dst], reg_map[src2], ZERO); -+ } - - return SLJIT_SUCCESS; - -@@ -1811,7 +1782,6 @@ - else { - /* Rare ocasion. */ - FAIL_IF(ADD(TMP_EREG2, reg_map[src1], ZERO)); -- - overflow_ra = TMP_EREG2; - } - } -@@ -1903,6 +1873,17 @@ - - return SLJIT_SUCCESS; - -+ case SLJIT_MUL: -+ if (flags & SRC2_IMM) { -+ FAIL_IF(load_immediate(compiler, TMP_REG2_mapped, src2)); -+ src2 = TMP_REG2; -+ flags &= ~SRC2_IMM; -+ } -+ -+ FAIL_IF(MUL(reg_map[dst], reg_map[src1], reg_map[src2])); -+ -+ return SLJIT_SUCCESS; -+ - #define EMIT_LOGICAL(op_imm, op_norm) \ - if (flags & SRC2_IMM) { \ - FAIL_IF(load_immediate(compiler, ADDR_TMP_mapped, src2)); \ -@@ -1950,8 +1931,8 @@ - } else { \ - if (op & SLJIT_SET_E) \ - FAIL_IF(push_3_buffer( \ -- compiler, op_imm, reg_map[dst], reg_map[src1], \ -- src2 & 0x3F, __LINE__)); \ -+ compiler, op_norm, EQUAL_FLAG, reg_map[src1], \ -+ reg_map[src2], __LINE__)); \ - if (CHECK_FLAGS(SLJIT_SET_E)) \ - FAIL_IF(push_3_buffer( \ - compiler, op_norm, reg_map[dst], reg_map[src1], \ -@@ -2105,9 +2086,10 @@ - { - sljit_si sugg_dst_ar, dst_ar; - sljit_si flags = GET_ALL_FLAGS(op); -+ sljit_si mem_type = (op & SLJIT_INT_OP) ? (INT_DATA | SIGNED_DATA) : WORD_DATA; - - CHECK_ERROR(); -- check_sljit_emit_op_flags(compiler, op, dst, dstw, src, srcw, type); -+ CHECK(check_sljit_emit_op_flags(compiler, op, dst, dstw, src, srcw, type)); - ADJUST_LOCAL_OFFSET(dst, dstw); - - if (dst == SLJIT_UNUSED) -@@ -2114,6 +2096,8 @@ - return SLJIT_SUCCESS; - - op = GET_OPCODE(op); -+ if (op == SLJIT_MOV_SI || op == SLJIT_MOV_UI) -+ mem_type = INT_DATA | SIGNED_DATA; - sugg_dst_ar = reg_map[(op < SLJIT_ADD && FAST_IS_REG(dst)) ? dst : TMP_REG2]; - - compiler->cache_arg = 0; -@@ -2120,51 +2104,43 @@ - compiler->cache_argw = 0; - if (op >= SLJIT_ADD && (src & SLJIT_MEM)) { - ADJUST_LOCAL_OFFSET(src, srcw); -- FAIL_IF(emit_op_mem2(compiler, WORD_DATA | LOAD_DATA, TMP_REG1_mapped, src, srcw, dst, dstw)); -+ FAIL_IF(emit_op_mem2(compiler, mem_type | LOAD_DATA, TMP_REG1_mapped, src, srcw, dst, dstw)); - src = TMP_REG1; - srcw = 0; - } - -- switch (type) { -- case SLJIT_C_EQUAL: -- case SLJIT_C_NOT_EQUAL: -+ switch (type & 0xff) { -+ case SLJIT_EQUAL: -+ case SLJIT_NOT_EQUAL: - FAIL_IF(CMPLTUI(sugg_dst_ar, EQUAL_FLAG, 1)); - dst_ar = sugg_dst_ar; - break; -- case SLJIT_C_LESS: -- case SLJIT_C_GREATER_EQUAL: -- case SLJIT_C_FLOAT_LESS: -- case SLJIT_C_FLOAT_GREATER_EQUAL: -+ case SLJIT_LESS: -+ case SLJIT_GREATER_EQUAL: - dst_ar = ULESS_FLAG; - break; -- case SLJIT_C_GREATER: -- case SLJIT_C_LESS_EQUAL: -- case SLJIT_C_FLOAT_GREATER: -- case SLJIT_C_FLOAT_LESS_EQUAL: -+ case SLJIT_GREATER: -+ case SLJIT_LESS_EQUAL: - dst_ar = UGREATER_FLAG; - break; -- case SLJIT_C_SIG_LESS: -- case SLJIT_C_SIG_GREATER_EQUAL: -+ case SLJIT_SIG_LESS: -+ case SLJIT_SIG_GREATER_EQUAL: - dst_ar = LESS_FLAG; - break; -- case SLJIT_C_SIG_GREATER: -- case SLJIT_C_SIG_LESS_EQUAL: -+ case SLJIT_SIG_GREATER: -+ case SLJIT_SIG_LESS_EQUAL: - dst_ar = GREATER_FLAG; - break; -- case SLJIT_C_OVERFLOW: -- case SLJIT_C_NOT_OVERFLOW: -+ case SLJIT_OVERFLOW: -+ case SLJIT_NOT_OVERFLOW: - dst_ar = OVERFLOW_FLAG; - break; -- case SLJIT_C_MUL_OVERFLOW: -- case SLJIT_C_MUL_NOT_OVERFLOW: -+ case SLJIT_MUL_OVERFLOW: -+ case SLJIT_MUL_NOT_OVERFLOW: - FAIL_IF(CMPLTUI(sugg_dst_ar, OVERFLOW_FLAG, 1)); - dst_ar = sugg_dst_ar; - type ^= 0x1; /* Flip type bit for the XORI below. */ - break; -- case SLJIT_C_FLOAT_EQUAL: -- case SLJIT_C_FLOAT_NOT_EQUAL: -- dst_ar = EQUAL_FLAG; -- break; - - default: - SLJIT_ASSERT_STOP(); -@@ -2180,11 +2156,11 @@ - if (op >= SLJIT_ADD) { - if (TMP_REG2_mapped != dst_ar) - FAIL_IF(ADD(TMP_REG2_mapped, dst_ar, ZERO)); -- return emit_op(compiler, op | flags, CUMULATIVE_OP | LOGICAL_OP | IMM_OP | ALT_KEEP_CACHE, dst, dstw, src, srcw, TMP_REG2, 0); -+ return emit_op(compiler, op | flags, mem_type | CUMULATIVE_OP | LOGICAL_OP | IMM_OP | ALT_KEEP_CACHE, dst, dstw, src, srcw, TMP_REG2, 0); - } - - if (dst & SLJIT_MEM) -- return emit_op_mem(compiler, WORD_DATA, dst_ar, dst, dstw); -+ return emit_op_mem(compiler, mem_type, dst_ar, dst, dstw); - - if (sugg_dst_ar != dst_ar) - return ADD(sugg_dst_ar, dst_ar, ZERO); -@@ -2194,7 +2170,7 @@ - - SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op) { - CHECK_ERROR(); -- check_sljit_emit_op0(compiler, op); -+ CHECK(check_sljit_emit_op0(compiler, op)); - - op = GET_OPCODE(op); - switch (op) { -@@ -2204,10 +2180,10 @@ - case SLJIT_BREAKPOINT: - return PI(BPT); - -- case SLJIT_UMUL: -- case SLJIT_SMUL: -- case SLJIT_UDIV: -- case SLJIT_SDIV: -+ case SLJIT_LUMUL: -+ case SLJIT_LSMUL: -+ case SLJIT_UDIVI: -+ case SLJIT_SDIVI: - SLJIT_ASSERT_STOP(); - } - -@@ -2217,7 +2193,7 @@ - SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op1(struct sljit_compiler *compiler, sljit_si op, sljit_si dst, sljit_sw dstw, sljit_si src, sljit_sw srcw) - { - CHECK_ERROR(); -- check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw); -+ CHECK(check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw)); - ADJUST_LOCAL_OFFSET(dst, dstw); - ADJUST_LOCAL_OFFSET(src, srcw); - -@@ -2273,7 +2249,7 @@ - return emit_op(compiler, SLJIT_SUB | GET_ALL_FLAGS(op), IMM_OP, dst, dstw, SLJIT_IMM, 0, src, srcw); - - case SLJIT_CLZ: -- return emit_op(compiler, op, 0, dst, dstw, TMP_REG1, 0, src, srcw); -+ return emit_op(compiler, op, (op & SLJIT_INT_OP) ? INT_DATA : WORD_DATA, dst, dstw, TMP_REG1, 0, src, srcw); - } - - return SLJIT_SUCCESS; -@@ -2282,7 +2258,7 @@ - SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op2(struct sljit_compiler *compiler, sljit_si op, sljit_si dst, sljit_sw dstw, sljit_si src1, sljit_sw src1w, sljit_si src2, sljit_sw src2w) - { - CHECK_ERROR(); -- check_sljit_emit_op2(compiler, op, dst, dstw, src1, src1w, src2, src2w); -+ CHECK(check_sljit_emit_op2(compiler, op, dst, dstw, src1, src1w, src2, src2w)); - ADJUST_LOCAL_OFFSET(dst, dstw); - ADJUST_LOCAL_OFFSET(src1, src1w); - ADJUST_LOCAL_OFFSET(src2, src2w); -@@ -2325,7 +2301,7 @@ - flush_buffer(compiler); - - CHECK_ERROR_PTR(); -- check_sljit_emit_label(compiler); -+ CHECK_PTR(check_sljit_emit_label(compiler)); - - if (compiler->last_label && compiler->last_label->size == compiler->size) - return compiler->last_label; -@@ -2344,7 +2320,7 @@ - flush_buffer(compiler); - - CHECK_ERROR(); -- check_sljit_emit_ijump(compiler, type, src, srcw); -+ CHECK(check_sljit_emit_ijump(compiler, type, src, srcw)); - ADJUST_LOCAL_OFFSET(src, srcw); - - if (FAST_IS_REG(src)) { -@@ -2404,8 +2380,10 @@ - - return SLJIT_SUCCESS; - -- } else if (src & SLJIT_MEM) -+ } else if (src & SLJIT_MEM) { - FAIL_IF(emit_op(compiler, SLJIT_MOV, WORD_DATA, TMP_REG2, 0, TMP_REG1, 0, src, srcw)); -+ flush_buffer(compiler); -+ } - - FAIL_IF(JR_SOLO(reg_map[src_r])); - -@@ -2432,7 +2410,7 @@ - flush_buffer(compiler); - - CHECK_ERROR_PTR(); -- check_sljit_emit_jump(compiler, type); -+ CHECK_PTR(check_sljit_emit_jump(compiler, type)); - - jump = (struct sljit_jump *)ensure_abuf(compiler, sizeof(struct sljit_jump)); - PTR_FAIL_IF(!jump); -@@ -2440,48 +2418,42 @@ - type &= 0xff; - - switch (type) { -- case SLJIT_C_EQUAL: -- case SLJIT_C_FLOAT_NOT_EQUAL: -+ case SLJIT_EQUAL: - BR_NZ(EQUAL_FLAG); - break; -- case SLJIT_C_NOT_EQUAL: -- case SLJIT_C_FLOAT_EQUAL: -+ case SLJIT_NOT_EQUAL: - BR_Z(EQUAL_FLAG); - break; -- case SLJIT_C_LESS: -- case SLJIT_C_FLOAT_LESS: -+ case SLJIT_LESS: - BR_Z(ULESS_FLAG); - break; -- case SLJIT_C_GREATER_EQUAL: -- case SLJIT_C_FLOAT_GREATER_EQUAL: -+ case SLJIT_GREATER_EQUAL: - BR_NZ(ULESS_FLAG); - break; -- case SLJIT_C_GREATER: -- case SLJIT_C_FLOAT_GREATER: -+ case SLJIT_GREATER: - BR_Z(UGREATER_FLAG); - break; -- case SLJIT_C_LESS_EQUAL: -- case SLJIT_C_FLOAT_LESS_EQUAL: -+ case SLJIT_LESS_EQUAL: - BR_NZ(UGREATER_FLAG); - break; -- case SLJIT_C_SIG_LESS: -+ case SLJIT_SIG_LESS: - BR_Z(LESS_FLAG); - break; -- case SLJIT_C_SIG_GREATER_EQUAL: -+ case SLJIT_SIG_GREATER_EQUAL: - BR_NZ(LESS_FLAG); - break; -- case SLJIT_C_SIG_GREATER: -+ case SLJIT_SIG_GREATER: - BR_Z(GREATER_FLAG); - break; -- case SLJIT_C_SIG_LESS_EQUAL: -+ case SLJIT_SIG_LESS_EQUAL: - BR_NZ(GREATER_FLAG); - break; -- case SLJIT_C_OVERFLOW: -- case SLJIT_C_MUL_OVERFLOW: -+ case SLJIT_OVERFLOW: -+ case SLJIT_MUL_OVERFLOW: - BR_Z(OVERFLOW_FLAG); - break; -- case SLJIT_C_NOT_OVERFLOW: -- case SLJIT_C_MUL_NOT_OVERFLOW: -+ case SLJIT_NOT_OVERFLOW: -+ case SLJIT_MUL_NOT_OVERFLOW: - BR_NZ(OVERFLOW_FLAG); - break; - default: -@@ -2536,7 +2508,7 @@ - flush_buffer(compiler); - - CHECK_ERROR_PTR(); -- check_sljit_emit_const(compiler, dst, dstw, init_value); -+ CHECK_PTR(check_sljit_emit_const(compiler, dst, dstw, init_value)); - ADJUST_LOCAL_OFFSET(dst, dstw); - - const_ = (struct sljit_const *)ensure_abuf(compiler, sizeof(struct sljit_const)); -@@ -2572,3 +2544,18 @@ - inst[3] = (inst[3] & ~(0xFFFFL << 43)) | ((new_constant & 0xFFFFL) << 43); - SLJIT_CACHE_FLUSH(inst, inst + 4); - } -+ -+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg) -+{ -+ CHECK_REG_INDEX(check_sljit_get_register_index(reg)); -+ return reg_map[reg]; -+} -+ -+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler, -+ void *instruction, sljit_si size) -+{ -+ CHECK_ERROR(); -+ CHECK(check_sljit_emit_op_custom(compiler, instruction, size)); -+ return SLJIT_ERR_UNSUPPORTED; -+} -+ -Index: pcregrep.c -=================================================================== ---- pcregrep.c (revision 1554) -+++ pcregrep.c (working copy) -@@ -1692,9 +1692,13 @@ - - if (filenames == FN_NOMATCH_ONLY) return 1; - -+ /* If all we want is a yes/no answer, stop now. */ -+ -+ if (quiet) return 0; -+ - /* Just count if just counting is wanted. */ - -- if (count_only) count++; -+ else if (count_only) count++; - - /* When handling a binary file and binary-files==binary, the "binary" - variable will be set true (it's false in all other cases). In this -@@ -1715,10 +1719,6 @@ - return 0; - } - -- /* Likewise, if all we want is a yes/no answer. */ -- -- else if (quiet) return 0; -- - /* The --only-matching option prints just the substring that matched, - and/or one or more captured portions of it, as long as these strings are - not empty. The --file-offsets and --line-offsets options output offsets for -@@ -2089,7 +2089,7 @@ - - /* Print the match count if wanted */ - --if (count_only) -+if (count_only && !quiet) - { - if (count > 0 || !omit_zero_count) - { -Index: pcre_study.c -=================================================================== ---- pcre_study.c (revision 1554) -+++ pcre_study.c (working copy) -@@ -71,6 +71,7 @@ - startcode pointer to start of the whole pattern's code - options the compiling options - recurses chain of recurse_check to catch mutual recursion -+ countptr pointer to call count (to catch over complexity) - - Returns: the minimum length - -1 if \C in UTF-8 mode or (*ACCEPT) was encountered -@@ -80,7 +81,8 @@ - - static int - find_minlength(const REAL_PCRE *re, const pcre_uchar *code, -- const pcre_uchar *startcode, int options, recurse_check *recurses) -+ const pcre_uchar *startcode, int options, recurse_check *recurses, -+ int *countptr) - { - int length = -1; - /* PCRE_UTF16 has the same value as PCRE_UTF8. */ -@@ -90,6 +92,8 @@ - register int branchlength = 0; - register pcre_uchar *cc = (pcre_uchar *)code + 1 + LINK_SIZE; - -+if ((*countptr)++ > 1000) return -1; /* too complex */ -+ - if (*code == OP_CBRA || *code == OP_SCBRA || - *code == OP_CBRAPOS || *code == OP_SCBRAPOS) cc += IMM2_SIZE; - -@@ -131,7 +135,7 @@ - case OP_SBRAPOS: - case OP_ONCE: - case OP_ONCE_NC: -- d = find_minlength(re, cc, startcode, options, recurses); -+ d = find_minlength(re, cc, startcode, options, recurses, countptr); - if (d < 0) return d; - branchlength += d; - do cc += GET(cc, 1); while (*cc == OP_ALT); -@@ -415,7 +419,8 @@ - int dd; - this_recurse.prev = recurses; - this_recurse.group = cs; -- dd = find_minlength(re, cs, startcode, options, &this_recurse); -+ dd = find_minlength(re, cs, startcode, options, &this_recurse, -+ countptr); - if (dd < d) d = dd; - } - } -@@ -451,7 +456,8 @@ - { - this_recurse.prev = recurses; - this_recurse.group = cs; -- d = find_minlength(re, cs, startcode, options, &this_recurse); -+ d = find_minlength(re, cs, startcode, options, &this_recurse, -+ countptr); - } - } - } -@@ -514,7 +520,7 @@ - this_recurse.prev = recurses; - this_recurse.group = cs; - branchlength += find_minlength(re, cs, startcode, options, -- &this_recurse); -+ &this_recurse, countptr); - } - } - cc += 1 + LINK_SIZE; -@@ -1453,6 +1459,7 @@ - #endif - { - int min; -+int count = 0; - BOOL bits_set = FALSE; - pcre_uint8 start_bits[32]; - PUBL(extra) *extra = NULL; -@@ -1539,7 +1546,7 @@ - - /* Find the minimum length of subject string. */ - --switch(min = find_minlength(re, code, code, re->options, NULL)) -+switch(min = find_minlength(re, code, code, re->options, NULL, &count)) - { - case -2: *errorptr = "internal error: missing capturing bracket"; return NULL; - case -3: *errorptr = "internal error: opcode not recognized"; return NULL; -Index: pcre_internal.h -=================================================================== ---- pcre_internal.h (revision 1554) -+++ pcre_internal.h (working copy) -@@ -984,7 +984,7 @@ - #ifndef EBCDIC - - #define HSPACE_LIST \ -- CHAR_HT, CHAR_SPACE, 0xa0, \ -+ CHAR_HT, CHAR_SPACE, CHAR_NBSP, \ - 0x1680, 0x180e, 0x2000, 0x2001, 0x2002, 0x2003, 0x2004, 0x2005, \ - 0x2006, 0x2007, 0x2008, 0x2009, 0x200A, 0x202f, 0x205f, 0x3000, \ - NOTACHAR -@@ -1010,7 +1010,7 @@ - #define HSPACE_BYTE_CASES \ - case CHAR_HT: \ - case CHAR_SPACE: \ -- case 0xa0 /* NBSP */ -+ case CHAR_NBSP - - #define HSPACE_CASES \ - HSPACE_BYTE_CASES: \ -@@ -1037,11 +1037,12 @@ - /* ------ EBCDIC environments ------ */ - - #else --#define HSPACE_LIST CHAR_HT, CHAR_SPACE -+#define HSPACE_LIST CHAR_HT, CHAR_SPACE, CHAR_NBSP, NOTACHAR - - #define HSPACE_BYTE_CASES \ - case CHAR_HT: \ -- case CHAR_SPACE -+ case CHAR_SPACE: \ -+ case CHAR_NBSP - - #define HSPACE_CASES HSPACE_BYTE_CASES - -@@ -1215,6 +1216,7 @@ - - #define CHAR_ESC '\047' - #define CHAR_DEL '\007' -+#define CHAR_NBSP '\x41' - #define STR_ESC "\047" - #define STR_DEL "\007" - -@@ -1229,6 +1231,7 @@ - #define CHAR_NEL ((unsigned char)'\x85') - #define CHAR_ESC '\033' - #define CHAR_DEL '\177' -+#define CHAR_NBSP ((unsigned char)'\xa0') - - #define STR_LF "\n" - #define STR_NL STR_LF -@@ -1606,6 +1609,7 @@ - #define CHAR_VERTICAL_LINE '\174' - #define CHAR_RIGHT_CURLY_BRACKET '\175' - #define CHAR_TILDE '\176' -+#define CHAR_NBSP ((unsigned char)'\xa0') - - #define STR_HT "\011" - #define STR_VT "\013" -@@ -1762,6 +1766,10 @@ - - /* Escape items that are just an encoding of a particular data value. */ - -+#ifndef ESC_a -+#define ESC_a CHAR_BEL -+#endif -+ - #ifndef ESC_e - #define ESC_e CHAR_ESC - #endif -@@ -2446,6 +2454,7 @@ - BOOL had_pruneorskip; /* (*PRUNE) or (*SKIP) encountered */ - BOOL check_lookbehind; /* Lookbehinds need later checking */ - BOOL dupnames; /* Duplicate names exist */ -+ BOOL dupgroups; /* Duplicate groups exist: (?| found */ - BOOL iscondassert; /* Next assert is a condition */ - int nltype; /* Newline type */ - int nllen; /* Newline string length */ -Index: pcre_exec.c -=================================================================== ---- pcre_exec.c (revision 1554) -+++ pcre_exec.c (working copy) -@@ -6685,7 +6685,8 @@ - register int *iend = iptr - re->top_bracket; - if (iend < md->offset_vector + 2) iend = md->offset_vector + 2; - while (--iptr >= iend) *iptr = -1; -- md->offset_vector[0] = md->offset_vector[1] = -1; -+ if (offsetcount > 0) md->offset_vector[0] = -1; -+ if (offsetcount > 1) md->offset_vector[1] = -1; - } - - /* Set up the first character to match, if available. The first_char value is -Index: pcre_jit_test.c -=================================================================== ---- pcre_jit_test.c (revision 1554) -+++ pcre_jit_test.c (working copy) -@@ -182,6 +182,7 @@ - { CMUAP, 0, "\xf0\x90\x90\x80{2}", "\xf0\x90\x90\x80#\xf0\x90\x90\xa8\xf0\x90\x90\x80" }, - { CMUAP, 0, "\xf0\x90\x90\xa8{2}", "\xf0\x90\x90\x80#\xf0\x90\x90\xa8\xf0\x90\x90\x80" }, - { CMUAP, 0, "\xe1\xbd\xb8\xe1\xbf\xb8", "\xe1\xbf\xb8\xe1\xbd\xb8" }, -+ { MA, 0, "[3-57-9]", "5" }, - - /* Assertions. */ - { MUA, 0, "\\b[^A]", "A_B#" }, -Index: configure.ac -=================================================================== ---- configure.ac (revision 1554) -+++ configure.ac (working copy) -@@ -9,9 +9,9 @@ - dnl be defined as -RC2, for example. For real releases, it should be empty. - - m4_define(pcre_major, [8]) --m4_define(pcre_minor, [37]) --m4_define(pcre_prerelease, []) --m4_define(pcre_date, [2015-04-28]) -+m4_define(pcre_minor, [38]) -+m4_define(pcre_prerelease, [-RC1]) -+m4_define(pcre_date, [2015-05-03]) - - # NOTE: The CMakeLists.txt file searches for the above variables in the first - # 50 lines of this file. Please update that if the variables above are moved. -Index: doc/pcrepattern.3 -=================================================================== ---- doc/pcrepattern.3 (revision 1554) -+++ doc/pcrepattern.3 (working copy) -@@ -1,4 +1,4 @@ --.TH PCREPATTERN 3 "08 January 2014" "PCRE 8.35" -+.TH PCREPATTERN 3 "14 June 2015" "PCRE 8.38" - .SH NAME - PCRE - Perl-compatible regular expressions - .SH "PCRE REGULAR EXPRESSION DETAILS" -@@ -308,7 +308,8 @@ - in patterns in a visible manner. There is no restriction on the appearance of - non-printing characters, apart from the binary zero that terminates a pattern, - but when a pattern is being prepared by text editing, it is often easier to use --one of the following escape sequences than the binary character it represents: -+one of the following escape sequences than the binary character it represents. -+In an ASCII or Unicode environment, these escapes are as follows: - .sp - \ea alarm, that is, the BEL character (hex 07) - \ecx "control-x", where x is any ASCII character -@@ -330,19 +331,31 @@ - but \ec{ becomes hex 3B ({ is 7B), and \ec; becomes hex 7B (; is 3B). If the - data item (byte or 16-bit value) following \ec has a value greater than 127, a - compile-time error occurs. This locks out non-ASCII characters in all modes. -+.P -+When PCRE is compiled in EBCDIC mode, \ea, \ee, \ef, \en, \er, and \et -+generate the appropriate EBCDIC code values. The \ec escape is processed -+as specified for Perl in the \fBperlebcdic\fP document. The only characters -+that are allowed after \ec are A-Z, a-z, or one of @, [, \e, ], ^, _, or ?. Any -+other character provokes a compile-time error. The sequence \e@ encodes -+character code 0; the letters (in either case) encode characters 1-26 (hex 01 -+to hex 1A); [, \e, ], ^, and _ encode characters 27-31 (hex 1B to hex 1F), and -+\e? becomes either 255 (hex FF) or 95 (hex 5F). - .P --The \ec facility was designed for use with ASCII characters, but with the --extension to Unicode it is even less useful than it once was. It is, however, --recognized when PCRE is compiled in EBCDIC mode, where data items are always --bytes. In this mode, all values are valid after \ec. If the next character is a --lower case letter, it is converted to upper case. Then the 0xc0 bits of the --byte are inverted. Thus \ecA becomes hex 01, as in ASCII (A is C1), but because --the EBCDIC letters are disjoint, \ecZ becomes hex 29 (Z is E9), and other --characters also generate different values. -+Thus, apart from \e?, these escapes generate the same character code values as -+they do in an ASCII environment, though the meanings of the values mostly -+differ. For example, \eG always generates code value 7, which is BEL in ASCII -+but DEL in EBCDIC. - .P -+The sequence \e? generates DEL (127, hex 7F) in an ASCII environment, but -+because 127 is not a control character in EBCDIC, Perl makes it generate the -+APC character. Unfortunately, there are several variants of EBCDIC. In most of -+them the APC character has the value 255 (hex FF), but in the one Perl calls -+POSIX-BC its value is 95 (hex 5F). If certain other characters have POSIX-BC -+values, PCRE makes \e? generate 95; otherwise it generates 255. -+.P - After \e0 up to two further octal digits are read. If there are fewer than two --digits, just those that are present are used. Thus the sequence \e0\ex\e07 --specifies two binary zeros followed by a BEL character (code value 7). Make -+digits, just those that are present are used. Thus the sequence \e0\ex\e015 -+specifies two binary zeros followed by a CR character (code value 13). Make - sure you supply two digits after the initial zero if the pattern character that - follows is itself an octal digit. - .P -@@ -3283,6 +3296,6 @@ - .rs - .sp - .nf --Last updated: 08 January 2014 --Copyright (c) 1997-2014 University of Cambridge. -+Last updated: 14 June 2015 -+Copyright (c) 1997-2015 University of Cambridge. - .fi -Index: testdata/testoutput11-32 -=================================================================== ---- testdata/testoutput11-32 (revision 1554) -+++ testdata/testoutput11-32 (working copy) -@@ -231,7 +231,7 @@ - ------------------------------------------------------------------ - - /(?Pa)...(?P=a)bbb(?P>a)d/BM --Memory allocation (code space): 125 -+Memory allocation (code space): 157 - ------------------------------------------------------------------ - 0 24 Bra - 2 5 CBra 1 -@@ -748,4 +748,21 @@ - 22 End - ------------------------------------------------------------------ - -+/.((?2)(?R)\1)()/B -+------------------------------------------------------------------ -+ 0 23 Bra -+ 2 Any -+ 3 13 Once -+ 5 9 CBra 1 -+ 8 18 Recurse -+ 10 0 Recurse -+ 12 \1 -+ 14 9 Ket -+ 16 13 Ket -+ 18 3 CBra 2 -+ 21 3 Ket -+ 23 23 Ket -+ 25 End -+------------------------------------------------------------------ -+ - /-- End of testinput11 --/ -Index: testdata/testinputEBC -=================================================================== ---- testdata/testinputEBC (revision 1554) -+++ testdata/testinputEBC (working copy) -@@ -29,13 +29,16 @@ - - /^A\ˆ/ - A B -+ A\x41B - - /-- Test \H --/ - - /^A\È/ - AB -+ A\x42B - ** Fail - A B -+ A\x41B - - /-- Test \R --/ - -Index: testdata/testoutput1 -=================================================================== ---- testdata/testoutput1 (revision 1554) -+++ testdata/testoutput1 (working copy) -@@ -9429,4 +9429,9 @@ - 0: aaaaaaaaa - 1: a - -+"(?|(\k'Pm')|(?'Pm'))" -+ abcd -+ 0: -+ 1: -+ - /-- End of testinput1 --/ -Index: testdata/testoutput2 -=================================================================== ---- testdata/testoutput2 (revision 1554) -+++ testdata/testoutput2 (working copy) -@@ -5614,9 +5614,9 @@ - 123456\P - No match - --//KF>/dev/null --Compiled pattern written to /dev/null --Study data written to /dev/null -+//KF>testsavedregex -+Compiled pattern written to testsavedregex -+Study data written to testsavedregex - - /abc/IS>testsavedregex - Capturing subpattern count = 0 -@@ -9135,10 +9135,10 @@ - Failed: subpattern name expected at offset 3 - - /\k/ --Failed: \k is not followed by a braced, angle-bracketed, or quoted name at offset 2 -+Failed: \k is not followed by a braced, angle-bracketed, or quoted name at offset 1 - - /\kabc/ --Failed: \k is not followed by a braced, angle-bracketed, or quoted name at offset 5 -+Failed: \k is not followed by a braced, angle-bracketed, or quoted name at offset 1 - - /(?P=)/ - Failed: subpattern name expected at offset 4 -@@ -9186,7 +9186,7 @@ - Failed: unknown POSIX class name at offset 3 - - /(^(a|b\g<-1'c))/ --Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 15 -+Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 8 - - /^(?+1)(?x|y){0}z/ - xzxx -@@ -14098,10 +14098,10 @@ - Failed: group name must start with a non-digit at offset 4 - - /\g'3gh'/ --Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 7 -+Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 2 - - /\g<5fg>/ --Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 7 -+Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 2 - - /(?(<4gh>)abc)/ - Failed: group name must start with a non-digit at offset 4 -@@ -14423,4 +14423,146 @@ - - /((?2){73}(?2))((?1))/ - -+/.((?2)(?R)\1)()/BZ -+------------------------------------------------------------------ -+ Bra -+ Any -+ Once -+ CBra 1 -+ Recurse -+ Recurse -+ \1 -+ Ket -+ Ket -+ CBra 2 -+ Ket -+ Ket -+ End -+------------------------------------------------------------------ -+ -+/(?1)()((((((\1++))\x85)+)|))/ -+ -+/(\9*+(?2);\3++()2|)++{/ -+Failed: reference to non-existent subpattern at offset 22 -+ -+/\V\x85\9*+((?2)\3++()2)*:2/ -+Failed: reference to non-existent subpattern at offset 26 -+ -+/(((?(R)){0,2}) (?''((?'R')((?'R')))))/J -+ -+/(((?(X)){0,2}) (?''((?'X')((?'X')))))/J -+ -+/(((?(R)){0,2}) (?''((?'X')((?'R')))))/ -+ -+"(?J)(?'d'(?'d'\g{d}))" -+ -+".*?\h.+.\.+\R*?\xd(?i)(?=!(?=b`b`b`\`b\xa9b!)`\a`bbbbbbbbbbbbb`bbbbbbbbbbbb*R\x85bbbbbbb\C?{((?2)(?))(( -+\H){8(?<=(?1){29}\xa8bbbb\x16\xd\xc6^($(?1)/ -+ - /-- End of testinput2 --/ -Index: testdata/testoutput11-16 -=================================================================== ---- testdata/testoutput11-16 (revision 1554) -+++ testdata/testoutput11-16 (working copy) -@@ -231,7 +231,7 @@ - ------------------------------------------------------------------ - - /(?Pa)...(?P=a)bbb(?P>a)d/BM --Memory allocation (code space): 61 -+Memory allocation (code space): 77 - ------------------------------------------------------------------ - 0 24 Bra - 2 5 CBra 1 -@@ -748,4 +748,21 @@ - 22 End - ------------------------------------------------------------------ - -+/.((?2)(?R)\1)()/B -+------------------------------------------------------------------ -+ 0 23 Bra -+ 2 Any -+ 3 13 Once -+ 5 9 CBra 1 -+ 8 18 Recurse -+ 10 0 Recurse -+ 12 \1 -+ 14 9 Ket -+ 16 13 Ket -+ 18 3 CBra 2 -+ 21 3 Ket -+ 23 23 Ket -+ 25 End -+------------------------------------------------------------------ -+ - /-- End of testinput11 --/ -Index: testdata/testoutput6 -=================================================================== ---- testdata/testoutput6 (revision 1554) -+++ testdata/testoutput6 (working copy) -@@ -2469,4 +2469,8 @@ - Ó…\x0aT - No match - -+/[\pS#moq]/ -+ = -+ 0: = -+ - /-- End of testinput6 --/ -Index: testdata/testinput11 -=================================================================== ---- testdata/testinput11 (revision 1554) -+++ testdata/testinput11 (working copy) -@@ -136,4 +136,6 @@ - - /((?+1)(\1))/B - -+/.((?2)(?R)\1)()/B -+ - /-- End of testinput11 --/ -Index: testdata/testinput12 -=================================================================== ---- testdata/testinput12 (revision 1554) -+++ testdata/testinput12 (working copy) -@@ -8,6 +8,8 @@ - - /(?(?C1)(?=a)a)/S!+I - -+/b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*/S+I -+ - /abc/S+I>testsavedregex - - testsavedregex - Capturing subpattern count = 0 - No options -@@ -184,4 +193,12 @@ - - /(a(?:a|b|c|d|e)b){8,16}/S++ - -+/(?:|a|){100}x/S++ -+ -+/(x(?1)){4}/S++ -+ -+/(.|.)*?bx/ -+ aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabax -+Error -8 (match limit exceeded) -+ - /-- End of testinput12 --/ -Index: testdata/testoutput11-8 -=================================================================== ---- testdata/testoutput11-8 (revision 1554) -+++ testdata/testoutput11-8 (working copy) -@@ -231,7 +231,7 @@ - ------------------------------------------------------------------ - - /(?Pa)...(?P=a)bbb(?P>a)d/BM --Memory allocation (code space): 38 -+Memory allocation (code space): 50 - ------------------------------------------------------------------ - 0 30 Bra - 3 7 CBra 1 -@@ -748,4 +748,21 @@ - 34 End - ------------------------------------------------------------------ - -+/.((?2)(?R)\1)()/B -+------------------------------------------------------------------ -+ 0 35 Bra -+ 3 Any -+ 4 20 Once -+ 7 14 CBra 1 -+ 12 27 Recurse -+ 15 0 Recurse -+ 18 \1 -+ 21 14 Ket -+ 24 20 Ket -+ 27 5 CBra 2 -+ 32 5 Ket -+ 35 35 Ket -+ 38 End -+------------------------------------------------------------------ -+ - /-- End of testinput11 --/ -Index: testdata/testoutputEBC -=================================================================== ---- testdata/testoutputEBC (revision 1554) -+++ testdata/testoutputEBC (working copy) -@@ -41,6 +41,8 @@ - /^A\ˆ/ - A B - 0: A\x20 -+ A\x41B -+ 0: AA - - /-- Test \H --/ - -@@ -47,10 +49,14 @@ - /^A\È/ - AB - 0: AB -+ A\x42B -+ 0: AB - ** Fail - No match - A B - No match -+ A\x41B -+No match - - /-- Test \R --/ - -Index: testdata/grepoutput -=================================================================== ---- testdata/grepoutput (revision 1554) -+++ testdata/grepoutput (working copy) -@@ -751,3 +751,7 @@ - 2:3,1 - 2:4,1 - RC=0 -+---------------------------- Test 108 ------------------------------ -+RC=0 -+---------------------------- Test 109 ----------------------------- -+RC=0 -Index: testdata/testinput1 -=================================================================== ---- testdata/testinput1 (revision 1554) -+++ testdata/testinput1 (working copy) -@@ -5730,4 +5730,7 @@ - "(?1)(?#?'){8}(a)" - baaaaaaaaac - -+"(?|(\k'Pm')|(?'Pm'))" -+ abcd -+ - /-- End of testinput1 --/ -Index: testdata/testinput2 -=================================================================== ---- testdata/testinput2 (revision 1554) -+++ testdata/testinput2 (working copy) -@@ -1380,7 +1380,7 @@ - 1X - 123456\P - --//KF>/dev/null -+//KF>testsavedregex - - /abc/IS>testsavedregex - 1)/ -+ - /-- End of testinput2 --/ -Index: testdata/testinput6 -=================================================================== ---- testdata/testinput6 (revision 1554) -+++ testdata/testinput6 (working copy) -@@ -1502,4 +1502,7 @@ - /\C\X*QT/8 - Ó…\x0aT - -+/[\pS#moq]/ -+ = -+ - /-- End of testinput6 --/ -Index: NON-AUTOTOOLS-BUILD -=================================================================== ---- NON-AUTOTOOLS-BUILD (revision 1554) -+++ NON-AUTOTOOLS-BUILD (working copy) -@@ -764,9 +764,9 @@ - - http://www.zaconsultants.net - --There is also a mirror here: -+You may download PCRE from WWW.CBTTAPE.ORG, file 882.  Everything, source and -+executable, is in EBCDIC and native z/OS file formats and this is the -+recommended download site. - -- http://www.vsoft-software.com/downloads.html -- - ========================== --Last Updated: 10 February 2015 -+Last Updated: 25 June 2015 -- cgit 1.4.1 From 2896861c7e55da24b8f15c42af0f2b5fc3b0bdb0 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Fri, 25 Sep 2015 11:53:19 +0200 Subject: pcre: Smaller patch for CVE-2015-3210, CVE-2015-5073 --- .../development/libraries/pcre/cve-2015-3210.patch | 87 ++++++++++++++++++++++ .../development/libraries/pcre/cve-2015-5073.patch | 68 +++++++++++++++++ pkgs/development/libraries/pcre/default.nix | 5 ++ 3 files changed, 160 insertions(+) create mode 100644 pkgs/development/libraries/pcre/cve-2015-3210.patch create mode 100644 pkgs/development/libraries/pcre/cve-2015-5073.patch (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/pcre/cve-2015-3210.patch b/pkgs/development/libraries/pcre/cve-2015-3210.patch new file mode 100644 index 00000000000..c97849fb70c --- /dev/null +++ b/pkgs/development/libraries/pcre/cve-2015-3210.patch @@ -0,0 +1,87 @@ +From 68ff1beb43bb3d4d8838f3285c97023d1e50513a Mon Sep 17 00:00:00 2001 +From: ph10 +Date: Fri, 15 May 2015 17:17:03 +0000 +Subject: [PATCH] Fix buffer overflow for named recursive back reference when + the name is duplicated. +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Upstream commit ported to pcre-8.37: + +commit 4b79af6b4cbeb5326ae5e4d83f3e935e00286c19 +Author: ph10 +Date: Fri May 15 17:17:03 2015 +0000 + + Fix buffer overflow for named recursive back reference when the name is + duplicated. + + git-svn-id: svn://vcs.exim.org/pcre/code/trunk@1558 2f5784b3-3f2a-0410-8824-cb99058d5e15 + +This fixes CVE-2015-3210. + +Signed-off-by: Petr PísaÅ™ +--- + pcre_compile.c | 16 ++++++++++++++-- + testdata/testinput2 | 2 ++ + testdata/testoutput2 | 2 ++ + 3 files changed, 18 insertions(+), 2 deletions(-) + +diff --git a/pcre_compile.c b/pcre_compile.c +index 0efad26..6f06912 100644 +--- a/pcre_compile.c ++++ b/pcre_compile.c +@@ -7173,14 +7173,26 @@ for (;; ptr++) + number. If the name is not found, set the value to 0 for a forward + reference. */ + ++ recno = 0; + ng = cd->named_groups; + for (i = 0; i < cd->names_found; i++, ng++) + { + if (namelen == ng->length && + STRNCMP_UC_UC(name, ng->name, namelen) == 0) +- break; ++ { ++ open_capitem *oc; ++ recno = ng->number; ++ if (is_recurse) break; ++ for (oc = cd->open_caps; oc != NULL; oc = oc->next) ++ { ++ if (oc->number == recno) ++ { ++ oc->flag = TRUE; ++ break; ++ } ++ } ++ } + } +- recno = (i < cd->names_found)? ng->number : 0; + + /* Count named back references. */ + +diff --git a/testdata/testinput2 b/testdata/testinput2 +index 58fe53b..83bb471 100644 +--- a/testdata/testinput2 ++++ b/testdata/testinput2 +@@ -4152,4 +4152,6 @@ backtracking verbs. --/ + + /((?2){73}(?2))((?1))/ + ++"(?J)(?'d'(?'d'\g{d}))" ++ + /-- End of testinput2 --/ +diff --git a/testdata/testoutput2 b/testdata/testoutput2 +index b718df0..7dff52a 100644 +--- a/testdata/testoutput2 ++++ b/testdata/testoutput2 +@@ -14423,4 +14423,6 @@ Failed: lookbehind assertion is not fixed length at offset 17 + + /((?2){73}(?2))((?1))/ + ++"(?J)(?'d'(?'d'\g{d}))" ++ + /-- End of testinput2 --/ +-- +2.4.3 + diff --git a/pkgs/development/libraries/pcre/cve-2015-5073.patch b/pkgs/development/libraries/pcre/cve-2015-5073.patch new file mode 100644 index 00000000000..16fd45c87b1 --- /dev/null +++ b/pkgs/development/libraries/pcre/cve-2015-5073.patch @@ -0,0 +1,68 @@ +From 354e1f8e921dcb9cf2f3a5eac93cd826d01a7d8a Mon Sep 17 00:00:00 2001 +From: ph10 +Date: Tue, 23 Jun 2015 16:34:53 +0000 +Subject: [PATCH] Fix buffer overflow for forward reference within backward + assertion with excess closing parenthesis. Bugzilla 1651. +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +This is upstream commit ported to 8.37: + +commit 764692f9aea9eab50fdba6cb537441d8b34c6c37 +Author: ph10 +Date: Tue Jun 23 16:34:53 2015 +0000 + + Fix buffer overflow for forward reference within backward assertion with excess + closing parenthesis. Bugzilla 1651. + + git-svn-id: svn://vcs.exim.org/pcre/code/trunk@1571 2f5784b3-3f2a-0410-8824-cb99058d5e15 + +It fixes CVE-2015-5073. + +Signed-off-by: Petr PísaÅ™ +--- + pcre_compile.c | 2 +- + testdata/testinput2 | 2 ++ + testdata/testoutput2 | 3 +++ + 3 files changed, 6 insertions(+), 1 deletion(-) + +diff --git a/pcre_compile.c b/pcre_compile.c +index 6f06912..b66b1f6 100644 +--- a/pcre_compile.c ++++ b/pcre_compile.c +@@ -9392,7 +9392,7 @@ OP_RECURSE that are not fixed length get a diagnosic with a useful offset. The + exceptional ones forgo this. We scan the pattern to check that they are fixed + length, and set their lengths. */ + +-if (cd->check_lookbehind) ++if (errorcode == 0 && cd->check_lookbehind) + { + pcre_uchar *cc = (pcre_uchar *)codestart; + +diff --git a/testdata/testinput2 b/testdata/testinput2 +index 83bb471..5cc9ce6 100644 +--- a/testdata/testinput2 ++++ b/testdata/testinput2 +@@ -4154,4 +4154,6 @@ backtracking verbs. --/ + + "(?J)(?'d'(?'d'\g{d}))" + ++/(?=di(?<=(?1))|(?=(.))))/ ++ + /-- End of testinput2 --/ +diff --git a/testdata/testoutput2 b/testdata/testoutput2 +index 7dff52a..4decb8d 100644 +--- a/testdata/testoutput2 ++++ b/testdata/testoutput2 +@@ -14425,4 +14425,7 @@ Failed: lookbehind assertion is not fixed length at offset 17 + + "(?J)(?'d'(?'d'\g{d}))" + ++/(?=di(?<=(?1))|(?=(.))))/ ++Failed: unmatched parentheses at offset 23 ++ + /-- End of testinput2 --/ +-- +2.4.3 + diff --git a/pkgs/development/libraries/pcre/default.nix b/pkgs/development/libraries/pcre/default.nix index a34f3e5e132..3370e910565 100644 --- a/pkgs/development/libraries/pcre/default.nix +++ b/pkgs/development/libraries/pcre/default.nix @@ -12,6 +12,11 @@ stdenv.mkDerivation rec { sha256 = "17bqykp604p7376wj3q2nmjdhrb6v1ny8q08zdwi7qvc02l9wrsi"; }; + patches = + [ ./cve-2015-3210.patch + ./cve-2015-5073.patch + ]; + outputs = [ "out" "doc" "man" ]; configureFlags = '' -- cgit 1.4.1 From 702fde3a91f450d4963189250bf2df113b42efa7 Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 14:06:23 +0200 Subject: libarchive: fix .la file for lzo2 --- pkgs/development/libraries/libarchive/default.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libarchive/default.nix b/pkgs/development/libraries/libarchive/default.nix index 837db32ea4b..ff33043dbae 100644 --- a/pkgs/development/libraries/libarchive/default.nix +++ b/pkgs/development/libraries/libarchive/default.nix @@ -26,7 +26,9 @@ stdenv.mkDerivation rec { '' else null; preFixup = '' - sed 's|-lcrypto|-L${openssl}/lib -lcrypto|' -i $out/lib/libarchive.la + sed -i $out/lib/libarchive.la \ + -e 's|-lcrypto|-L${openssl}/lib -lcrypto|' \ + -e 's|-llzo2|-L${lzo}/lib -llzo2|' ''; meta = { -- cgit 1.4.1 From 7d1cb980bfdb88f889ac59bb9080389052d12558 Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Fri, 25 Sep 2015 14:06:23 +0200 Subject: libarchive: fix .la file for lzo2 --- pkgs/development/libraries/libarchive/default.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libarchive/default.nix b/pkgs/development/libraries/libarchive/default.nix index 837db32ea4b..ff33043dbae 100644 --- a/pkgs/development/libraries/libarchive/default.nix +++ b/pkgs/development/libraries/libarchive/default.nix @@ -26,7 +26,9 @@ stdenv.mkDerivation rec { '' else null; preFixup = '' - sed 's|-lcrypto|-L${openssl}/lib -lcrypto|' -i $out/lib/libarchive.la + sed -i $out/lib/libarchive.la \ + -e 's|-lcrypto|-L${openssl}/lib -lcrypto|' \ + -e 's|-llzo2|-L${lzo}/lib -llzo2|' ''; meta = { -- cgit 1.4.1 From 406c366432c12e48596726340ce7494f62fade1e Mon Sep 17 00:00:00 2001 From: Jude Taylor Date: Mon, 28 Sep 2015 09:16:05 -0700 Subject: revert realLibtool --- pkgs/development/libraries/libuv/default.nix | 4 ++-- pkgs/top-level/all-packages.nix | 16 +++++----------- 2 files changed, 7 insertions(+), 13 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libuv/default.nix b/pkgs/development/libraries/libuv/default.nix index 2a35264799b..248553dc5eb 100644 --- a/pkgs/development/libraries/libuv/default.nix +++ b/pkgs/development/libraries/libuv/default.nix @@ -1,4 +1,4 @@ -{ stdenv, lib, fetchFromGitHub, autoconf, automake, realLibtool, pkgconfig +{ stdenv, lib, fetchFromGitHub, autoconf, automake, libtool, pkgconfig , ApplicationServices, CoreServices }: @@ -61,7 +61,7 @@ let mkWithAutotools = stability: version: sha256: stdenv.mkDerivation { name = mkName stability version; src = mkSrc version sha256; - buildInputs = [ automake autoconf realLibtool pkgconfig ] + buildInputs = [ automake autoconf libtool pkgconfig ] ++ stdenv.lib.optionals stdenv.isDarwin [ ApplicationServices CoreServices ]; preConfigure = '' LIBTOOLIZE=libtoolize ./autogen.sh diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 58185dee3cf..adebc405f76 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -258,7 +258,7 @@ let autonix = import ../build-support/autonix { inherit pkgs; }; autoreconfHook = makeSetupHook - { substitutions = { inherit autoconf automake gettext; libtool = realLibtool; }; } + { substitutions = { inherit autoconf automake gettext libtool; }; } ../build-support/setup-hooks/autoreconf.sh; buildEnv = callPackage ../build-support/buildenv {}; @@ -4857,9 +4857,7 @@ let guile_1_8 = callPackage ../development/interpreters/guile/1.8.nix { }; - guile_2_0 = callPackage ../development/interpreters/guile { - libtool = realLibtool; - }; + guile_2_0 = callPackage ../development/interpreters/guile { }; guile = guile_2_0; @@ -5572,11 +5570,8 @@ let lemon = callPackage ../development/tools/parsing/lemon { }; - libtool = if stdenv.isDarwin - then darwin.cctools - else realLibtool; - realLibtool = libtool_2; + libtool = libtool_2; libtool_1_5 = callPackage ../development/tools/misc/libtool { }; @@ -6057,9 +6052,7 @@ let db6 = db60; db60 = callPackage ../development/libraries/db/db-6.0.nix { }; - dbus = callPackage ../development/libraries/dbus { - libtool = realLibtool; - }; + dbus = callPackage ../development/libraries/dbus { }; dbus_cplusplus = callPackage ../development/libraries/dbus-cplusplus { }; dbus_glib = callPackage ../development/libraries/dbus-glib { }; dbus_java = callPackage ../development/libraries/java/dbus-java { }; @@ -11044,6 +11037,7 @@ let }); emacs24Macport_24_5 = lowPrio (callPackage ../applications/editors/emacs-24/macport-24.5.nix { stdenv = pkgs.clangStdenv; + inherit (darwin.apple_sdk.frameworks) Carbon; }); emacs24Macport = self.emacs24Macport_24_5; -- cgit 1.4.1 From cfba54975e4193389657c0e67747b1c0632e71dd Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Wed, 30 Sep 2015 16:17:02 -0700 Subject: mesa: 10.6.8 -> 11.0.2 --- pkgs/development/libraries/mesa/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/mesa/default.nix b/pkgs/development/libraries/mesa/default.nix index 90db53ae7eb..52268b9c343 100644 --- a/pkgs/development/libraries/mesa/default.nix +++ b/pkgs/development/libraries/mesa/default.nix @@ -22,7 +22,7 @@ else */ let - version = "10.6.8"; + version = "11.0.2"; # this is the default search path for DRI drivers driverLink = "/run/opengl-driver" + stdenv.lib.optionalString stdenv.isi686 "-32"; in @@ -36,7 +36,7 @@ stdenv.mkDerivation { "https://launchpad.net/mesa/trunk/${version}/+download/mesa-${version}.tar.xz" "ftp://ftp.freedesktop.org/pub/mesa/${version}/mesa-${version}.tar.xz" ]; - sha256 = "e36ee5ceeadb3966fb5ce5b4cf18322dbb76a4f075558ae49c3bba94f57d58fd"; + sha256 = "fce11fb27eb87adf1e620a76455d635c6136dfa49ae58c53b34ef8d0c7b7eae4"; }; prePatch = "patchShebangs ."; -- cgit 1.4.1 From 4d3198ca3102eafe7fc5c4ef0354e602a0dc9a77 Mon Sep 17 00:00:00 2001 From: Vladimír ÄŒunát Date: Thu, 1 Oct 2015 21:37:19 +0200 Subject: libaccounts-glib: fixup build after glib update --- pkgs/development/libraries/libaccounts-glib/default.nix | 2 ++ 1 file changed, 2 insertions(+) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/libaccounts-glib/default.nix b/pkgs/development/libraries/libaccounts-glib/default.nix index aa029ede953..2e2bdb11d50 100644 --- a/pkgs/development/libraries/libaccounts-glib/default.nix +++ b/pkgs/development/libraries/libaccounts-glib/default.nix @@ -22,4 +22,6 @@ stdenv.mkDerivation rec { configurePhase = '' HAVE_GCOV_FALSE="#" ./configure $configureFlags --prefix=$out ''; + + NIX_CFLAGS_COMPILE = "-Wno-error=deprecated-declarations"; # since glib-2.46 } -- cgit 1.4.1 From 33f1ebb8f2bb9ee16494d7a84a3ea17ecbefef02 Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Fri, 2 Oct 2015 16:08:42 -0700 Subject: glew: 1.11.0 -> 1.13.0 --- pkgs/development/libraries/glew/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/glew/default.nix b/pkgs/development/libraries/glew/default.nix index cbdc2831187..6595d97b01a 100644 --- a/pkgs/development/libraries/glew/default.nix +++ b/pkgs/development/libraries/glew/default.nix @@ -3,11 +3,11 @@ with stdenv.lib; stdenv.mkDerivation rec { - name = "glew-1.11.0"; + name = "glew-1.13.0"; src = fetchurl { url = "mirror://sourceforge/glew/${name}.tgz"; - sha256 = "1mhkllxz49l1x680dmzrv2i82qjrq017sykah3xc90f2d8qcxfv9"; + sha256 = "1iwb2a6wfhkzv6fa7zx2gz1lkwa0iwnd9ka1im5vdc44xm4dq9da"; }; nativeBuildInputs = [ xlibsWrapper libXmu libXi ]; -- cgit 1.4.1 From b233ecdca68e08940024da6e4e55e6ef2a20863f Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Fri, 2 Oct 2015 16:08:52 -0700 Subject: poppler: 0.34.0 -> 0.36.0 Tested building cups-filters and rendering a pdf --- pkgs/development/libraries/poppler/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/poppler/default.nix b/pkgs/development/libraries/poppler/default.nix index b15142dc673..92777f00169 100644 --- a/pkgs/development/libraries/poppler/default.nix +++ b/pkgs/development/libraries/poppler/default.nix @@ -5,8 +5,8 @@ }: let # beware: updates often break cups_filters build - version = "0.34.0"; # even major numbers are stable - sha256 = "1c2wa4pfzqmvzq1jpp3ps5nmzz745gcg8dnpwqpfdccy5ydbm90v"; + version = "0.36.0"; # even major numbers are stable + sha256 = "13i440kv873wgmw50rs4d1v05cj0r7bqnghd70hp9vy44dxhdk4k"; in stdenv.mkDerivation rec { name = "poppler-${suffix}-${version}"; -- cgit 1.4.1 From 4e8da0747c88375c221bf1b0f060183a863c6851 Mon Sep 17 00:00:00 2001 From: Vladimír ÄŒunát Date: Sun, 4 Oct 2015 12:32:25 +0200 Subject: boost-1.55: fix build with gcc-5 by upstream patch Our higher versions have fix integrated upstream. --- pkgs/development/libraries/boost/1.55.nix | 2 +- pkgs/development/libraries/boost/gcc-5.patch | 64 ++++++++++++++++++++++++++++ 2 files changed, 65 insertions(+), 1 deletion(-) create mode 100644 pkgs/development/libraries/boost/gcc-5.patch (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/boost/1.55.nix b/pkgs/development/libraries/boost/1.55.nix index a10cd8ce220..0a38f35af75 100644 --- a/pkgs/development/libraries/boost/1.55.nix +++ b/pkgs/development/libraries/boost/1.55.nix @@ -3,7 +3,7 @@ callPackage ./generic.nix (args // rec { version = "1.55.0"; - patches = [ ./clang-math.patch ./clang-math-2.patch ]; + patches = [ ./clang-math.patch ./clang-math-2.patch ./gcc-5.patch ]; src = fetchurl { url = "mirror://sourceforge/boost/boost_1_55_0.tar.bz2"; diff --git a/pkgs/development/libraries/boost/gcc-5.patch b/pkgs/development/libraries/boost/gcc-5.patch new file mode 100644 index 00000000000..2b2713590ca --- /dev/null +++ b/pkgs/development/libraries/boost/gcc-5.patch @@ -0,0 +1,64 @@ +https://svn.boost.org/trac/boost/ticket/10125 + + boost/thread/pthread/once.hpp | 6 +++--- + boost/thread/pthread/once_atomic.hpp | 2 +- + boost/thread/win32/once.hpp | 2 +- + 3 files changed, 5 insertions(+), 5 deletions(-) + +diff --git a/boost/thread/pthread/once.hpp b/boost/thread/pthread/once.hpp +index ccfb051..0bef038 100644 +--- a/boost/thread/pthread/once.hpp ++++ b/boost/thread/pthread/once.hpp +@@ -42,7 +42,7 @@ namespace boost + } + + #ifdef BOOST_THREAD_PROVIDES_ONCE_CXX11 +-#ifndef BOOST_NO_CXX11_VARIADIC_TEMPLATES ++#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) + template + inline void call_once(once_flag& flag, BOOST_THREAD_RV_REF(Function) f, BOOST_THREAD_RV_REF(ArgTypes)... args); + #else +@@ -65,7 +65,7 @@ namespace boost + private: + volatile thread_detail::uintmax_atomic_t epoch; + +-#ifndef BOOST_NO_CXX11_VARIADIC_TEMPLATES ++#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) + template + friend void call_once(once_flag& flag, BOOST_THREAD_RV_REF(Function) f, BOOST_THREAD_RV_REF(ArgTypes)... args); + #else +@@ -118,7 +118,7 @@ namespace boost + // http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2444.html + + +-#ifndef BOOST_NO_CXX11_VARIADIC_TEMPLATES ++#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) + + + template +diff --git a/boost/thread/pthread/once_atomic.hpp b/boost/thread/pthread/once_atomic.hpp +index 9e2f876..923f07b 100644 +--- a/boost/thread/pthread/once_atomic.hpp ++++ b/boost/thread/pthread/once_atomic.hpp +@@ -115,7 +115,7 @@ namespace boost + #endif + + +-#ifndef BOOST_NO_CXX11_VARIADIC_TEMPLATES ++#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES) && !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) + + template + inline void call_once(once_flag& flag, BOOST_THREAD_RV_REF(Function) f, BOOST_THREAD_RV_REF(ArgTypes)... args) +diff --git a/boost/thread/win32/once.hpp b/boost/thread/win32/once.hpp +index cafcfd4..9b37b31 100644 +--- a/boost/thread/win32/once.hpp ++++ b/boost/thread/win32/once.hpp +@@ -227,7 +227,7 @@ namespace boost + } + } + +-#ifndef BOOST_NO_CXX11_VARIADIC_TEMPLATES ++#if !defined BOOST_NO_CXX11_VARIADIC_TEMPLATES && !defined(BOOST_NO_CXX11_RVALUE_REFERENCES) + //#if defined(BOOST_THREAD_RVALUE_REFERENCES_DONT_MATCH_FUNTION_PTR) + inline void call_once(once_flag& flag, void (*f)()) + { -- cgit 1.4.1 From 0a32eab91e7a547325958da2581933a98095d50c Mon Sep 17 00:00:00 2001 From: Jude Taylor Date: Mon, 5 Oct 2015 08:46:49 -0700 Subject: fix LLVM packages to work in darwin stdenv --- .../compilers/llvm/3.7/libc++/default.nix | 9 ----- pkgs/development/compilers/llvm/3.7/libc++abi.nix | 2 +- pkgs/development/compilers/llvm/3.7/llvm.nix | 6 ++-- .../development/interpreters/perl/5.22/default.nix | 7 +++- .../interpreters/perl/5.22/no-libutil.patch | 16 +++++---- pkgs/development/libraries/gmp/6.x.nix | 2 ++ pkgs/development/libraries/gmp/l0m4_tmp.patch | 27 ++++++++++++++ pkgs/development/libraries/ncurses/clang.patch | 42 ---------------------- pkgs/development/libraries/ncurses/default.nix | 2 -- .../libraries/openssl/darwin-arch.patch | 13 +++---- pkgs/stdenv/pure-darwin/default.nix | 8 +++-- pkgs/tools/misc/cloc/default.nix | 8 ++++- 12 files changed, 68 insertions(+), 74 deletions(-) create mode 100644 pkgs/development/libraries/gmp/l0m4_tmp.patch delete mode 100644 pkgs/development/libraries/ncurses/clang.patch (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/compilers/llvm/3.7/libc++/default.nix b/pkgs/development/compilers/llvm/3.7/libc++/default.nix index cd985d89098..db1475cfc14 100644 --- a/pkgs/development/compilers/llvm/3.7/libc++/default.nix +++ b/pkgs/development/compilers/llvm/3.7/libc++/default.nix @@ -12,15 +12,6 @@ stdenv.mkDerivation rec { preConfigure = '' # Get headers from the cxxabi source so we can see private headers not installed by the cxxabi package cmakeFlagsArray=($cmakeFlagsArray -DLIBCXX_CXX_ABI_INCLUDE_PATHS="$NIX_BUILD_TOP/libcxxabi-${version}.src/include") - '' + - stdenv.lib.optionalString stdenv.isDarwin '' - # instead of allowing libc++ to link with /usr/lib/libc++abi.dylib, - # force it to link with our copy - substituteInPlace lib/CMakeLists.txt \ - --replace 'OSX_RE_EXPORT_LINE "/usr/lib/libc++abi.dylib' \ - 'OSX_RE_EXPORT_LINE "${libcxxabi}/lib/libc++abi.dylib' \ - --replace '"''${CMAKE_OSX_SYSROOT}/usr/lib/libc++abi.dylib"' \ - '"${libcxxabi}/lib/libc++abi.dylib"' ''; patches = [ ./darwin.patch ]; diff --git a/pkgs/development/compilers/llvm/3.7/libc++abi.nix b/pkgs/development/compilers/llvm/3.7/libc++abi.nix index a1b300ffa04..97f182a9af8 100644 --- a/pkgs/development/compilers/llvm/3.7/libc++abi.nix +++ b/pkgs/development/compilers/llvm/3.7/libc++abi.nix @@ -27,7 +27,7 @@ stdenv.mkDerivation { done make install install -d 755 $out/include - install -m 644 ../include/cxxabi.h $out/include + install -m 644 ../include/*.h $out/include '' else '' install -d -m 755 $out/include $out/lib diff --git a/pkgs/development/compilers/llvm/3.7/llvm.nix b/pkgs/development/compilers/llvm/3.7/llvm.nix index 4ff61b27878..9784a64e7c3 100644 --- a/pkgs/development/compilers/llvm/3.7/llvm.nix +++ b/pkgs/development/compilers/llvm/3.7/llvm.nix @@ -11,6 +11,7 @@ , ncurses , version , zlib +, libcxxabi , compiler-rt_src }: @@ -27,7 +28,8 @@ in stdenv.mkDerivation rec { mv compiler-rt-* $sourceRoot/projects/compiler-rt ''; - buildInputs = [ perl groff cmake libxml2 python libffi ] /* ++ stdenv.lib.optional stdenv.isLinux valgrind */; + buildInputs = [ perl groff cmake libxml2 python libffi ] + ++ stdenv.lib.optional stdenv.isDarwin libcxxabi; propagatedBuildInputs = [ ncurses zlib ]; @@ -47,7 +49,7 @@ in stdenv.mkDerivation rec { "-DBUILD_SHARED_LIBS=ON" "-DLLVM_BINUTILS_INCDIR=${binutils}/include" ] ++ stdenv.lib.optionals ( isDarwin) [ - "-DCMAKE_CXX_FLAGS=-stdlib=libc++" + "-DLLVM_ENABLE_LIBCXX=ON" "-DCAN_TARGET_i386=false" ]; diff --git a/pkgs/development/interpreters/perl/5.22/default.nix b/pkgs/development/interpreters/perl/5.22/default.nix index e0be8610fb7..4b0f4364ea2 100644 --- a/pkgs/development/interpreters/perl/5.22/default.nix +++ b/pkgs/development/interpreters/perl/5.22/default.nix @@ -59,9 +59,14 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; + postPatch = '' + pwd="$(type -P pwd)" + substituteInPlace dist/PathTools/Cwd.pm \ + --replace "pwd_cmd = 'pwd'" "pwd_cmd = '$pwd'" + ''; + preConfigure = '' - configureFlags="$configureFlags -Dprefix=$out -Dman1dir=$out/share/man/man1 -Dman3dir=$out/share/man/man3" ${optionalString stdenv.isArm '' diff --git a/pkgs/development/interpreters/perl/5.22/no-libutil.patch b/pkgs/development/interpreters/perl/5.22/no-libutil.patch index 68d44612bfe..d6356a52437 100644 --- a/pkgs/development/interpreters/perl/5.22/no-libutil.patch +++ b/pkgs/development/interpreters/perl/5.22/no-libutil.patch @@ -1,12 +1,14 @@ -diff -ru -x '*~' perl-5.14.2-orig/Configure perl-5.14.2/Configure ---- perl-5.14.2-orig/Configure 2011-09-26 11:44:34.000000000 +0200 -+++ perl-5.14.2/Configure 2012-02-16 17:24:50.779839039 +0100 -@@ -1368,7 +1368,7 @@ +diff --git a/Configure b/Configure +index 0a405d3..1871298 100755 +--- a/Configure ++++ b/Configure +@@ -1455,7 +1455,7 @@ libswanted_uselargefiles='' : List of libraries we want. : If anyone needs extra -lxxx, put those in a hint file. - libswanted="socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld sun" --libswanted="$libswanted m crypt sec util c cposix posix ucb bsd BSD" -+libswanted="$libswanted m crypt sec c cposix posix ucb bsd BSD" + libswanted="cl pthread socket bind inet nsl nm ndbm gdbm dbm db malloc dl ld" +-libswanted="$libswanted sun m crypt sec util c cposix posix ucb bsd BSD" ++libswanted="$libswanted sun m crypt sec c cposix posix ucb bsd BSD" : We probably want to search /usr/shlib before most other libraries. : This is only used by the lib/ExtUtils/MakeMaker.pm routine extliblist. glibpth=`echo " $glibpth " | sed -e 's! /usr/shlib ! !'` + diff --git a/pkgs/development/libraries/gmp/6.x.nix b/pkgs/development/libraries/gmp/6.x.nix index 171611e1249..083bfec9b05 100644 --- a/pkgs/development/libraries/gmp/6.x.nix +++ b/pkgs/development/libraries/gmp/6.x.nix @@ -33,6 +33,8 @@ stdenv.mkDerivation rec { configureFlagsArray+=("--build=$(./configfsf.guess)") ''; + patches = [ ./l0m4_tmp.patch ]; + doCheck = true; dontDisableStatic = withStatic; diff --git a/pkgs/development/libraries/gmp/l0m4_tmp.patch b/pkgs/development/libraries/gmp/l0m4_tmp.patch new file mode 100644 index 00000000000..4431106cba6 --- /dev/null +++ b/pkgs/development/libraries/gmp/l0m4_tmp.patch @@ -0,0 +1,27 @@ +# HG changeset patch +# User Torbjorn Granlund +# Date 1396470504 -7200 +# Node ID 1fab0adc5ff7d9ecddcbda96f407da58347bb49c +# Parent db645603dcdb41afcf78b19b551ecd5a01c3841c +Workaround for Darwin assembler quirk. + +diff -r db645603dcdb -r 1fab0adc5ff7 mpn/x86_64/k8/redc_1.asm +--- a/mpn/x86_64/k8/redc_1.asm Mon Mar 31 23:04:32 2014 +0200 ++++ b/mpn/x86_64/k8/redc_1.asm Wed Apr 02 22:28:24 2014 +0200 +@@ -114,7 +114,7 @@ + + JUMPTABSECT + ALIGN(8) +-L(tab): JMPENT( L(0m4), L(tab)) ++L(tab): JMPENT( L(0), L(tab)) + JMPENT( L(1), L(tab)) + JMPENT( L(2), L(tab)) + JMPENT( L(3), L(tab)) +@@ -397,6 +397,7 @@ + + + ALIGN(16) ++L(0): + L(0m4): + L(lo0): mov (mp,nneg,8), %rax + mov nneg, i diff --git a/pkgs/development/libraries/ncurses/clang.patch b/pkgs/development/libraries/ncurses/clang.patch deleted file mode 100644 index ce33049bf40..00000000000 --- a/pkgs/development/libraries/ncurses/clang.patch +++ /dev/null @@ -1,42 +0,0 @@ -diff -ruNp ncurses-5.8.orig/c++/cursesf.h ncurses-5.8/c++/cursesf.h ---- ncurses-5.8.orig/c++/cursesf.h 2005-08-13 21:08:24.000000000 +0300 -+++ ncurses-5.8/c++/cursesf.h 2011-04-03 18:29:29.000000000 +0300 -@@ -681,7 +681,7 @@ public: - const T* p_UserData = STATIC_CAST(T*)(0), - bool with_frame=FALSE, - bool autoDelete_Fields=FALSE) -- : NCursesForm (Fields, with_frame, autoDelete_Fields) { -+ : NCursesForm (&Fields, with_frame, autoDelete_Fields) { - if (form) - set_user (const_cast(p_UserData)); - }; -@@ -694,7 +694,7 @@ public: - const T* p_UserData = STATIC_CAST(T*)(0), - bool with_frame=FALSE, - bool autoDelete_Fields=FALSE) -- : NCursesForm (Fields, nlines, ncols, begin_y, begin_x, -+ : NCursesForm (&Fields, nlines, ncols, begin_y, begin_x, - with_frame, autoDelete_Fields) { - if (form) - set_user (const_cast(p_UserData)); -diff -ruNp ncurses-5.8.orig/c++/cursesm.h ncurses-5.8/c++/cursesm.h ---- ncurses-5.8.orig/c++/cursesm.h 2005-08-13 21:10:36.000000000 +0300 -+++ ncurses-5.8/c++/cursesm.h 2011-04-03 18:31:42.000000000 +0300 -@@ -639,7 +639,7 @@ public: - const T* p_UserData = STATIC_CAST(T*)(0), - bool with_frame=FALSE, - bool autoDelete_Items=FALSE) -- : NCursesMenu (Items, with_frame, autoDelete_Items) { -+ : NCursesMenu (&Items, with_frame, autoDelete_Items) { - if (menu) - set_user (const_cast(p_UserData)); - }; -@@ -651,7 +651,7 @@ public: - int begin_x = 0, - const T* p_UserData = STATIC_CAST(T*)(0), - bool with_frame=FALSE) -- : NCursesMenu (Items, nlines, ncols, begin_y, begin_x, with_frame) { -+ : NCursesMenu (&Items, nlines, ncols, begin_y, begin_x, with_frame) { - if (menu) - set_user (const_cast(p_UserData)); - }; diff --git a/pkgs/development/libraries/ncurses/default.nix b/pkgs/development/libraries/ncurses/default.nix index 046c7347f86..a76bba24c62 100644 --- a/pkgs/development/libraries/ncurses/default.nix +++ b/pkgs/development/libraries/ncurses/default.nix @@ -14,8 +14,6 @@ stdenv.mkDerivation rec { sha256 = "0q3jck7lna77z5r42f13c4xglc7azd19pxfrjrpgp2yf615w4lgm"; }; - patches = [ ./clang.patch ]; - configureFlags = [ "--with-shared" "--with-cxx-shared" diff --git a/pkgs/development/libraries/openssl/darwin-arch.patch b/pkgs/development/libraries/openssl/darwin-arch.patch index 63db3efc084..238dd7d08d8 100644 --- a/pkgs/development/libraries/openssl/darwin-arch.patch +++ b/pkgs/development/libraries/openssl/darwin-arch.patch @@ -1,12 +1,13 @@ -diff -ru -x '*~' openssl-1.0.1c-orig/Configure openssl-1.0.1c/Configure ---- openssl-1.0.1c-orig/Configure 2012-03-14 23:20:40.000000000 +0100 -+++ openssl-1.0.1c/Configure 2012-12-18 17:29:30.268090633 +0100 -@@ -579,7 +579,7 @@ +diff --git a/Configure b/Configure +index d99eed7..341dbd0 100755 +--- a/Configure ++++ b/Configure +@@ -638,7 +638,7 @@ my %table=( "darwin64-ppc-cc","cc:-arch ppc64 -O3 -DB_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${ppc64_asm}:osx64:dlfcn:darwin-shared:-fPIC -fno-common:-arch ppc64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", "darwin-i386-cc","cc:-arch i386 -O3 -fomit-frame-pointer -DL_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:BN_LLONG RC4_INT RC4_CHUNK DES_UNROLL BF_PTR:".eval{my $asm=$x86_asm;$asm=~s/cast\-586\.o//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch i386 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", "debug-darwin-i386-cc","cc:-arch i386 -g3 -DL_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:BN_LLONG RC4_INT RC4_CHUNK DES_UNROLL BF_PTR:${x86_asm}:macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch i386 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", --"darwin64-x86_64-cc","cc:-arch x86_64 -O3 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$x86_64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch x86_64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", +-"darwin64-x86_64-cc","cc:-arch x86_64 -O3 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$x86_64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch x86_64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", +"darwin64-x86_64-cc","cc:-O3 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$x86_64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", + "debug-darwin64-x86_64-cc","cc:-arch x86_64 -ggdb -g2 -O0 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$x86_64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch x86_64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", "debug-darwin-ppc-cc","cc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DCRYPTO_MDEBUG -DB_ENDIAN -g -Wall -O::-D_REENTRANT:MACOSX::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${ppc32_asm}:osx32:dlfcn:darwin-shared:-fPIC:-dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", # iPhoneOS/iOS - "iphoneos-cross","llvm-gcc:-O3 -isysroot \$(CROSS_TOP)/SDKs/\$(CROSS_SDK) -fomit-frame-pointer -fno-common::-D_REENTRANT:iOS:-Wl,-search_paths_first%:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${no_asm}:dlfcn:darwin-shared:-fPIC -fno-common:-dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", diff --git a/pkgs/stdenv/pure-darwin/default.nix b/pkgs/stdenv/pure-darwin/default.nix index 51780b6f774..a50a63fbda6 100644 --- a/pkgs/stdenv/pure-darwin/default.nix +++ b/pkgs/stdenv/pure-darwin/default.nix @@ -220,11 +220,13 @@ in rec { persistent3 = orig: with stage3.pkgs; { inherit gnumake gzip gnused bzip2 gawk ed xz patch bash - libcxxabi libcxx ncurses libffi zlib llvm gmp pcre gnugrep + libcxxabi libcxx ncurses libffi zlib gmp pcre gnugrep coreutils findutils diffutils patchutils; - llvmPackages = orig.llvmPackages // { - inherit (llvmPackages) llvm clang-unwrapped; + llvmPackages = let llvmOverride = llvmPackages.llvm.override { inherit libcxxabi; }; + in orig.llvmPackages // { + llvm = llvmOverride; + clang-unwrapped = llvmPackages.clang-unwrapped.override { llvm = llvmOverride; }; }; darwin = orig.darwin // { diff --git a/pkgs/tools/misc/cloc/default.nix b/pkgs/tools/misc/cloc/default.nix index bb278dbe1b1..0b5796d4ac3 100644 --- a/pkgs/tools/misc/cloc/default.nix +++ b/pkgs/tools/misc/cloc/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, perl, AlgorithmDiff, RegexpCommon }: +{ stdenv, fetchurl, fetchpatch, perl, AlgorithmDiff, RegexpCommon }: stdenv.mkDerivation rec { @@ -11,6 +11,12 @@ stdenv.mkDerivation rec { sha256 = "1w3mz69h2i7pscvi9q7yp7wimds8g38c5ph78cj5pvjl5wa035rh"; }; + patches = [ (fetchpatch { + name = "perl-5.22.patch"; + url = "https://bugs.archlinux.org/task/45494?getfile=13174"; + sha256 = "1xxwqjy2q2fdza7kfp9ld0yzljkdsrgm8a9pwnmx5q4adigcjjsz"; + }) ]; + buildInputs = [ perl AlgorithmDiff RegexpCommon ]; makeFlags = [ "prefix=" "DESTDIR=$(out)" "INSTALL=install" ]; -- cgit 1.4.1 From 741bf840dad05cd1728481045466811ae8ae8281 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 6 Oct 2015 15:24:20 +0200 Subject: Revert "Merge pull request #9543 from NixOS/staging.post-15.06" This reverts commit f61176c5396ed513f3d399f73f38ab78a066667f, reversing changes made to a27ca029ee2b39e04d7d2a516a7228f4b62067fb. Conflicts: pkgs/development/libraries/ncurses/default.nix --- doc/haskell-users-guide.md | 21 ------ lib/maintainers.nix | 2 - nixos/modules/services/mail/opensmtpd.nix | 20 +----- .../modules/services/networking/networkmanager.nix | 5 +- nixos/modules/tasks/network-interfaces.nix | 2 +- pkgs/applications/audio/audacity/default.nix | 8 +-- pkgs/applications/audio/jackmix/default.nix | 35 --------- .../applications/graphics/gimp/plugins/default.nix | 2 +- pkgs/applications/graphics/hugin/default.nix | 4 +- pkgs/applications/networking/ids/daq/default.nix | 6 +- pkgs/applications/networking/ids/snort/default.nix | 12 +--- pkgs/applications/networking/iptraf-ng/default.nix | 44 ------------ .../git-and-tools/git-hub/default.nix | 30 ++++---- .../version-management/subversion/default.nix | 16 +---- pkgs/applications/video/smplayer/default.nix | 8 +-- pkgs/build-support/build-fhs-chrootenv/env.nix | 7 -- pkgs/data/fonts/symbola/default.nix | 9 ++- .../ruby/bundler-env/default-gem-config.nix | 7 +- pkgs/development/libraries/glpk/default.nix | 4 +- pkgs/development/libraries/libdnet/default.nix | 4 +- pkgs/development/libraries/libunwind/native.nix | 17 +++++ pkgs/development/libraries/ncurses/default.nix | 24 ++++--- pkgs/development/libraries/ncurses/gcc-5.patch | 46 ++++++++++++ pkgs/development/libraries/neon/default.nix | 5 +- pkgs/development/libraries/openssl/1.0.2.x.nix | 84 ++++++++++++++++++++++ pkgs/development/libraries/openssl/default.nix | 4 +- pkgs/development/web/iojs/default.nix | 36 ---------- pkgs/development/web/nodejs/default-arch.patch | 24 ------- pkgs/development/web/nodejs/default.nix | 7 +- pkgs/development/web/nodejs/no-xcode.patch | 21 ++++++ pkgs/development/web/nodejs/pkg-libpath.patch | 13 ---- pkgs/development/web/nodejs/v0_10.nix | 2 +- pkgs/misc/jackaudio/jack1.nix | 3 +- pkgs/misc/urbit/default.nix | 42 ----------- pkgs/os-specific/linux/kernel/linux-3.14.nix | 4 +- pkgs/os-specific/linux/miraclecast/default.nix | 26 ------- pkgs/os-specific/linux/nvidiabl/default.nix | 2 - pkgs/os-specific/linux/nvidiabl/linux4compat.patch | 22 ------ pkgs/os-specific/linux/syslinux/default.nix | 3 +- pkgs/os-specific/linux/syslinux/gcc5-fix.patch | 26 +++++++ pkgs/os-specific/linux/systemd/default.nix | 3 +- pkgs/servers/mail/opensmtpd/default.nix | 7 +- pkgs/servers/mail/opensmtpd/extras.nix | 79 -------------------- pkgs/servers/mail/opensmtpd/proc_path.diff | 76 -------------------- pkgs/stdenv/linux/default.nix | 9 ++- pkgs/tools/filesystems/duff/default.nix | 19 ++--- pkgs/tools/graphics/enblend-enfuse/default.nix | 10 ++- pkgs/tools/misc/heatseeker/default.nix | 28 -------- pkgs/tools/networking/openssh/default.nix | 6 +- .../openssh/openssh-6.9p1-security-7.0.patch | 65 +++++++++++++++++ pkgs/top-level/all-packages.nix | 48 +++++-------- pkgs/top-level/go-packages.nix | 20 ------ pkgs/top-level/perl-packages.nix | 10 +-- 53 files changed, 385 insertions(+), 652 deletions(-) delete mode 100644 pkgs/applications/audio/jackmix/default.nix delete mode 100644 pkgs/applications/networking/iptraf-ng/default.nix create mode 100644 pkgs/development/libraries/libunwind/native.nix create mode 100644 pkgs/development/libraries/ncurses/gcc-5.patch create mode 100644 pkgs/development/libraries/openssl/1.0.2.x.nix delete mode 100644 pkgs/development/web/iojs/default.nix delete mode 100644 pkgs/development/web/nodejs/default-arch.patch delete mode 100644 pkgs/development/web/nodejs/pkg-libpath.patch delete mode 100644 pkgs/misc/urbit/default.nix delete mode 100644 pkgs/os-specific/linux/miraclecast/default.nix delete mode 100644 pkgs/os-specific/linux/nvidiabl/linux4compat.patch create mode 100644 pkgs/os-specific/linux/syslinux/gcc5-fix.patch delete mode 100644 pkgs/servers/mail/opensmtpd/extras.nix delete mode 100644 pkgs/servers/mail/opensmtpd/proc_path.diff delete mode 100644 pkgs/tools/misc/heatseeker/default.nix create mode 100644 pkgs/tools/networking/openssh/openssh-6.9p1-security-7.0.patch (limited to 'pkgs/development/libraries') diff --git a/doc/haskell-users-guide.md b/doc/haskell-users-guide.md index 446f08eb697..b06a81e5b36 100644 --- a/doc/haskell-users-guide.md +++ b/doc/haskell-users-guide.md @@ -666,27 +666,6 @@ to find out the store path of the system's zlib library. Now, you can The same thing applies to `cabal configure`, of course, if you're building with `cabal-install` instead of Stack. -## Creating statically linked binaries - -There are two levels of static linking. The first option is to configure the -build with the Cabal flag `--disable-executable-dynamic`. In Nix expressions, -this can be achieved by setting the attribute: - - enableSharedExecutables = false; - -That gives you a binary with statically linked Haskell libraries and -dynamically linked system libraries. - -To link both Haskell libraries and system libraries statically, the additional -flags `--ghc-option=-optl=-static --ghc-option=-optl=-pthread` need to be used. -In Nix, this is accomplished with: - - configureFlags = [ "--ghc-option=-optl=-static" "--ghc-option=-optl=-pthread" ]; - -It's important to realize, however, that most system libraries in Nix are built -as shared libraries only, i.e. there is just no static library available that -Cabal could link! - # Other resources diff --git a/lib/maintainers.nix b/lib/maintainers.nix index 071a4d45ba2..121fca95164 100644 --- a/lib/maintainers.nix +++ b/lib/maintainers.nix @@ -144,7 +144,6 @@ jwilberding = "Jordan Wilberding "; jzellner = "Jeff Zellner "; kamilchm = "Kamil Chmielewski "; - kampfschlaefer = "Arnold Krille "; khumba = "Bryan Gardiner "; kkallio = "Karn Kallio "; koral = "Koral "; @@ -180,7 +179,6 @@ meditans = "Carlo Nucera "; meisternu = "Matt Miemiec "; michelk = "Michel Kuhlmann "; - michaelpj = "Michael Peyton Jones "; mirdhyn = "Merlin Gaillard "; mschristiansen = "Mikkel Christiansen "; modulistic = "Pablo Costa "; diff --git a/nixos/modules/services/mail/opensmtpd.nix b/nixos/modules/services/mail/opensmtpd.nix index a1cfd84365a..a3e50b42292 100644 --- a/nixos/modules/services/mail/opensmtpd.nix +++ b/nixos/modules/services/mail/opensmtpd.nix @@ -46,17 +46,6 @@ in { is left empty, the OpenSMTPD server will not start. ''; }; - - procPackages = mkOption { - type = types.listOf types.path; - default = []; - description = '' - Packages to search for filters, tables, queues, and schedulers. - - Add OpenSMTPD-extras here if you want to use the filters, etc. from - that package. - ''; - }; }; }; @@ -83,19 +72,12 @@ in { }; }; - systemd.services.opensmtpd = let - procEnv = pkgs.buildEnv { - name = "opensmtpd-procs"; - paths = [ opensmtpd ] ++ cfg.procPackages; - pathsToLink = [ "/libexec/opensmtpd" ]; - }; - in { + systemd.services.opensmtpd = { wantedBy = [ "multi-user.target" ]; wants = [ "network.target" ]; after = [ "network.target" ]; preStart = "mkdir -p /var/spool"; serviceConfig.ExecStart = "${opensmtpd}/sbin/smtpd -d -f ${conf} ${args}"; - environment.OPENSMTPD_PROC_PATH = "${procEnv}/libexec/opensmtpd"; }; environment.systemPackages = [ (pkgs.runCommand "opensmtpd-sendmail" {} '' diff --git a/nixos/modules/services/networking/networkmanager.nix b/nixos/modules/services/networking/networkmanager.nix index 8370eca21e5..adbc6099c95 100644 --- a/nixos/modules/services/networking/networkmanager.nix +++ b/nixos/modules/services/networking/networkmanager.nix @@ -71,10 +71,11 @@ let ${coreutils}/bin/rm -f $tmp $tmp.ns ''; + # pre-up and pre-down hooks were added in NM 0.9.10, but we still use 0.9.0 dispatcherTypesSubdirMap = { "basic" = ""; - "pre-up" = "pre-up.d/"; - "pre-down" = "pre-down.d/"; + /*"pre-up" = "pre-up.d/"; + "pre-down" = "pre-down.d/";*/ }; in { diff --git a/nixos/modules/tasks/network-interfaces.nix b/nixos/modules/tasks/network-interfaces.nix index 03e647b1b1e..9ffede48bf5 100644 --- a/nixos/modules/tasks/network-interfaces.nix +++ b/nixos/modules/tasks/network-interfaces.nix @@ -59,7 +59,7 @@ let # place the interface which is named after the device at the beginning. wlanListDeviceFirst = device: interfaces: if hasAttr device interfaces - then mapAttrsToList (n: v: v//{_iName=n;}) (filterAttrs (n: _: n==device) interfaces) ++ mapAttrsToList (n: v: v//{_iName=n;}) (filterAttrs (n: _: n!=device) interfaces) + then [{"${device}"=interfaces.device; _iName=device;}] ++ mapAttrsToList (n: v: v//{_iName=n;}) (filterAttrs (n: _: n!=device) interfaces) else mapAttrsToList (n: v: v // {_iName = n;}) interfaces; # udev script that configures a physical wlan device and adds virtual interfaces diff --git a/pkgs/applications/audio/audacity/default.nix b/pkgs/applications/audio/audacity/default.nix index 67ec6b5a419..6f25693f734 100644 --- a/pkgs/applications/audio/audacity/default.nix +++ b/pkgs/applications/audio/audacity/default.nix @@ -1,6 +1,6 @@ { stdenv, fetchurl, wxGTK, pkgconfig, gettext, gtk, glib, zlib, perl, intltool, libogg, libvorbis, libmad, alsaLib, libsndfile, soxr, flac, lame, - expat, libid3tag, ffmpeg, soundtouch /*, portaudio - given up fighting their portaudio.patch */ + expat, libid3tag, ffmpeg /*, portaudio - given up fighting their portaudio.patch */ }: stdenv.mkDerivation rec { @@ -19,13 +19,11 @@ stdenv.mkDerivation rec { rm -r lib-src-rm/ ''; - configureFlags = "--with-libsamplerate"; - buildInputs = [ pkgconfig gettext wxGTK gtk expat alsaLib libsndfile soxr libid3tag - ffmpeg libmad lame libvorbis flac soundtouch - ]; #ToDo: detach sbsms + ffmpeg libmad lame libvorbis flac + ]; #ToDo: soundtouch, detach sbsms dontDisableStatic = true; doCheck = true; diff --git a/pkgs/applications/audio/jackmix/default.nix b/pkgs/applications/audio/jackmix/default.nix deleted file mode 100644 index 8176a340470..00000000000 --- a/pkgs/applications/audio/jackmix/default.nix +++ /dev/null @@ -1,35 +0,0 @@ -{ stdenv, fetchurl, pkgs, jack ? pkgs.libjack2 }: - -stdenv.mkDerivation rec { - name = "jackmix-0.5.2"; - src = fetchurl { - url = https://github.com/kampfschlaefer/jackmix/archive/v0.5.2.tar.gz; - sha256 = "18f5v7g66mgarhs476frvayhch7fy4nyjf2xivixc061ipn0m82j"; - }; - - buildInputs = [ - pkgs.pkgconfig - pkgs.scons - pkgs.kde4.qt4 - pkgs.lash - jack - ]; - - buildPhase = '' - scons - ''; - installPhase = '' - mkdir -p $out/bin - cp jackmix/jackmix $out/bin - ''; - - meta = { - description = "Matrix-Mixer for the Jack-Audio-connection-Kit"; - homepage = http://www.arnoldarts.de/jackmix/; - license = stdenv.lib.licenses.gpl2; - maintainers = [ stdenv.lib.maintainers.kampfschlaefer ]; - platforms = stdenv.lib.platforms.linux; - }; -} - - diff --git a/pkgs/applications/graphics/gimp/plugins/default.nix b/pkgs/applications/graphics/gimp/plugins/default.nix index 702911fee74..ea638de7925 100644 --- a/pkgs/applications/graphics/gimp/plugins/default.nix +++ b/pkgs/applications/graphics/gimp/plugins/default.nix @@ -245,7 +245,7 @@ rec { /* =============== simple script files ==================== */ - # also have a look at enblend-enfuse in all-packages.nix + # also have a look at enblendenfuse in all-packages.nix exposureBlend = scriptDerivation { name = "exposure-blend"; src = fetchurl { diff --git a/pkgs/applications/graphics/hugin/default.nix b/pkgs/applications/graphics/hugin/default.nix index b11ed1a99df..88912cbda55 100644 --- a/pkgs/applications/graphics/hugin/default.nix +++ b/pkgs/applications/graphics/hugin/default.nix @@ -1,7 +1,7 @@ { stdenv, cmake, fetchurl, gnumake, pkgconfig , boost, gettext, tclap, wxGTK , freeglut, glew, libXi, libXmu, mesa -, autopanosiftc, enblend-enfuse, exiv2, ilmbase, lensfun, libpng, libtiff +, autopanosiftc, enblendenfuse, exiv2, ilmbase, lensfun, libpng, libtiff , openexr, panotools, perlPackages }: @@ -29,7 +29,7 @@ stdenv.mkDerivation rec { # commandline tools needed by the hugin batch processor # you may have to tell hugin (in the preferences) where these binaries reside - propagatedUserEnvPackages = [ autopanosiftc enblend-enfuse gnumake + propagatedUserEnvPackages = [ autopanosiftc enblendenfuse gnumake perlPackages.ImageExifTool ]; diff --git a/pkgs/applications/networking/ids/daq/default.nix b/pkgs/applications/networking/ids/daq/default.nix index 9339bfef6e0..c4a82966238 100644 --- a/pkgs/applications/networking/ids/daq/default.nix +++ b/pkgs/applications/networking/ids/daq/default.nix @@ -1,4 +1,4 @@ -{stdenv, fetchurl, flex, bison, libpcap, libdnet, libnfnetlink, libnetfilter_queue}: +{stdenv, fetchurl, flex, bison, libpcap}: stdenv.mkDerivation rec { name = "daq-2.0.5"; @@ -9,9 +9,7 @@ stdenv.mkDerivation rec { sha256 = "0vdwb0r9kdlgj4g0i0swafbc7qik0zmks17mhqji8cl7hpdva13p"; }; - buildInputs = [ flex bison libpcap libdnet libnfnetlink libnetfilter_queue]; - - configureFlags = "--enable-nfq-module=yes --with-dnet-includes=${libdnet}/includes --with-dnet-libraries=${libdnet}/lib"; + buildInputs = [ flex bison libpcap ]; meta = { description = "Data AcQuisition library (DAQ), for packet I/O"; diff --git a/pkgs/applications/networking/ids/snort/default.nix b/pkgs/applications/networking/ids/snort/default.nix index 62c784a7fb7..ea7e0962699 100644 --- a/pkgs/applications/networking/ids/snort/default.nix +++ b/pkgs/applications/networking/ids/snort/default.nix @@ -1,4 +1,4 @@ -{stdenv, makeWrapper, fetchurl, libpcap, pcre, libdnet, daq, zlib, flex, bison}: +{stdenv, fetchurl, libpcap, pcre, libdnet, daq, zlib, flex, bison}: stdenv.mkDerivation rec { version = "2.9.7.2"; @@ -10,15 +10,7 @@ stdenv.mkDerivation rec { sha256 = "1gmlrh9ygpd5h6nnrr4090wk5n2yq2yrvwi7q6xbm6lxj4rcamyv"; }; - buildInputs = [ makeWrapper libpcap pcre libdnet daq zlib flex bison ]; - - enableParallelBuilding = true; - - configureFlags = "--disable-static-daq --enable-control-socket --with-daq-includes=${daq}/includes --with-daq-libraries=${daq}/lib --dynamic-preprocessor-lib-dir $out/lib/snort_dynamicpreprocessor/ --dynamic-engine-lib-dir $out/lib/snort_dynamicengine"; - - postInstall = '' - wrapProgram $out/bin/snort --add-flags "--daq-dir ${daq}/lib/daq" - ''; + buildInputs = [ libpcap pcre libdnet daq zlib flex bison ]; meta = { description = "Network intrusion prevention and detection system (IDS/IPS)"; diff --git a/pkgs/applications/networking/iptraf-ng/default.nix b/pkgs/applications/networking/iptraf-ng/default.nix deleted file mode 100644 index 368d78a36f9..00000000000 --- a/pkgs/applications/networking/iptraf-ng/default.nix +++ /dev/null @@ -1,44 +0,0 @@ -{ stdenv, fetchurl, ncurses }: - -stdenv.mkDerivation rec { - version = "1.1.4"; - name = "iptraf-ng-${version}"; - - src = fetchurl { - url = "https://fedorahosted.org/releases/i/p/iptraf-ng/${name}.tar.gz"; - sha256 = "02gb8z9h2s6s1ybyikywz7jgb1mafdx88hijfasv3khcgkq0q53r"; - }; - - buildInputs = [ ncurses ]; - - configurePhase = '' - ./configure --prefix=$out/usr --sysconfdir=$out/etc \ - --localstatedir=$out/var --sbindir=$out/bin - ''; - - meta = { - description = "A console-based network monitoring utility (fork of iptraf)"; - longDescription = '' - IPTraf-ng is a console-based network monitoring utility. IPTraf-ng - gathers data like TCP connection packet and byte counts, interface - statistics and activity indicators, TCP/UDP traffic breakdowns, and LAN - station packet and byte counts. IPTraf-ng features include an IP traffic - monitor which shows TCP flag information, packet and byte counts, ICMP - details, OSPF packet types, and oversized IP packet warnings; interface - statistics showing IP, TCP, UDP, ICMP, non-IP and other IP packet counts, - IP checksum errors, interface activity and packet size counts; a TCP and - UDP service monitor showing counts of incoming and outgoing packets for - common TCP and UDP application ports, a LAN statistics module that - discovers active hosts and displays statistics about their activity; TCP, - UDP and other protocol display filters so you can view just the traffic - you want; logging; support for Ethernet, FDDI, ISDN, SLIP, PPP, and - loopback interfaces; and utilization of the built-in raw socket interface - of the Linux kernel, so it can be used on a wide variety of supported - network cards. - ''; - homepage = https://fedorahosted.org/iptraf-ng/; - license = stdenv.lib.licenses.gpl2; - platforms = stdenv.lib.platforms.linux; - maintainers = [ stdenv.lib.maintainers.devhell ]; - }; -} diff --git a/pkgs/applications/version-management/git-and-tools/git-hub/default.nix b/pkgs/applications/version-management/git-and-tools/git-hub/default.nix index e657215f2cd..e47d2569b10 100644 --- a/pkgs/applications/version-management/git-and-tools/git-hub/default.nix +++ b/pkgs/applications/version-management/git-and-tools/git-hub/default.nix @@ -1,7 +1,7 @@ { stdenv, fetchFromGitHub, docutils, python }: let version = "0.9.0"; in -stdenv.mkDerivation rec { +stdenv.mkDerivation { name = "git-hub-${version}"; src = fetchFromGitHub { @@ -11,6 +11,20 @@ stdenv.mkDerivation rec { owner = "sociomantic"; }; + meta = with stdenv.lib; { + inherit version; + description = "Git command line interface to GitHub"; + longDescription = '' + A simple command line interface to GitHub, enabling most useful GitHub + tasks (like creating and listing pull request or issues) to be accessed + directly through the Git command line. + ''; + homepage = https://github.com/sociomantic/git-hub; + license = licenses.gpl3Plus; + platforms = with platforms; linux; + maintainers = with maintainers; [ nckx ]; + }; + buildInputs = [ python ]; nativeBuildInputs = [ docutils ]; @@ -27,18 +41,4 @@ stdenv.mkDerivation rec { # Remove inert ftdetect vim plugin and a README that's a man page subset: rm -r $out/share/{doc,vim} ''; - - meta = with stdenv.lib; { - inherit version; - inherit (src.meta) homepage; - description = "Git command line interface to GitHub"; - longDescription = '' - A simple command line interface to GitHub, enabling most useful GitHub - tasks (like creating and listing pull request or issues) to be accessed - directly through the Git command line. - ''; - license = licenses.gpl3Plus; - platforms = platforms.linux; - maintainers = with maintainers; [ nckx ]; - }; } diff --git a/pkgs/applications/version-management/subversion/default.nix b/pkgs/applications/version-management/subversion/default.nix index f563bebd9db..db29360c9ec 100644 --- a/pkgs/applications/version-management/subversion/default.nix +++ b/pkgs/applications/version-management/subversion/default.nix @@ -8,7 +8,6 @@ , stdenv, fetchurl, apr, aprutil, zlib, sqlite , apacheHttpd ? null, expat, swig ? null, jdk ? null, python ? null, perl ? null , sasl ? null, serf ? null -, branch ? "1.9" }: assert bdbSupport -> aprutil.bdbSupport; @@ -16,26 +15,15 @@ assert httpServer -> apacheHttpd != null; assert pythonBindings -> swig != null && python != null; assert javahlBindings -> jdk != null && perl != null; -let - config = { - "1.9".ver_min = "2"; - "1.9".sha1 = "fb9db3b7ddf48ae37aa8785872301b59bfcc7017"; - - "1.8".ver_min = "14"; - "1.8".sha1 = "0698efc58373e7657f6dd3ce13cab7b002ffb497"; - }; -in -assert builtins.hasAttr branch config; - stdenv.mkDerivation (rec { - version = "${branch}." + config.${branch}.ver_min; + version = "1.9.2"; name = "subversion-${version}"; src = fetchurl { url = "mirror://apache/subversion/${name}.tar.bz2"; - inherit (config.${branch}) sha1; + sha1 = "fb9db3b7ddf48ae37aa8785872301b59bfcc7017"; }; buildInputs = [ zlib apr aprutil sqlite ] diff --git a/pkgs/applications/video/smplayer/default.nix b/pkgs/applications/video/smplayer/default.nix index d56ef964967..22935064c4b 100644 --- a/pkgs/applications/video/smplayer/default.nix +++ b/pkgs/applications/video/smplayer/default.nix @@ -1,16 +1,16 @@ -{ stdenv, fetchurl, qt5 }: +{ stdenv, fetchurl, qt4 }: stdenv.mkDerivation rec { - name = "smplayer-15.9.0"; + name = "smplayer-14.9.0.6690"; src = fetchurl { url = "mirror://sourceforge/smplayer/${name}.tar.bz2"; - sha256 = "1yx6kikaj9v5aj8aavvrcklx283wl6wrnpl905hjc7v03kgp1ac5"; + sha256 = "0nmw69kg8rqvl9icyx1r1v1pyxg6560363l0kyqyja18j79a3j2y"; }; patches = [ ./basegui.cpp.patch ]; - buildInputs = [ qt5.script ]; + buildInputs = [ qt4 ]; preConfigure = '' makeFlags="PREFIX=$out" diff --git a/pkgs/build-support/build-fhs-chrootenv/env.nix b/pkgs/build-support/build-fhs-chrootenv/env.nix index a2ac8288e8e..b659655f74b 100644 --- a/pkgs/build-support/build-fhs-chrootenv/env.nix +++ b/pkgs/build-support/build-fhs-chrootenv/env.nix @@ -182,12 +182,6 @@ let setupLibDirs = if isTargetBuild then setupLibDirs_target else setupLibDirs_multi; - setupIncludeDir = '' - if [ -x "${staticUsrProfileTarget}/include" ] - then - ln -s "${staticUsrProfileTarget}/include" - fi - ''; # the target profile is the actual profile that will be used for the chroot setupTargetProfile = '' @@ -198,7 +192,6 @@ let cd usr ${linkProfile staticUsrProfileTarget} ${setupLibDirs} - ${setupIncludeDir} cd .. rm -rf usr/etc usr/var ''; diff --git a/pkgs/data/fonts/symbola/default.nix b/pkgs/data/fonts/symbola/default.nix index 253fd9cd3e9..5b2113dc57e 100644 --- a/pkgs/data/fonts/symbola/default.nix +++ b/pkgs/data/fonts/symbola/default.nix @@ -5,7 +5,11 @@ stdenv.mkDerivation rec { src = fetchurl { url = "http://users.teilar.gr/~g1951d/Symbola.zip"; - sha256 = "1lfs2j816332ysvpb5ibj2gwpmyqyispqdl7skkshf2gra18hmhd"; + sha256 = "07bczpl3vqdpg2gakfddhzzgpb6v2wpasv7rwqxkyg9yd9lmbr0s"; + }; + docs_pdf = fetchurl { + url = "http://users.teilar.gr/~g1951d/Symbola.pdf"; + sha256 = "1zmq1ijl0k5hrc6vpa2xp9n1x2zrrd7ng3jwc9yf0qsi3pmkpk0p"; }; buildInputs = [ unzip ]; @@ -20,7 +24,8 @@ stdenv.mkDerivation rec { mkdir -p "$out/doc/${name}" cp -v Symbola.docx "$out/doc/${name}/" - cp -v Symbola.pdf "$out/doc/${name}/" + cp -v Symbola.htm "$out/doc/${name}/" + cp -v "$docs_pdf" "$out/doc/${name}/${docs_pdf.name}" ''; meta = { diff --git a/pkgs/development/interpreters/ruby/bundler-env/default-gem-config.nix b/pkgs/development/interpreters/ruby/bundler-env/default-gem-config.nix index 3ae74057a54..b4e04f6ec90 100644 --- a/pkgs/development/interpreters/ruby/bundler-env/default-gem-config.nix +++ b/pkgs/development/interpreters/ruby/bundler-env/default-gem-config.nix @@ -20,7 +20,7 @@ { lib, fetchurl, writeScript, ruby, libxml2, libxslt, python, stdenv, which , libiconv, postgresql, v8_3_16_14, clang, sqlite, zlib, imagemagick , pkgconfig , ncurses, xapian, gpgme, utillinux, fetchpatch, tzdata, icu, libffi -, cmake, libssh2, openssl, mysql, darwin +, cmake, libssh2, openssl, mysql }: let @@ -70,7 +70,6 @@ in "--with-exslt-lib=${libxslt}/lib" "--with-exslt-include=${libxslt}/include" ] ++ lib.optional stdenv.isDarwin "--with-iconv-dir=${libiconv}"; - buildInputs = lib.optional stdenv.isDarwin darwin.libobjc; }; pg = attrs: { @@ -120,10 +119,6 @@ in ''; }; - unf_ext = attrs: { - buildInputs = lib.optional stdenv.isDarwin darwin.libobjc; - }; - xapian-ruby = attrs: { # use the system xapian buildInputs = [ xapian pkgconfig zlib ]; diff --git a/pkgs/development/libraries/glpk/default.nix b/pkgs/development/libraries/glpk/default.nix index d4ff7d9603f..2b1a5b571ef 100644 --- a/pkgs/development/libraries/glpk/default.nix +++ b/pkgs/development/libraries/glpk/default.nix @@ -1,11 +1,11 @@ { fetchurl, stdenv }: stdenv.mkDerivation rec { - name = "glpk-4.56"; + name = "glpk-4.52.1"; src = fetchurl { url = "mirror://gnu/glpk/${name}.tar.gz"; - sha256 = "0syzix6qvpn0fzp08c84c8snansf1cam5vd0dk2w91mz2c85d18h"; + sha256 = "0nz9ngmx23c8gbjr8l8ygnfaanxj2mwbl8awpg630bgrkxdnhc9j"; }; doCheck = true; diff --git a/pkgs/development/libraries/libdnet/default.nix b/pkgs/development/libraries/libdnet/default.nix index 8911539d7b0..2bdeffb204d 100644 --- a/pkgs/development/libraries/libdnet/default.nix +++ b/pkgs/development/libraries/libdnet/default.nix @@ -10,9 +10,9 @@ stdenv.mkDerivation { sha1 = "71302be302e84fc19b559e811951b5d600d976f8"; }; - buildInputs = [ automake autoconf libtool ]; + configureFlags = [ "--enable-shared" ]; # shared libs required by hyenae - CFLAGS="-fPIC"; + buildInputs = [ automake autoconf libtool ]; # .so endings are missing (quick and dirty fix) postInstall = '' diff --git a/pkgs/development/libraries/libunwind/native.nix b/pkgs/development/libraries/libunwind/native.nix new file mode 100644 index 00000000000..6ce485ecaec --- /dev/null +++ b/pkgs/development/libraries/libunwind/native.nix @@ -0,0 +1,17 @@ +{ stdenv }: + +assert stdenv.isDarwin; + +stdenv.mkDerivation { + name = "libunwind-native"; + + unpackPhase = ":"; + dontBuild = true; + + installPhase = '' + mkdir -p $out/lib + cat /usr/lib/system/libunwind.dylib > $out/lib/libunwind.dylib + ''; + + meta.platforms = stdenv.lib.platforms.darwin; +} diff --git a/pkgs/development/libraries/ncurses/default.nix b/pkgs/development/libraries/ncurses/default.nix index a76bba24c62..51741005158 100644 --- a/pkgs/development/libraries/ncurses/default.nix +++ b/pkgs/development/libraries/ncurses/default.nix @@ -1,37 +1,38 @@ -{ lib, stdenv, fetchurl, pkgconfig, libtool +{ lib, stdenv, fetchurl , mouseSupport ? false , unicode ? true , gpm + +# Extra Options +, abiVersion ? "5" }: stdenv.mkDerivation rec { - name = "ncurses-6.0"; + name = "ncurses-5.9"; src = fetchurl { url = "mirror://gnu/ncurses/${name}.tar.gz"; - sha256 = "0q3jck7lna77z5r42f13c4xglc7azd19pxfrjrpgp2yf615w4lgm"; + sha256 = "0fsn7xis81za62afan0vvm38bvgzg5wfmv1m86flqcj0nj7jjilh"; }; + # gcc-5.patch should be removed after 5.9 + patches = [ ./gcc-5.patch ]; + configureFlags = [ "--with-shared" - "--with-cxx-shared" - "--with-libtool" "--without-debug" - "--enable-overwrite" # Needed for proper header installation "--enable-pc-files" "--enable-symlinks" ] ++ lib.optional unicode "--enable-widec"; - nativeBuildInputs = [ pkgconfig libtool ]; buildInputs = lib.optional (mouseSupport && stdenv.isLinux) gpm; preConfigure = '' configureFlagsArray+=("--includedir=$out/include") export PKG_CONFIG_LIBDIR="$out/lib/pkgconfig" mkdir -p "$PKG_CONFIG_LIBDIR" - configureFlagsArray+=("--with-pkg-config-libdir=$PKG_CONFIG_LIBDIR") '' + lib.optionalString stdenv.isCygwin '' sed -i -e 's,LIB_SUFFIX="t,LIB_SUFFIX=",' configure ''; @@ -68,6 +69,7 @@ stdenv.mkDerivation rec { for dylibtype in so dll dylib; do if [ -e "$out/lib/lib''${lib}$suffix.$dylibtype" ]; then ln -svf lib''${lib}$suffix.$dylibtype $out/lib/lib$lib$newsuffix.$dylibtype + ln -svf lib''${lib}$suffix.$dylibtype.${abiVersion} $out/lib/lib$lib$newsuffix.$dylibtype.${abiVersion} fi done for statictype in a dll.a la; do @@ -80,6 +82,10 @@ stdenv.mkDerivation rec { done ''; + preFixup = '' + rm $out/lib/*.a + ''; + meta = { description = "Free software emulation of curses in SVR4 and more"; @@ -106,6 +112,6 @@ stdenv.mkDerivation rec { passthru = { ldflags = "-lncurses"; - inherit unicode; + inherit unicode abiVersion; }; } diff --git a/pkgs/development/libraries/ncurses/gcc-5.patch b/pkgs/development/libraries/ncurses/gcc-5.patch new file mode 100644 index 00000000000..2448229b88e --- /dev/null +++ b/pkgs/development/libraries/ncurses/gcc-5.patch @@ -0,0 +1,46 @@ +https://bugs.gentoo.org/545114 + +extracted from the upstream change (which had many unrelated commits in one) + +From 97bb4678dc03e753290b39bbff30ba2825df9517 Mon Sep 17 00:00:00 2001 +From: "Thomas E. Dickey" +Date: Sun, 7 Dec 2014 03:10:09 +0000 +Subject: [PATCH] ncurses 5.9 - patch 20141206 + ++ modify MKlib_gen.sh to work around change in development version of + gcc introduced here: + https://gcc.gnu.org/ml/gcc-patches/2014-06/msg02185.html + https://gcc.gnu.org/ml/gcc-patches/2014-07/msg00236.html + (reports by Marcus Shawcroft, Maohui Lei). + +diff --git a/ncurses/base/MKlib_gen.sh b/ncurses/base/MKlib_gen.sh +index d8cc3c9..b91398c 100755 +--- a/ncurses/base/MKlib_gen.sh ++++ b/ncurses/base/MKlib_gen.sh +@@ -474,11 +474,22 @@ sed -n -f $ED1 \ + -e 's/gen_$//' \ + -e 's/ / /g' >>$TMP + ++cat >$ED1 < $ED2 ++cat $ED2 >$TMP ++ + $preprocessor $TMP 2>/dev/null \ +-| sed \ +- -e 's/ / /g' \ +- -e 's/^ //' \ +- -e 's/_Bool/NCURSES_BOOL/g' \ ++| sed -f $ED1 \ + | $AWK -f $AW2 \ + | sed -f $ED3 \ + | sed \ diff --git a/pkgs/development/libraries/neon/default.nix b/pkgs/development/libraries/neon/default.nix index 0ca64c9bb07..ffc409d271e 100644 --- a/pkgs/development/libraries/neon/default.nix +++ b/pkgs/development/libraries/neon/default.nix @@ -14,12 +14,11 @@ let in stdenv.mkDerivation rec { - version = "0.30.1"; - name = "neon-${version}"; + name = "neon-0.29.6"; src = fetchurl { url = "http://www.webdav.org/neon/${name}.tar.gz"; - sha256 = "1pawhk02x728xn396a1kcivy9gqm94srmgad6ymr9l0qvk02dih0"; + sha256 = "0hzbjqdx1z8zw0vmbknf159wjsxbcq8ii0wgwkqhxj3dimr0nr4w"; }; patches = optionals stdenv.isDarwin [ ./0.29.6-darwin-fix-configure.patch ]; diff --git a/pkgs/development/libraries/openssl/1.0.2.x.nix b/pkgs/development/libraries/openssl/1.0.2.x.nix new file mode 100644 index 00000000000..28254cb390d --- /dev/null +++ b/pkgs/development/libraries/openssl/1.0.2.x.nix @@ -0,0 +1,84 @@ +{ stdenv, fetchurl, perl +, withCryptodev ? false, cryptodevHeaders }: + +with stdenv.lib; +let + opensslCrossSystem = attrByPath [ "openssl" "system" ] + (throw "openssl needs its platform name cross building" null) + stdenv.cross; +in +stdenv.mkDerivation rec { + name = "openssl-1.0.2d"; + + src = fetchurl { + urls = [ + "http://www.openssl.org/source/${name}.tar.gz" + "http://openssl.linux-mirror.org/source/${name}.tar.gz" + ]; + sha1 = "d01d17b44663e8ffa6a33a5a30053779d9593c3d"; + }; + + patches = optional stdenv.isCygwin ./1.0.1-cygwin64.patch; + + nativeBuildInputs = [ perl ]; + buildInputs = stdenv.lib.optional withCryptodev cryptodevHeaders; + + # On x86_64-darwin, "./config" misdetects the system as + # "darwin-i386-cc". So specify the system type explicitly. + configureScript = + if stdenv.system == "x86_64-darwin" then "./Configure darwin64-x86_64-cc" + else if stdenv.system == "x86_64-solaris" then "./Configure solaris64-x86_64-gcc" + else "./config"; + + configureFlags = [ + "shared" + "--libdir=lib" + "--openssldir=etc/ssl" + ] ++ stdenv.lib.optionals withCryptodev [ + "-DHAVE_CRYPTODEV" + "-DUSE_CRYPTODEV_DIGESTS" + ]; + + makeFlags = [ + "MANDIR=$(out)/share/man" + ]; + + # Parallel building is broken in OpenSSL. + enableParallelBuilding = false; + + postInstall = '' + # If we're building dynamic libraries, then don't install static + # libraries. + if [ -n "$(echo $out/lib/*.so $out/lib/*.dylib $out/lib/*.dll)" ]; then + rm "$out/lib/"*.a + fi + + # remove dependency on Perl at runtime + rm -r $out/etc/ssl/misc $out/bin/c_rehash + ''; + + postFixup = '' + # Check to make sure we don't depend on perl + if grep -r '${perl}' $out; then + echo "Found an erroneous dependency on perl ^^^" >&2 + exit 1 + fi + ''; + + crossAttrs = { + preConfigure='' + # It's configure does not like --build or --host + export configureFlags="${concatStringsSep " " (configureFlags ++ [ opensslCrossSystem ])}" + ''; + + configureScript = "./Configure"; + }; + + meta = { + homepage = http://www.openssl.org/; + description = "A cryptographic library that implements the SSL and TLS protocols"; + platforms = stdenv.lib.platforms.all; + maintainers = [ stdenv.lib.maintainers.simons ]; + priority = 10; # resolves collision with ‘man-pages’ + }; +} diff --git a/pkgs/development/libraries/openssl/default.nix b/pkgs/development/libraries/openssl/default.nix index 31bd7fb2d67..ca3e7999f9b 100644 --- a/pkgs/development/libraries/openssl/default.nix +++ b/pkgs/development/libraries/openssl/default.nix @@ -8,14 +8,14 @@ let stdenv.cross; in stdenv.mkDerivation rec { - name = "openssl-1.0.2d"; + name = "openssl-1.0.1p"; src = fetchurl { urls = [ "http://www.openssl.org/source/${name}.tar.gz" "http://openssl.linux-mirror.org/source/${name}.tar.gz" ]; - sha256 = "671c36487785628a703374c652ad2cebea45fa920ae5681515df25d9f2c9a8c8"; + sha1 = "9d1977cc89242cd11471269ece2ed4650947c046"; }; outputs = [ "out" "man" ]; diff --git a/pkgs/development/web/iojs/default.nix b/pkgs/development/web/iojs/default.nix deleted file mode 100644 index a44a6d6c6c4..00000000000 --- a/pkgs/development/web/iojs/default.nix +++ /dev/null @@ -1,36 +0,0 @@ -{ stdenv, fetchurl, python, utillinux, openssl, http-parser, zlib, libuv }: - -let - version = "3.1.0"; - inherit (stdenv.lib) optional maintainers licenses platforms; -in stdenv.mkDerivation { - name = "iojs-${version}"; - - src = fetchurl { - url = "https://iojs.org/dist/v${version}/iojs-v${version}.tar.gz"; - sha256 = "15qh5pscg3588hyf4yfhma34gjkg87v5i4xzxj804g6m52m6y727"; - }; - - prePatch = '' - sed -e 's|^#!/usr/bin/env python$|#!${python}/bin/python|g' -i configure - ''; - - configureFlags = [ "--shared-openssl" "--shared-http-parser" "--shared-zlib" "--shared-libuv" ]; - - # iojs has --enable-static but no --disable-static. Automatically adding --disable-static - # causes configure to fail, so don't add --disable-static. - dontDisableStatic = true; - - buildInputs = [ python openssl http-parser zlib libuv ] ++ (optional stdenv.isLinux utillinux); - setupHook = ../nodejs/setup-hook.sh; - - passthru.interpreterName = "iojs"; - - meta = { - description = "A friendly fork of Node.js with an open governance model"; - homepage = https://iojs.org/; - license = licenses.mit; - platforms = platforms.linux; - maintainers = [ maintainers.havvy ]; - }; -} diff --git a/pkgs/development/web/nodejs/default-arch.patch b/pkgs/development/web/nodejs/default-arch.patch deleted file mode 100644 index 3c7eb1014de..00000000000 --- a/pkgs/development/web/nodejs/default-arch.patch +++ /dev/null @@ -1,24 +0,0 @@ -diff -Naur a/tools/gyp/pylib/gyp/xcode_emulation.py b/tools/gyp/pylib/gyp/xcode_emulation.py ---- a/tools/gyp/pylib/gyp/xcode_emulation.py 2014-01-23 06:05:51.000000000 +0100 -+++ b/tools/gyp/pylib/gyp/xcode_emulation.py 2014-02-04 17:49:48.000000000 +0100 -@@ -1018,12 +1033,16 @@ - # Since the value returned by this function is only used when ARCHS is not - # set, then on iOS we return "i386", as the default xcode project generator - # does not set ARCHS if it is not set in the .gyp file. -- if self.isIOS: -+ -+ try: -+ if self.isIOS: -+ return 'i386' -+ version, build = self._XcodeVersion() -+ if version >= '0500': -+ return 'x86_64' - return 'i386' -- version, build = self._XcodeVersion() -- if version >= '0500': -+ except: - return 'x86_64' -- return 'i386' - - class MacPrefixHeader(object): - """A class that helps with emulating Xcode's GCC_PREFIX_HEADER feature. diff --git a/pkgs/development/web/nodejs/default.nix b/pkgs/development/web/nodejs/default.nix index 0f7f56dd5b3..440ed7aca92 100644 --- a/pkgs/development/web/nodejs/default.nix +++ b/pkgs/development/web/nodejs/default.nix @@ -38,13 +38,12 @@ in stdenv.mkDerivation { dontDisableStatic = true; prePatch = '' patchShebangs . - sed -i 's/raise.*No Xcode or CLT version detected.*/version = "7.0.0"/' tools/gyp/pylib/gyp/xcode_emulation.py ''; - patches = stdenv.lib.optionals stdenv.isDarwin [ ./no-xcode.patch ./pkg-libpath.patch ]; + patches = stdenv.lib.optional stdenv.isDarwin ./no-xcode.patch; - buildInputs = [ python which zlib libuv openssl python ] - ++ optionals stdenv.isLinux [ utillinux http-parser ] + buildInputs = [ python which http-parser zlib libuv openssl python ] + ++ (optional stdenv.isLinux utillinux) ++ optionals stdenv.isDarwin [ pkgconfig openssl libtool ]; setupHook = ./setup-hook.sh; diff --git a/pkgs/development/web/nodejs/no-xcode.patch b/pkgs/development/web/nodejs/no-xcode.patch index 244a55e9aeb..e88168b68a7 100644 --- a/pkgs/development/web/nodejs/no-xcode.patch +++ b/pkgs/development/web/nodejs/no-xcode.patch @@ -70,3 +70,24 @@ diff -Naur a/tools/gyp/pylib/gyp/xcode_emulation.py b/tools/gyp/pylib/gyp/xcode_ def AdjustLibraries(self, libraries, config_name=None): """Transforms entries like 'Cocoa.framework' in libraries into entries like +@@ -1018,12 +1033,16 @@ + # Since the value returned by this function is only used when ARCHS is not + # set, then on iOS we return "i386", as the default xcode project generator + # does not set ARCHS if it is not set in the .gyp file. +- if self.isIOS: ++ ++ try: ++ if self.isIOS: ++ return 'i386' ++ version, build = self._XcodeVersion() ++ if version >= '0500': ++ return 'x86_64' + return 'i386' +- version, build = self._XcodeVersion() +- if version >= '0500': ++ except: + return 'x86_64' +- return 'i386' + + class MacPrefixHeader(object): + """A class that helps with emulating Xcode's GCC_PREFIX_HEADER feature. diff --git a/pkgs/development/web/nodejs/pkg-libpath.patch b/pkgs/development/web/nodejs/pkg-libpath.patch deleted file mode 100644 index 8ad94c0e3e2..00000000000 --- a/pkgs/development/web/nodejs/pkg-libpath.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/configure b/configure -index d199975..66d903b 100755 ---- a/configure -+++ b/configure -@@ -734,7 +734,7 @@ def configure_library(lib, output): - # libpath needs to be provided ahead libraries - if pkg_libpath: - output['libraries'] += ( -- filter(None, map(str.strip, pkg_cflags.split('-L')))) -+ pkg_libpath.split()) - - default_libs = getattr(options, shared_lib + '_libname') - default_libs = map('-l{0}'.format, default_libs.split(',')) diff --git a/pkgs/development/web/nodejs/v0_10.nix b/pkgs/development/web/nodejs/v0_10.nix index 47de2e72d40..bf19ba646fd 100644 --- a/pkgs/development/web/nodejs/v0_10.nix +++ b/pkgs/development/web/nodejs/v0_10.nix @@ -42,7 +42,7 @@ in stdenv.mkDerivation { patchShebangs . ''; - patches = stdenv.lib.optionals stdenv.isDarwin [ ./default-arch.patch ./no-xcode.patch ]; + patches = stdenv.lib.optional stdenv.isDarwin ./no-xcode.patch; postPatch = stdenv.lib.optionalString stdenv.isDarwin '' (cd tools/gyp; patch -Np1 -i ${../../python-modules/gyp/no-darwin-cflags.patch}) diff --git a/pkgs/misc/jackaudio/jack1.nix b/pkgs/misc/jackaudio/jack1.nix index 4250efcb6a2..1c5c78548f5 100644 --- a/pkgs/misc/jackaudio/jack1.nix +++ b/pkgs/misc/jackaudio/jack1.nix @@ -27,8 +27,7 @@ stdenv.mkDerivation rec { ''; nativeBuildInputs = [ pkgconfig ]; - buildInputs = [ optAlsaLib optDb optLibffado optCelt ]; - propagatedBuildInputs = [ optLibuuid ]; + buildInputs = [ optAlsaLib optDb optLibuuid optLibffado optCelt ]; meta = with stdenv.lib; { description = "JACK audio connection kit"; diff --git a/pkgs/misc/urbit/default.nix b/pkgs/misc/urbit/default.nix deleted file mode 100644 index e4049f07897..00000000000 --- a/pkgs/misc/urbit/default.nix +++ /dev/null @@ -1,42 +0,0 @@ -{ stdenv, fetchgit, gcc, gmp, libsigsegv, openssl, automake, autoconf, ragel, - cmake, re2c, libtool, ncurses, perl, zlib, python }: - -stdenv.mkDerivation rec { - - name = "urbit-${version}"; - version = "2015.09.26"; - - src = fetchgit { - url = "https://github.com/urbit/urbit.git"; - rev = "c9592664c797b2dd74f26886528656f8a7058640"; - sha256 = "0sgrxnmpqh54mgar81wlb6gff8c0pc24p53xwxr448g5shvnzjx9"; - }; - - buildInputs = with stdenv.lib; [ - gcc gmp libsigsegv openssl automake autoconf ragel cmake re2c libtool - ncurses perl zlib python - ]; - - configurePhase = '' - : - ''; - - buildPhase = '' - sed -i 's/-lcurses/-lncurses/' Makefile - mkdir -p $out - cp -r . $out/ - cd $out - make - ''; - - installPhase = '' - : - ''; - - meta = with stdenv.lib; { - description = "an operating function"; - homepage = http://urbit.org/preview/~2015.9.25/materials; - license = licenses.mit; - maintainers = with maintainers; [ mudri ]; - }; -} diff --git a/pkgs/os-specific/linux/kernel/linux-3.14.nix b/pkgs/os-specific/linux/kernel/linux-3.14.nix index 4a18072d753..5ea214c9eb3 100644 --- a/pkgs/os-specific/linux/kernel/linux-3.14.nix +++ b/pkgs/os-specific/linux/kernel/linux-3.14.nix @@ -1,13 +1,13 @@ { stdenv, fetchurl, perl, buildLinux, ... } @ args: import ./generic.nix (args // rec { - version = "3.14.54"; + version = "3.14.53"; # Remember to update grsecurity! extraMeta.branch = "3.14"; src = fetchurl { url = "mirror://kernel/linux/kernel/v3.x/linux-${version}.tar.xz"; - sha256 = "0jjl7xx2mkkhy3yg3mza2h7ysz48qcn0z475jldfw4fh87ajlfig"; + sha256 = "0zqaqa7gs895p521c82jggak9zlmiwmkfarh2ykvh423sxjbvs5i"; }; features.iwlwifi = true; diff --git a/pkgs/os-specific/linux/miraclecast/default.nix b/pkgs/os-specific/linux/miraclecast/default.nix deleted file mode 100644 index 3d5a76144af..00000000000 --- a/pkgs/os-specific/linux/miraclecast/default.nix +++ /dev/null @@ -1,26 +0,0 @@ -{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, udev, systemd, glib, readline }: - -with stdenv.lib; -stdenv.mkDerivation rec { - name = "miraclecast-0.0-git-20151002"; - - src = fetchFromGitHub { - owner = "albfan"; - repo = "miraclecast"; - rev = "30b8c2d22391423f76ba582aaaa1e0936869103a"; - sha256 = "0i076n76kq64fayc7v06gr1853pk5r6ms86m57vd1xsjd0r9wyxd"; - }; - - # INFO: It is important to list 'systemd' first as for now miraclecast - # links against a customized systemd. Otherwise, a systemd package from - # a propagatedBuildInput could take precedence. - buildInputs = [ systemd autoreconfHook pkgconfig udev glib readline ]; - - meta = { - homepage = https://github.com/albfan/miraclecast; - description = "Connect external monitors via Wi-Fi"; - license = licenses.lgpl21Plus; - maintainers = with maintainers; [ tstrobel ]; - platforms = platforms.linux; - }; -} diff --git a/pkgs/os-specific/linux/nvidiabl/default.nix b/pkgs/os-specific/linux/nvidiabl/default.nix index a6797608664..a5a43926e04 100644 --- a/pkgs/os-specific/linux/nvidiabl/default.nix +++ b/pkgs/os-specific/linux/nvidiabl/default.nix @@ -8,8 +8,6 @@ stdenv.mkDerivation { sha256 = "1c7ar39wc8jpqh67sw03lwnyp0m9l6dad469ybqrgcywdiwxspwj"; }; - patches = [ ./linux4compat.patch ]; - preConfigure = '' sed -i 's|/sbin/depmod|#/sbin/depmod|' Makefile ''; diff --git a/pkgs/os-specific/linux/nvidiabl/linux4compat.patch b/pkgs/os-specific/linux/nvidiabl/linux4compat.patch deleted file mode 100644 index ad8236a2b63..00000000000 --- a/pkgs/os-specific/linux/nvidiabl/linux4compat.patch +++ /dev/null @@ -1,22 +0,0 @@ -From 2bf6f08b2492cc04a2c39fdcb22a2d0c18963d1c Mon Sep 17 00:00:00 2001 -From: sonic414 -Date: Tue, 28 Apr 2015 19:30:15 +0530 -Subject: [PATCH] strnicmp to strncasecmp in Linux 4.0.0 - ---- - nvidiabl-module.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/nvidiabl-module.c b/nvidiabl-module.c -index b789ea4..b306579 100644 ---- a/nvidiabl-module.c -+++ b/nvidiabl-module.c -@@ -214,7 +214,7 @@ static int __init nvidiabl_init(void) - #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39) - - for (iii = 0 ; iii < sizeof(backlight_type_ids) ; iii++) { -- if (strnicmp(bl_type, backlight_type_ids[iii].id, sizeof(bl_type)) == 0) { -+ if (strncasecmp(bl_type, backlight_type_ids[iii].id, sizeof(bl_type)) == 0) { - props.type = backlight_type_ids[iii].type; - printk(KERN_INFO "nvidiabl: backlight type is %s\n", backlight_type_ids[iii].id); - } diff --git a/pkgs/os-specific/linux/syslinux/default.nix b/pkgs/os-specific/linux/syslinux/default.nix index 93e5d591a9d..3c01516b081 100644 --- a/pkgs/os-specific/linux/syslinux/default.nix +++ b/pkgs/os-specific/linux/syslinux/default.nix @@ -8,7 +8,8 @@ stdenv.mkDerivation rec { sha256 = "03l5iifwlg1wyb4yh98i0b7pd4j55a1c9y74q1frs47a5dnrilr6"; }; - patches = [ ./perl-deps.patch ]; + # gcc5-fix should be in 6.04+, so remove if it fails to apply. + patches = [ ./perl-deps.patch ./gcc5-fix.patch ]; buildInputs = [ nasm perl libuuid ]; diff --git a/pkgs/os-specific/linux/syslinux/gcc5-fix.patch b/pkgs/os-specific/linux/syslinux/gcc5-fix.patch new file mode 100644 index 00000000000..dc44b188058 --- /dev/null +++ b/pkgs/os-specific/linux/syslinux/gcc5-fix.patch @@ -0,0 +1,26 @@ +diff --git a/com32/include/menu.h b/com32/include/menu.h +index bc0182f..b0251e4 100644 +--- a/com32/include/menu.h ++++ b/com32/include/menu.h +@@ -195,7 +195,7 @@ void local_cursor_enable(bool); + + static inline int my_isspace(char c) + { +- return (unsigned char)c <= ' '; ++ return (unsigned char)c <= ' ' || (unsigned char)c == '\x7f'; + } + + int my_isxdigit(char c); +diff --git a/com32/menu/readconfig.c b/com32/menu/readconfig.c +index b7814be..a433fad 100644 +--- a/com32/menu/readconfig.c ++++ b/com32/menu/readconfig.c +@@ -299,7 +299,7 @@ static char *copy_sysappend_string(char *dst, const char *src) + char c; + + while ((c = *src++)) { +- if (c <= ' ' && c == '\x7f') { ++ if (my_isspace(c)) { + if (!was_space) + *dst++ = '_'; + was_space = true; diff --git a/pkgs/os-specific/linux/systemd/default.nix b/pkgs/os-specific/linux/systemd/default.nix index b7f70ec3b11..4c9e0475b94 100644 --- a/pkgs/os-specific/linux/systemd/default.nix +++ b/pkgs/os-specific/linux/systemd/default.nix @@ -3,7 +3,6 @@ , glib, kbd, libxslt, coreutils, libgcrypt , kexectools, libmicrohttpd, linuxHeaders , pythonPackages ? null, pythonSupport ? false -, enableKDbus ? false }: assert stdenv.isLinux; @@ -61,7 +60,7 @@ stdenv.mkDerivation rec { "--with-sysvinit-path=" "--with-sysvrcnd-path=" "--with-rc-local-script-path-stop=/etc/halt.local" - ] ++ stdenv.lib.optional enableKDbus "--enable-kdbus"; + ]; preConfigure = '' diff --git a/pkgs/servers/mail/opensmtpd/default.nix b/pkgs/servers/mail/opensmtpd/default.nix index 2fd3f0421b9..a95a5d81ce9 100644 --- a/pkgs/servers/mail/opensmtpd/default.nix +++ b/pkgs/servers/mail/opensmtpd/default.nix @@ -4,18 +4,16 @@ stdenv.mkDerivation rec { name = "opensmtpd-${version}"; - version = "5.7.1p1"; + version = "5.4.5p1"; nativeBuildInputs = [ autoconf automake libtool bison ]; buildInputs = [ libasr libevent zlib openssl db pam ]; src = fetchurl { url = "http://www.opensmtpd.org/archives/${name}.tar.gz"; - sha256 = "67e9dd9682ca8c181e84e66c76245a4a8f6205834f915a2c021cdfeb22049e3a"; + sha256 = "15sicrpqsgg72igdckkwpmbgrapcjbfjsdrvm0zl8z13kgp6r4ks"; }; - patches = [ ./proc_path.diff ]; - configureFlags = [ "--sysconfdir=/etc" "--localstatedir=/var" @@ -26,7 +24,6 @@ stdenv.mkDerivation rec { "--with-privsep-user=smtpd" "--with-queue-user=smtpq" "--with-ca-file=/etc/ssl/certs/ca-certificates.crt" - "--with-libevent-dir=${libevent}" ]; installFlags = [ diff --git a/pkgs/servers/mail/opensmtpd/extras.nix b/pkgs/servers/mail/opensmtpd/extras.nix deleted file mode 100644 index 0123d19bf3f..00000000000 --- a/pkgs/servers/mail/opensmtpd/extras.nix +++ /dev/null @@ -1,79 +0,0 @@ -{ stdenv, fetchurl, openssl, libevent, libasr, - python2, pkgconfig, lua5, perl, mariadb, postgresql, sqlite, hiredis }: -stdenv.mkDerivation rec { - name = "opensmtpd-extras-${version}"; - version = "5.7.1"; - - src = fetchurl { - url = "https://www.opensmtpd.org/archives/${name}.tar.gz"; - sha256 = "1kld4hxgz792s0cb2gl7m2n618ikzqkj88w5dhaxdrxg4x2c4vdm"; - }; - - nativeBuildInputs = [ pkgconfig ]; - buildInputs = [ openssl libevent - libasr python2 lua5 perl mariadb postgresql sqlite hiredis ]; - - configureFlags = [ - "--sysconfdir=/etc" - "--localstatedir=/var" - "--with-privsep-user=smtpd" - "--with-libevent-dir=${libevent}" - - "--with-filter-clamav" - "--with-filter-dkim-signer" - "--with-filter-dnsbl" - "--with-filter-monkey" - "--with-filter-pause" - "--with-filter-regex" - "--with-filter-spamassassin" - "--with-filter-stub" - "--with-filter-trace" - "--with-filter-void" - "--with-queue-null" - "--with-queue-ram" - "--with-queue-stub" - "--with-table-ldap" - "--with-table-socketmap" - "--with-table-passwd" - "--with-table-stub" - "--with-scheduler-ram" - "--with-scheduler-stub" - - ] ++ stdenv.lib.optional (python2 != null) [ - "--with-python=${python2}" - "--with-filter-python" - "--with-queue-python" - "--with-table-python" - "--with-scheduler-python" - - ] ++ stdenv.lib.optional (lua5 != null) [ - "--with-lua=${pkgconfig}" - "--with-filter-lua" - - ] ++ stdenv.lib.optional (perl != null) [ - "--with-perl=${perl}" - "--with-filter-perl" - - ] ++ stdenv.lib.optional (mariadb != null) [ - "--with-table-mysql" - - ] ++ stdenv.lib.optional (postgresql != null) [ - "--with-table-postgres" - - ] ++ stdenv.lib.optional (sqlite != null) [ - "--with-table-sqlite" - - ] ++ stdenv.lib.optional (hiredis != null) [ - "--with-table-redis" - ]; - - NIX_CFLAGS_COMPILE = stdenv.lib.optional (hiredis != null) [ "-I${hiredis}/include/hiredis" ]; - - meta = with stdenv.lib; { - homepage = https://www.opensmtpd.org/; - description = "Extra plugins for the OpenSMTPD mail server"; - license = licenses.isc; - platforms = platforms.unix; - maintainers = with maintainers; [ gebner ]; - }; -} diff --git a/pkgs/servers/mail/opensmtpd/proc_path.diff b/pkgs/servers/mail/opensmtpd/proc_path.diff deleted file mode 100644 index 0e8eac0bb83..00000000000 --- a/pkgs/servers/mail/opensmtpd/proc_path.diff +++ /dev/null @@ -1,76 +0,0 @@ -diff -Naur opensmtpd-5.7.1p1/smtpd/parse.y opensmtpd-5.7.1p1.patched/smtpd/parse.y ---- opensmtpd-5.7.1p1/smtpd/parse.y 2015-06-30 10:13:34.000000000 +0200 -+++ opensmtpd-5.7.1p1.patched/smtpd/parse.y 2015-09-26 08:41:17.012472516 +0200 -@@ -2519,13 +2519,19 @@ - { - struct filter_conf *f; - char *path; -+ const char *proc_path; - - if (dict_get(&conf->sc_filters, name)) { - yyerror("filter \"%s\" already defined", name); - return (NULL); - } - -- if (asprintf(&path, "%s/filter-%s", PATH_LIBEXEC, prog) == -1) { -+ proc_path = getenv("OPENSMTPD_PROC_PATH"); -+ if (proc_path == NULL) { -+ proc_path = PATH_LIBEXEC; -+ } -+ -+ if (asprintf(&path, "%s/filter-%s", proc_path, prog) == -1) { - yyerror("filter \"%s\" asprintf failed", name); - return (0); - } -diff -Naur opensmtpd-5.7.1p1/smtpd/smtpd.c opensmtpd-5.7.1p1.patched/smtpd/smtpd.c ---- opensmtpd-5.7.1p1/smtpd/smtpd.c 2015-06-30 10:13:34.000000000 +0200 -+++ opensmtpd-5.7.1p1.patched/smtpd/smtpd.c 2015-09-26 08:41:16.998472557 +0200 -@@ -854,6 +854,7 @@ - char path[PATH_MAX]; - char name[PATH_MAX]; - char *arg; -+ char *proc_path; - - if (strlcpy(name, conf, sizeof(name)) >= sizeof(name)) { - log_warnx("warn: %s-proc: conf too long", key); -@@ -864,7 +865,12 @@ - if (arg) - *arg++ = '\0'; - -- if (snprintf(path, sizeof(path), PATH_LIBEXEC "/%s-%s", key, name) >= -+ proc_path = getenv("OPENSMTPD_PROC_PATH"); -+ if (proc_path == NULL) { -+ proc_path = PATH_LIBEXEC; -+ } -+ -+ if (snprintf(path, sizeof(path), "%s/%s-%s", proc_path, key, name) >= - (ssize_t)sizeof(path)) { - log_warn("warn: %s-proc: exec path too long", key); - return (-1); -diff -Naur opensmtpd-5.7.1p1/smtpd/table.c opensmtpd-5.7.1p1.patched/smtpd/table.c ---- opensmtpd-5.7.1p1/smtpd/table.c 2015-06-30 10:13:34.000000000 +0200 -+++ opensmtpd-5.7.1p1.patched/smtpd/table.c 2015-09-26 08:41:17.005472536 +0200 -@@ -201,6 +201,7 @@ - struct table_backend *tb; - char buf[LINE_MAX]; - char path[LINE_MAX]; -+ const char *proc_path; - size_t n; - struct stat sb; - -@@ -215,8 +216,14 @@ - if (name && table_find(name, NULL)) - fatalx("table_create: table \"%s\" already defined", name); - -+ proc_path = getenv("OPENSMTPD_PROC_PATH"); -+ if (proc_path == NULL) { -+ proc_path = PATH_LIBEXEC; -+ } -+ - if ((tb = table_backend_lookup(backend)) == NULL) { -- if ((size_t)snprintf(path, sizeof(path), PATH_LIBEXEC "/table-%s", -+ if ((size_t)snprintf(path, sizeof(path), "%s/table-%s", -+ proc_path, - backend) >= sizeof(path)) { - fatalx("table_create: path too long \"" - PATH_LIBEXEC "/table-%s\"", backend); diff --git a/pkgs/stdenv/linux/default.nix b/pkgs/stdenv/linux/default.nix index 2436181aa7a..12fc3fed5a5 100644 --- a/pkgs/stdenv/linux/default.nix +++ b/pkgs/stdenv/linux/default.nix @@ -210,9 +210,14 @@ rec { gmp = pkgs.gmp.override { stdenv = pkgs.makeStaticLibraries pkgs.stdenv; }; mpfr = pkgs.mpfr.override { stdenv = pkgs.makeStaticLibraries pkgs.stdenv; }; libmpc = pkgs.libmpc.override { stdenv = pkgs.makeStaticLibraries pkgs.stdenv; }; - isl_0_14 = pkgs.isl_0_14.override { stdenv = pkgs.makeStaticLibraries pkgs.stdenv; }; + isl_0_11 = pkgs.isl_0_11.override { stdenv = pkgs.makeStaticLibraries pkgs.stdenv; }; + cloog_0_18_0 = pkgs.cloog_0_18_0.override { + stdenv = pkgs.makeStaticLibraries pkgs.stdenv; + isl = isl_0_11; + }; gccPlain = pkgs.gcc.cc.override { - isl = isl_0_14; + isl = isl_0_11; + cloog = cloog_0_18_0; }; }; extraBuildInputs = [ stage2.pkgs.patchelf stage2.pkgs.paxctl ]; diff --git a/pkgs/tools/filesystems/duff/default.nix b/pkgs/tools/filesystems/duff/default.nix index 1c4d068c4c1..31015334166 100644 --- a/pkgs/tools/filesystems/duff/default.nix +++ b/pkgs/tools/filesystems/duff/default.nix @@ -1,14 +1,12 @@ { stdenv, fetchFromGitHub, autoreconfHook, gettext }: -# The last release (0.5.2) is more than 2 years old and lacks features like -D, -# limiting its usefulness. Upstream appears comatose if not dead. -let version = "2014-07-03"; in +let version = "0.5.2"; in stdenv.mkDerivation { name = "duff-${version}"; src = fetchFromGitHub { - sha256 = "1k2dx38pjzc5d624vw1cs5ipj9fprsm5vqv55agksc29m63lswnx"; - rev = "f26d4837768b062a3f98fa075c791d9c8a0bb75c"; + sha256 = "0yfm910wjj6z0f0cg68x59ykf4ql5m49apzy8sra00f8kv4lpn53"; + rev = version; repo = "duff"; owner = "elmindreda"; }; @@ -16,6 +14,10 @@ stdenv.mkDerivation { nativeBuildInputs = [ autoreconfHook gettext ]; preAutoreconf = '' + # duff is currently badly packaged, requiring us to do extra work here that + # should be done upstream. If that is ever fixed, this entire phase can be + # removed along with all buildInputs. + # gettexttize rightly refuses to run non-interactively: cp ${gettext}/bin/gettextize . substituteInPlace gettextize \ @@ -28,15 +30,14 @@ stdenv.mkDerivation { enableParallelBuilding = true; meta = with stdenv.lib; { - inherit version; description = "Quickly find duplicate files"; + homepage = http://duff.dreda.org/; + license = licenses.zlib; longDescription = '' Duff is a Unix command-line utility for quickly finding duplicates in a given set of files. ''; - homepage = http://duff.dreda.org/; - license = licenses.zlib; - platforms = platforms.all; maintainers = with maintainers; [ nckx ]; + platforms = with platforms; all; }; } diff --git a/pkgs/tools/graphics/enblend-enfuse/default.nix b/pkgs/tools/graphics/enblend-enfuse/default.nix index c967b73001c..6b65d3df0d3 100644 --- a/pkgs/tools/graphics/enblend-enfuse/default.nix +++ b/pkgs/tools/graphics/enblend-enfuse/default.nix @@ -1,24 +1,22 @@ { stdenv, fetchurl , boost, freeglut, glew, gsl, lcms2, libpng, libtiff, libxmi, mesa, vigra -, help2man, pkgconfig, perl }: +, pkgconfig, perl }: -let version = "4.1.4"; in stdenv.mkDerivation rec { - name = "enblend-enfuse-${version}"; + name = "enblend-enfuse-4.1.3"; src = fetchurl { url = "mirror://sourceforge/enblend/${name}.tar.gz"; - sha256 = "0208x01i129hqylmy6jh3krwdac47mx6fi8xccjm9h35c18c7xl5"; + sha256 = "1b7r1nnwaind0344ckwggy0ghl0ipbk9jzylsxcjfl05rnasw00w"; }; buildInputs = [ boost freeglut glew gsl lcms2 libpng libtiff libxmi mesa vigra ]; - nativeBuildInputs = [ help2man perl pkgconfig ]; + nativeBuildInputs = [ perl pkgconfig ]; enableParallelBuilding = true; meta = { - inherit version; homepage = http://enblend.sourceforge.net/; description = "Blends away the seams in a panoramic image mosaic using a multiresolution spline"; license = stdenv.lib.licenses.gpl2; diff --git a/pkgs/tools/misc/heatseeker/default.nix b/pkgs/tools/misc/heatseeker/default.nix deleted file mode 100644 index 0d85554c347..00000000000 --- a/pkgs/tools/misc/heatseeker/default.nix +++ /dev/null @@ -1,28 +0,0 @@ -{ stdenv, fetchFromGitHub, rustPlatform }: - -with rustPlatform; - -buildRustPackage rec { - name = "heatseeker-${version}"; - version = "1.3.0"; - - depsSha256 = "03jap7myf85xgx9270sws8x57nl04a1wx8szrk9qx24s9vnnjcnh"; - - src = fetchFromGitHub { - owner = "rschmitt"; - repo = "heatseeker"; - rev = "v${version}"; - sha256 = "1xdvwgmh9lwv82hv1qg82bjv2iplnvva6lzbg7dyhbszhv7rhkbl"; - }; - - # some tests require a tty, this variable turns them off for Travis CI, - # which we can also make use of - TRAVIS= "true"; - - meta = with stdenv.lib; { - description = "A general-purpose fuzzy selector"; - homepage = https://github.com/rschmitt/heatseeker; - license = stdenv.lib.licenses.mit; - maintainers = [ maintainers.michaelpj ]; - }; -} diff --git a/pkgs/tools/networking/openssh/default.nix b/pkgs/tools/networking/openssh/default.nix index 50d53bdff2c..2004e453a0d 100644 --- a/pkgs/tools/networking/openssh/default.nix +++ b/pkgs/tools/networking/openssh/default.nix @@ -17,11 +17,11 @@ let in with stdenv.lib; stdenv.mkDerivation rec { - name = "openssh-7.1p1"; + name = "openssh-6.9p1"; src = fetchurl { url = "mirror://openbsd/OpenSSH/portable/${name}.tar.gz"; - sha256 = "0a44mnr8bvw41zg83xh4sb55d8nds29j95gxvxk5qg863lnns2pw"; + sha256 = "1zkci5nbpb4frmzj2vr3kv9j47x2h72kvybcpr0d8mzk73sls1vf"; }; prePatch = optionalString hpnSupport @@ -30,7 +30,7 @@ stdenv.mkDerivation rec { export NIX_LDFLAGS="$NIX_LDFLAGS -lgcc_s" ''; - patches = [ ./locale_archive.patch ]; + patches = [ ./locale_archive.patch ./openssh-6.9p1-security-7.0.patch]; buildInputs = [ zlib openssl libedit pkgconfig pam ] ++ optional withKerberos [ kerberos ]; diff --git a/pkgs/tools/networking/openssh/openssh-6.9p1-security-7.0.patch b/pkgs/tools/networking/openssh/openssh-6.9p1-security-7.0.patch new file mode 100644 index 00000000000..02e9eb3a973 --- /dev/null +++ b/pkgs/tools/networking/openssh/openssh-6.9p1-security-7.0.patch @@ -0,0 +1,65 @@ +http://pkgs.fedoraproject.org/cgit/openssh.git/commit/openssh-6.9p1-security-7.0.patch?h=f22&id=4776fad91e7e1f626f33e8c240d0ccecd663554d + +diff --git a/sshpty.c b/sshpty.c +index 7bb7641..15da8c6 100644 +--- a/sshpty.c ++++ b/sshpty.c +@@ -1,4 +1,4 @@ +-/* $OpenBSD: sshpty.c,v 1.29 2014/09/03 18:55:07 djm Exp $ */ ++/* $OpenBSD: sshpty.c,v 1.30 2015/07/30 23:09:15 djm Exp $ */ + /* + * Author: Tatu Ylonen + * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland +@@ -197,7 +197,7 @@ pty_setowner(struct passwd *pw, const char *tty) + /* Determine the group to make the owner of the tty. */ + grp = getgrnam("tty"); + gid = (grp != NULL) ? grp->gr_gid : pw->pw_gid; +- mode = (grp != NULL) ? 0622 : 0600; ++ mode = (grp != NULL) ? 0620 : 0600; + + /* + * Change owner and mode of the tty as required. +diff --git a/monitor.c b/monitor.c +index b410965..f1b873d 100644 +--- a/monitor.c ++++ b/monitor.c +@@ -1084,9 +1084,7 @@ extern KbdintDevice sshpam_device; + int + mm_answer_pam_init_ctx(int sock, Buffer *m) + { +- + debug3("%s", __func__); +- authctxt->user = buffer_get_string(m, NULL); + sshpam_ctxt = (sshpam_device.init_ctx)(authctxt); + sshpam_authok = NULL; + buffer_clear(m); +@@ -1166,14 +1166,16 @@ mm_answer_pam_respond(int sock, Buffer *m) + int + mm_answer_pam_free_ctx(int sock, Buffer *m) + { ++ int r = sshpam_authok != NULL && sshpam_authok == sshpam_ctxt; + + debug3("%s", __func__); + (sshpam_device.free_ctx)(sshpam_ctxt); ++ sshpam_ctxt = sshpam_authok = NULL; + buffer_clear(m); + mm_request_send(sock, MONITOR_ANS_PAM_FREE_CTX, m); + auth_method = "keyboard-interactive"; + auth_submethod = "pam"; +- return (sshpam_authok == sshpam_ctxt); ++ return r; + } + #endif + +diff --git a/monitor_wrap.c b/monitor_wrap.c +index e6217b3..eac421b 100644 +--- a/monitor_wrap.c ++++ b/monitor_wrap.c +@@ -614,7 +614,6 @@ mm_sshpam_init_ctx(Authctxt *authctxt) + + debug3("%s", __func__); + buffer_init(&m); +- buffer_put_cstring(&m, authctxt->user); + mm_request_send(pmonitor->m_recvfd, MONITOR_REQ_PAM_INIT_CTX, &m); + debug3("%s: waiting for MONITOR_ANS_PAM_INIT_CTX", __func__); + mm_request_receive_expect(pmonitor->m_recvfd, MONITOR_ANS_PAM_INIT_CTX, &m); diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 2623ffa6ac5..c7008bd86c0 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -853,8 +853,6 @@ let gmic = callPackage ../tools/graphics/gmic { }; - heatseeker = callPackage ../tools/misc/heatseeker { }; - mathics = pythonPackages.mathics; mcrl = callPackage ../tools/misc/mcrl { }; @@ -1370,7 +1368,7 @@ let emv = callPackage ../tools/misc/emv { }; - enblend-enfuse = callPackage ../tools/graphics/enblend-enfuse { }; + enblendenfuse = callPackage ../tools/graphics/enblend-enfuse { }; encfs = callPackage ../tools/filesystems/encfs { }; @@ -3734,7 +3732,7 @@ let gambit = callPackage ../development/compilers/gambit { }; - gcc = gcc5; + gcc = gcc49; gcc_multi = if system == "x86_64-linux" then lowPrio ( @@ -4986,7 +4984,8 @@ let fetchurl = fetchurlBoot; }; - perl = perl522; + # Make perl522 the default once gnulib is updated to support it. + perl = perl520; php = php56; @@ -5842,7 +5841,7 @@ let aalib = callPackage ../development/libraries/aalib { }; - accelio = callPackage ../development/libraries/accelio { }; + accelio = callPackage ../development/libraries/accelio { stdenv = overrideCC stdenv gcc5; }; accountsservice = callPackage ../development/libraries/accountsservice { }; @@ -6350,8 +6349,7 @@ let gmp4 = callPackage ../development/libraries/gmp/4.3.2.nix { }; # required by older GHC versions gmp5 = callPackage ../development/libraries/gmp/5.1.x.nix { }; - gmp6 = callPackage ../development/libraries/gmp/6.x.nix { }; - gmp = gmp6; + gmp = gmp5; gmpxx = appendToName "with-cxx" (gmp.override { cxx = true; }); #GMP ex-satellite, so better keep it near gmp @@ -7405,9 +7403,11 @@ let libusbmuxd = callPackage ../development/libraries/libusbmuxd { }; libunwind = if stdenv.isDarwin - then darwin.libunwind + then libunwindNative else callPackage ../development/libraries/libunwind { }; + libunwindNative = callPackage ../development/libraries/libunwind/native.nix {}; + libuvVersions = recurseIntoAttrs (callPackage ../development/libraries/libuv { automake = automake113x; # fails with 14 inherit (darwin.apple_sdk.frameworks) ApplicationServices CoreServices; @@ -7781,6 +7781,14 @@ let }; }; + openssl_1_0_2 = callPackage ../development/libraries/openssl/1.0.2.x.nix { + fetchurl = fetchurlBoot; + cryptodevHeaders = linuxPackages.cryptodev.override { + fetchurl = fetchurlBoot; + onlyHeaders = true; + }; + }; + openwsman = callPackage ../development/libraries/openwsman {}; ortp = callPackage ../development/libraries/ortp { }; @@ -9068,7 +9076,6 @@ let openresty = callPackage ../servers/http/openresty { }; opensmtpd = callPackage ../servers/mail/opensmtpd { }; - opensmtpd-extras = callPackage ../servers/mail/opensmtpd/extras.nix { }; openxpki = callPackage ../servers/openxpki { }; @@ -10014,10 +10021,6 @@ let mingetty = callPackage ../os-specific/linux/mingetty { }; - miraclecast = callPackage ../os-specific/linux/miraclecast { - systemd = systemd.override { enableKDbus = true; }; - }; - module_init_tools = callPackage ../os-specific/linux/module-init-tools { }; aggregateModules = modules: @@ -10173,13 +10176,7 @@ let sysklogd = callPackage ../os-specific/linux/sysklogd { }; - syslinux = callPackage ../os-specific/linux/syslinux { - # Using GCC5 with 6.03 creates a broken isolinux.bin - # Make sure to test booting the livecd on a bios system - # if changing this override. - # nixos.tests.bootBiosCdrom is useful for this. - stdenv = overrideCC stdenv gcc48; - }; + syslinux = callPackage ../os-specific/linux/syslinux { }; sysstat = callPackage ../os-specific/linux/sysstat { }; @@ -11793,8 +11790,6 @@ let iptraf = callPackage ../applications/networking/iptraf { }; - iptraf-ng = callPackage ../applications/networking/iptraf-ng { }; - irssi = callPackage ../applications/networking/irc/irssi { }; irssi_fish = callPackage ../applications/networking/irc/irssi/fish { }; @@ -11815,9 +11810,6 @@ let jackmeter = callPackage ../applications/audio/jackmeter { }; - jackmix = callPackage ../applications/audio/jackmix { }; - jackmix_jack1 = jackmix.override { jack = jack1; }; - jalv = callPackage ../applications/audio/jalv { }; jedit = callPackage ../applications/editors/jedit { }; @@ -13946,7 +13938,6 @@ let libcanberra = libcanberra_kde; boost = boost155; kdelibs = kdeApps_15_08.kdelibs; - subversionClient = subversionClient.override { branch = "1.8"; }; } ../desktops/kde-4.14; @@ -14974,8 +14965,6 @@ let tvheadend = callPackage ../servers/tvheadend { }; - urbit = callPackage ../misc/urbit { }; - utf8proc = callPackage ../development/libraries/utf8proc { }; vault = goPackages.vault.bin // { outputs = [ "bin" ]; }; @@ -15135,7 +15124,6 @@ aliases = with self; rec { clangAnalyzer = clang-analyzer; # added 2015-02-20 cool-old-term = cool-retro-term; # added 2015-01-31 cv = progress; # added 2015-09-06 - enblendenfuse = enblend-enfuse; # 2015-09-30 exfat-utils = exfat; # 2015-09-11 firefoxWrapper = firefox-wrapper; fuse_exfat = exfat; # 2015-09-11 diff --git a/pkgs/top-level/go-packages.nix b/pkgs/top-level/go-packages.nix index ec9ac07fe9a..2bf0a96a5aa 100644 --- a/pkgs/top-level/go-packages.nix +++ b/pkgs/top-level/go-packages.nix @@ -679,26 +679,6 @@ let subPackages = [ "./" ]; # don't try to build test fixtures }; - git-lfs = buildFromGitHub { - rev = "v1.0.0"; - owner = "github"; - repo = "git-lfs"; - sha256 = "1zlg3rm5yxak6d88brffv1wpj0iq4qgzn6sgg8xn0pbnzxjd1284"; - - # Tests fail with 'lfstest-gitserver.go:46: main redeclared in this block' - excludedPackages = [ "test" ]; - - preBuild = '' - pushd go/src/github.com/github/git-lfs - go generate ./commands - popd - ''; - - postInstall = '' - rm -v $bin/bin/{man,script} - ''; - }; - glide = buildFromGitHub { rev = "0.5.0"; owner = "Masterminds"; diff --git a/pkgs/top-level/perl-packages.nix b/pkgs/top-level/perl-packages.nix index 1057be798df..ead04c0f088 100644 --- a/pkgs/top-level/perl-packages.nix +++ b/pkgs/top-level/perl-packages.nix @@ -715,15 +715,15 @@ let self = _self // overrides; _self = with self; { }; Cairo = buildPerlPackage rec { - name = "Cairo-1.106"; + name = "Cairo-1.105"; src = fetchurl { url = "mirror://cpan/authors/id/X/XA/XAOC/${name}.tar.gz"; - sha256 = "1i25kks408c54k2zxskvg54l5k3qadzm8n72ffga9jy7ic0h6j76"; + sha256 = "0im025wy1346w7b7hi6im08bfn6x4ma0cxmjz6xnk8riizm1s84q"; }; buildInputs = [ ExtUtilsDepends ExtUtilsPkgConfig pkgs.cairo ]; meta = { homepage = http://gtk2-perl.sourceforge.net/; - description = "Perl interface to the cairo 2D vector graphics library"; + description = "Perl interface to the cairo 2d vector graphics library"; maintainers = with maintainers; [ nckx ]; license = stdenv.lib.licenses.lgpl21Plus; }; @@ -4843,10 +4843,10 @@ let self = _self // overrides; _self = with self; { }; Glib = buildPerlPackage rec { - name = "Glib-1.314"; + name = "Glib-1.313"; src = fetchurl { url = "mirror://cpan/authors/id/X/XA/XAOC/${name}.tar.gz"; - sha256 = "13lhyksm7fgj6rgrgs06kr0hinbyhiq3lfr6gd2qal1j2w0rwzml"; + sha256 = "162g342bhzy2ca4xwk63j10q9jycsps0s8l8y8pda70m7zcmr7xj"; }; buildInputs = [ ExtUtilsDepends ExtUtilsPkgConfig pkgs.glib ]; meta = { -- cgit 1.4.1 From 1283e3da5d0bc4657677d40fa3cb117b66489ee5 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Wed, 7 Oct 2015 15:11:39 +0300 Subject: glibc_multi: fix ldd for 64-bit ELFs --- pkgs/development/libraries/glibc/multi.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/glibc/multi.nix b/pkgs/development/libraries/glibc/multi.nix index e0a9fa46b96..b5b4eabe9c7 100644 --- a/pkgs/development/libraries/glibc/multi.nix +++ b/pkgs/development/libraries/glibc/multi.nix @@ -23,7 +23,7 @@ runCommand "${nameVersion.name}-multi-${nameVersion.version}" cp -rs $glibc64/bin $out chmod u+w $out/bin rm $out/bin/ldd - sed -e "s|^RTLDLIST=.*$|RTLDLIST=\"$out/lib/ld-2.19.so $out/lib/32/ld-linux.so.2\"|g" \ + sed -e "s|^RTLDLIST=.*$|RTLDLIST=\"$out/lib/ld-linux-x86-64.so.2 $out/lib/32/ld-linux.so.2\"|g" \ $glibc64/bin/ldd > $out/bin/ldd chmod 555 $out/bin/ldd -- cgit 1.4.1 From f4fb1d77538a4d4d75046b9ae7a98b97c6220bc8 Mon Sep 17 00:00:00 2001 From: Vladimír ÄŒunát Date: Thu, 15 Oct 2015 20:52:30 +0200 Subject: mesa: maintenance update 11.0.2 -> 11.0.3 --- pkgs/development/libraries/mesa/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/mesa/default.nix b/pkgs/development/libraries/mesa/default.nix index 52268b9c343..0e2d1af3a31 100644 --- a/pkgs/development/libraries/mesa/default.nix +++ b/pkgs/development/libraries/mesa/default.nix @@ -22,7 +22,7 @@ else */ let - version = "11.0.2"; + version = "11.0.3"; # this is the default search path for DRI drivers driverLink = "/run/opengl-driver" + stdenv.lib.optionalString stdenv.isi686 "-32"; in @@ -36,7 +36,7 @@ stdenv.mkDerivation { "https://launchpad.net/mesa/trunk/${version}/+download/mesa-${version}.tar.xz" "ftp://ftp.freedesktop.org/pub/mesa/${version}/mesa-${version}.tar.xz" ]; - sha256 = "fce11fb27eb87adf1e620a76455d635c6136dfa49ae58c53b34ef8d0c7b7eae4"; + sha256 = "ab2992eece21adc23c398720ef8c6933cb69ea42e1b2611dc09d031e17e033d6"; }; prePatch = "patchShebangs ."; -- cgit 1.4.1 From fb1e994c0c48054ad1b78149ed07d33c4254f6eb Mon Sep 17 00:00:00 2001 From: Andrew Kelley Date: Wed, 14 Oct 2015 22:39:30 -0700 Subject: ffmpeg: 2.7.2 -> 2.8.1 (close #10396) @vcunat removed 2.7 and 2.6. The global version of 2.6 was unused, and 2.7 -> 2.8 switch should be without problems by inspecting http://abi-laboratory.pro/tracker/timeline/ffmpeg/ (only ABI changes and symbol additions) --- pkgs/development/libraries/ffmpeg-full/default.nix | 4 ++-- pkgs/development/libraries/ffmpeg/2.6.nix | 7 ------- pkgs/development/libraries/ffmpeg/2.7.nix | 7 ------- pkgs/development/libraries/ffmpeg/2.8.nix | 7 +++++++ pkgs/top-level/all-packages.nix | 5 ++--- 5 files changed, 11 insertions(+), 19 deletions(-) delete mode 100644 pkgs/development/libraries/ffmpeg/2.6.nix delete mode 100644 pkgs/development/libraries/ffmpeg/2.7.nix create mode 100644 pkgs/development/libraries/ffmpeg/2.8.nix (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/ffmpeg-full/default.nix b/pkgs/development/libraries/ffmpeg-full/default.nix index 654741283f9..cecf4714b53 100644 --- a/pkgs/development/libraries/ffmpeg-full/default.nix +++ b/pkgs/development/libraries/ffmpeg-full/default.nix @@ -231,11 +231,11 @@ assert x11grabExtlib -> libX11 != null && libXv != null; stdenv.mkDerivation rec { name = "ffmpeg-full-${version}"; - version = "2.7.2"; + version = "2.8.1"; src = fetchurl { url = "https://www.ffmpeg.org/releases/ffmpeg-${version}.tar.bz2"; - sha256 = "1wlygd0jp34dk4qagi4h9psn4yk8zgyj7zy9lrpm5332mm87bsvw"; + sha256 = "1qk6g2h993i0wgs9d2p3ahdc5bqr03mp74bk6r1zj6pfinr5mvg2"; }; patchPhase = ''patchShebangs .''; diff --git a/pkgs/development/libraries/ffmpeg/2.6.nix b/pkgs/development/libraries/ffmpeg/2.6.nix deleted file mode 100644 index 60fc32e030e..00000000000 --- a/pkgs/development/libraries/ffmpeg/2.6.nix +++ /dev/null @@ -1,7 +0,0 @@ -{ callPackage, ... } @ args: - -callPackage ./generic.nix (args // rec { - version = "${branch}.3"; - branch = "2.6"; - sha256 = "1yqc3vm1xrwf866q262qd4nr9d6ifp4gg183pjdc4sl9np0rissr"; -}) diff --git a/pkgs/development/libraries/ffmpeg/2.7.nix b/pkgs/development/libraries/ffmpeg/2.7.nix deleted file mode 100644 index 105239c48c9..00000000000 --- a/pkgs/development/libraries/ffmpeg/2.7.nix +++ /dev/null @@ -1,7 +0,0 @@ -{ callPackage, ... } @ args: - -callPackage ./generic.nix (args // rec { - version = "${branch}.2"; - branch = "2.7"; - sha256 = "1wlygd0jp34dk4qagi4h9psn4yk8zgyj7zy9lrpm5332mm87bsvw"; -}) diff --git a/pkgs/development/libraries/ffmpeg/2.8.nix b/pkgs/development/libraries/ffmpeg/2.8.nix new file mode 100644 index 00000000000..e585ea14997 --- /dev/null +++ b/pkgs/development/libraries/ffmpeg/2.8.nix @@ -0,0 +1,7 @@ +{ callPackage, ... } @ args: + +callPackage ./generic.nix (args // rec { + version = "${branch}.1"; + branch = "2.8"; + sha256 = "1qk6g2h993i0wgs9d2p3ahdc5bqr03mp74bk6r1zj6pfinr5mvg2"; +}) diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 49a8259e764..9f4dd230163 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6158,12 +6158,11 @@ let ffmpeg_0_10 = callPackage ../development/libraries/ffmpeg/0.10.nix { }; ffmpeg_1_2 = callPackage ../development/libraries/ffmpeg/1.2.nix { }; ffmpeg_2_2 = callPackage ../development/libraries/ffmpeg/2.2.nix { }; - ffmpeg_2_6 = callPackage ../development/libraries/ffmpeg/2.6.nix { }; - ffmpeg_2_7 = callPackage ../development/libraries/ffmpeg/2.7.nix { }; + ffmpeg_2_8 = callPackage ../development/libraries/ffmpeg/2.8.nix { }; # Aliases ffmpeg_0 = ffmpeg_0_10; ffmpeg_1 = ffmpeg_1_2; - ffmpeg_2 = ffmpeg_2_7; + ffmpeg_2 = ffmpeg_2_8; ffmpeg = ffmpeg_2; ffmpeg-full = callPackage ../development/libraries/ffmpeg-full { -- cgit 1.4.1 From 9b9d790c6cecb48228fa8321ee85156904ddb914 Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Fri, 16 Oct 2015 16:45:26 -0700 Subject: jemalloc: 4.0.2 -> 4.0.3 --- pkgs/development/libraries/jemalloc/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/jemalloc/default.nix b/pkgs/development/libraries/jemalloc/default.nix index 4e13c9b1d93..746ebd2bfcd 100644 --- a/pkgs/development/libraries/jemalloc/default.nix +++ b/pkgs/development/libraries/jemalloc/default.nix @@ -1,11 +1,11 @@ { stdenv, fetchurl }: stdenv.mkDerivation rec { - name = "jemalloc-4.0.2"; + name = "jemalloc-4.0.3"; src = fetchurl { url = "http://www.canonware.com/download/jemalloc/${name}.tar.bz2"; - sha256 = "04a6iw9wiwiknd7v3l3i7vpmc5nvv52islnb1hz9idmdk259r2hd"; + sha256 = "1mpnfaniaybv8kh7yjqq2g595l2i08m7adg238k5igzf61n6ixzi"; }; meta = with stdenv.lib; { -- cgit 1.4.1 From 4318aede92abdf041418753cdbbcfc178da88b86 Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Sat, 17 Oct 2015 11:54:03 -0700 Subject: nghttp2: 1.2.1 -> 1.3.4 --- pkgs/development/libraries/nghttp2/default.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/nghttp2/default.nix b/pkgs/development/libraries/nghttp2/default.nix index c4257fe97d2..5cd5f0cb629 100644 --- a/pkgs/development/libraries/nghttp2/default.nix +++ b/pkgs/development/libraries/nghttp2/default.nix @@ -34,12 +34,12 @@ let in stdenv.mkDerivation rec { name = "${prefix}nghttp2-${version}"; - version = "1.2.1"; + version = "1.3.4"; # Don't use fetchFromGitHub since this needs a bootstrap curl src = fetchurl { url = "http://pub.wak.io/nixos/tarballs/nghttp2-${version}.tar.bz2"; - sha256 = "8027461a231d205394890b2fee34d1c3751e28e7d3f7c1ebc1b557993ea4045e"; + sha256 = "63c1d70e50f0c8514e261be88b66720df095269791aa008d76c09e0c3a4c085f"; }; # Configure script searches for a symbol which does not exist in jemalloc on Darwin @@ -66,6 +66,7 @@ stdenv.mkDerivation rec { (mkWith (optJemalloc != null) "jemalloc" null) (mkWith false "spdylay" null) (mkWith false "cython" null) + (mkWith false "mruby" null) ]; meta = with stdenv.lib; { -- cgit 1.4.1 From e8961181ea470b90de11ff5bc89affe03f543146 Mon Sep 17 00:00:00 2001 From: Vladimír ÄŒunát Date: Sun, 18 Oct 2015 09:07:20 +0200 Subject: gdk-pixbuf: security update 2.32.0 -> 2.32.1 CVE-2015-7674, fixes #10441. --- pkgs/development/libraries/gdk-pixbuf/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/gdk-pixbuf/default.nix b/pkgs/development/libraries/gdk-pixbuf/default.nix index 0971df78e66..daa67490533 100644 --- a/pkgs/development/libraries/gdk-pixbuf/default.nix +++ b/pkgs/development/libraries/gdk-pixbuf/default.nix @@ -3,14 +3,14 @@ let ver_maj = "2.32"; - ver_min = "0"; + ver_min = "1"; in stdenv.mkDerivation rec { name = "gdk-pixbuf-${ver_maj}.${ver_min}"; src = fetchurl { url = "mirror://gnome/sources/gdk-pixbuf/${ver_maj}/${name}.tar.xz"; - sha256 = "0rqvj5gcs2zfyyg9llm289b0xkj4mrhzxfjpjja0wx1m6vn5axjk"; + sha256 = "1g7kjxv67jcdasi14n7jan4icrnnppd1m99wrdmpv32k4m7vfcj4"; }; setupHook = ./setup-hook.sh; -- cgit 1.4.1 From 1335293aa72b44d4c95c8d313f7448445ba67b1a Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Sun, 18 Oct 2015 17:21:54 -0700 Subject: harfbuzz: 1.0.3 -> 1.0.6 --- pkgs/development/libraries/harfbuzz/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/harfbuzz/default.nix b/pkgs/development/libraries/harfbuzz/default.nix index d2f8416b3ea..26c5d2fa825 100644 --- a/pkgs/development/libraries/harfbuzz/default.nix +++ b/pkgs/development/libraries/harfbuzz/default.nix @@ -8,11 +8,11 @@ # (icu is a ~30 MB dependency, the rest is very small in comparison) stdenv.mkDerivation rec { - name = "harfbuzz-1.0.3"; + name = "harfbuzz-1.0.6"; src = fetchurl { url = "http://www.freedesktop.org/software/harfbuzz/release/${name}.tar.bz2"; - sha256 = "1xrxlrvgyr6mm9qjxmkif2kvcah082y94gf1vqi0f0bdl1g8gp7b"; + sha256 = "09ivk5m4y09ar4zi9r6db7gp234cy05h0ach7w22g9kqvkxsf5pn"; }; outputs = [ "out" "doc" ]; -- cgit 1.4.1 From cf787f028246fbf7c66c4d5482b9966d3f5745ff Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Sun, 18 Oct 2015 17:22:35 -0700 Subject: sqlite: 3.8.11.1 -> 3.9.1 --- pkgs/development/libraries/sqlite/default.nix | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/sqlite/default.nix b/pkgs/development/libraries/sqlite/default.nix index f043a37033a..c337de867e0 100644 --- a/pkgs/development/libraries/sqlite/default.nix +++ b/pkgs/development/libraries/sqlite/default.nix @@ -3,11 +3,11 @@ assert interactive -> readline != null && ncurses != null; stdenv.mkDerivation { - name = "sqlite-3.8.11.1"; + name = "sqlite-3.9.1"; src = fetchurl { - url = "http://sqlite.org/2015/sqlite-autoconf-3081101.tar.gz"; - sha1 = "d0e22d7e361b6f50830a3cdeafe35311443f8f9a"; + url = "http://sqlite.org/2015/sqlite-autoconf-3090100.tar.gz"; + sha1 = "6b7d22c24c9695118a2706c8e026fb3c31780a30"; }; buildInputs = lib.optionals interactive [ readline ncurses ]; @@ -17,6 +17,7 @@ stdenv.mkDerivation { NIX_CFLAGS_COMPILE = [ "-DSQLITE_ENABLE_COLUMN_METADATA" "-DSQLITE_ENABLE_DBSTAT_VTAB" + "-DSQLITE_ENABLE_JSON1" "-DSQLITE_ENABLE_FTS3" "-DSQLITE_ENABLE_FTS3_PARENTHESIS" "-DSQLITE_ENABLE_FTS4" -- cgit 1.4.1 From 4ba34e7055719f41ccaca655c0c9a7a8ed13d03b Mon Sep 17 00:00:00 2001 From: Vladimír ÄŒunát Date: Tue, 27 Oct 2015 18:03:38 +0100 Subject: openssl: fix darwin patch The things around this file are rather confusing, but judging from master, 1.0.2 branch doesn't need this patch to build on darwin. This just takes back the patch to the state for 1.0.1. --- pkgs/development/libraries/openssl/darwin-arch.patch | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/openssl/darwin-arch.patch b/pkgs/development/libraries/openssl/darwin-arch.patch index 238dd7d08d8..63db3efc084 100644 --- a/pkgs/development/libraries/openssl/darwin-arch.patch +++ b/pkgs/development/libraries/openssl/darwin-arch.patch @@ -1,13 +1,12 @@ -diff --git a/Configure b/Configure -index d99eed7..341dbd0 100755 ---- a/Configure -+++ b/Configure -@@ -638,7 +638,7 @@ my %table=( +diff -ru -x '*~' openssl-1.0.1c-orig/Configure openssl-1.0.1c/Configure +--- openssl-1.0.1c-orig/Configure 2012-03-14 23:20:40.000000000 +0100 ++++ openssl-1.0.1c/Configure 2012-12-18 17:29:30.268090633 +0100 +@@ -579,7 +579,7 @@ "darwin64-ppc-cc","cc:-arch ppc64 -O3 -DB_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${ppc64_asm}:osx64:dlfcn:darwin-shared:-fPIC -fno-common:-arch ppc64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", "darwin-i386-cc","cc:-arch i386 -O3 -fomit-frame-pointer -DL_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:BN_LLONG RC4_INT RC4_CHUNK DES_UNROLL BF_PTR:".eval{my $asm=$x86_asm;$asm=~s/cast\-586\.o//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch i386 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", "debug-darwin-i386-cc","cc:-arch i386 -g3 -DL_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:BN_LLONG RC4_INT RC4_CHUNK DES_UNROLL BF_PTR:${x86_asm}:macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch i386 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", --"darwin64-x86_64-cc","cc:-arch x86_64 -O3 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$x86_64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch x86_64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", +-"darwin64-x86_64-cc","cc:-arch x86_64 -O3 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$x86_64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch x86_64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", +"darwin64-x86_64-cc","cc:-O3 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$x86_64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", - "debug-darwin64-x86_64-cc","cc:-arch x86_64 -ggdb -g2 -O0 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$x86_64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch x86_64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", "debug-darwin-ppc-cc","cc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DCRYPTO_MDEBUG -DB_ENDIAN -g -Wall -O::-D_REENTRANT:MACOSX::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${ppc32_asm}:osx32:dlfcn:darwin-shared:-fPIC:-dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", # iPhoneOS/iOS + "iphoneos-cross","llvm-gcc:-O3 -isysroot \$(CROSS_TOP)/SDKs/\$(CROSS_SDK) -fomit-frame-pointer -fno-common::-D_REENTRANT:iOS:-Wl,-search_paths_first%:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${no_asm}:dlfcn:darwin-shared:-fPIC -fno-common:-dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib", -- cgit 1.4.1 From 00c90391417a91a6218ccdb952f2dac2c11d8d05 Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Fri, 30 Oct 2015 18:07:41 -0700 Subject: mesa: 11.0.3 -> 11.0.4 --- pkgs/development/libraries/mesa/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/mesa/default.nix b/pkgs/development/libraries/mesa/default.nix index 0e2d1af3a31..b0c26def14a 100644 --- a/pkgs/development/libraries/mesa/default.nix +++ b/pkgs/development/libraries/mesa/default.nix @@ -22,7 +22,7 @@ else */ let - version = "11.0.3"; + version = "11.0.4"; # this is the default search path for DRI drivers driverLink = "/run/opengl-driver" + stdenv.lib.optionalString stdenv.isi686 "-32"; in @@ -36,7 +36,7 @@ stdenv.mkDerivation { "https://launchpad.net/mesa/trunk/${version}/+download/mesa-${version}.tar.xz" "ftp://ftp.freedesktop.org/pub/mesa/${version}/mesa-${version}.tar.xz" ]; - sha256 = "ab2992eece21adc23c398720ef8c6933cb69ea42e1b2611dc09d031e17e033d6"; + sha256 = "40201bf7fc6fa12a6d9edfe870b41eb4dd6669154e3c42c48a96f70805f5483d"; }; prePatch = "patchShebangs ."; -- cgit 1.4.1 From 0a2c78fb5fecf00a4eb06792a23de576d7e5692e Mon Sep 17 00:00:00 2001 From: Stéphane Jourdois Date: Sun, 1 Nov 2015 12:58:31 +0100 Subject: cairo: maintenance update 1.14.2 -> 1.14.4 (close #10778) --- pkgs/development/libraries/cairo/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/cairo/default.nix b/pkgs/development/libraries/cairo/default.nix index e2d6b25e137..5add4e45129 100644 --- a/pkgs/development/libraries/cairo/default.nix +++ b/pkgs/development/libraries/cairo/default.nix @@ -11,11 +11,11 @@ assert glSupport -> mesa_noglu != null; with { inherit (stdenv.lib) optional optionals; }; stdenv.mkDerivation rec { - name = "cairo-1.14.2"; + name = "cairo-1.14.4"; src = fetchurl { url = "http://cairographics.org/releases/${name}.tar.xz"; - sha1 = "c8da68aa66ca0855b5d0ff552766d3e8679e1d24"; + sha256 = "05p75r914d809711yg9rapgmmi4hymzbarhd3w0yrfadhiy9rv7n"; }; nativeBuildInputs = [ pkgconfig libiconv ] ++ libintlOrEmpty; -- cgit 1.4.1 From bf41c5c23374f8443d03658e814b09205a7c2a99 Mon Sep 17 00:00:00 2001 From: Pascal Wittmann Date: Wed, 4 Nov 2015 21:05:44 +0100 Subject: audiofile: fix CVE-2015-7747 (close #10829) Fixes #10678. --- .../libraries/audiofile/CVE-2015-7747.patch | 161 +++++++++++++++++++++ pkgs/development/libraries/audiofile/default.nix | 2 + 2 files changed, 163 insertions(+) create mode 100644 pkgs/development/libraries/audiofile/CVE-2015-7747.patch (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/audiofile/CVE-2015-7747.patch b/pkgs/development/libraries/audiofile/CVE-2015-7747.patch new file mode 100644 index 00000000000..a01aaa14dce --- /dev/null +++ b/pkgs/development/libraries/audiofile/CVE-2015-7747.patch @@ -0,0 +1,161 @@ +Description: fix buffer overflow when changing both sample format and + number of channels +Origin: backport, https://github.com/mpruett/audiofile/pull/25 +Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/audiofile/+bug/1502721 +Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=801102 + +Index: audiofile-0.3.6/libaudiofile/modules/ModuleState.cpp +=================================================================== +--- audiofile-0.3.6.orig/libaudiofile/modules/ModuleState.cpp 2015-10-20 08:00:58.036128202 -0400 ++++ audiofile-0.3.6/libaudiofile/modules/ModuleState.cpp 2015-10-20 08:00:58.036128202 -0400 +@@ -402,7 +402,7 @@ + addModule(new Transform(outfc, in.pcm, out.pcm)); + + if (in.channelCount != out.channelCount) +- addModule(new ApplyChannelMatrix(infc, isReading, ++ addModule(new ApplyChannelMatrix(outfc, isReading, + in.channelCount, out.channelCount, + in.pcm.minClip, in.pcm.maxClip, + track->channelMatrix)); +Index: audiofile-0.3.6/test/Makefile.am +=================================================================== +--- audiofile-0.3.6.orig/test/Makefile.am 2015-10-20 08:00:58.036128202 -0400 ++++ audiofile-0.3.6/test/Makefile.am 2015-10-20 08:00:58.036128202 -0400 +@@ -26,6 +26,7 @@ + VirtualFile \ + floatto24 \ + query2 \ ++ sixteen-stereo-to-eight-mono \ + sixteen-to-eight \ + testchannelmatrix \ + testdouble \ +@@ -139,6 +140,7 @@ + printmarkers_LDADD = $(LIBAUDIOFILE) -lm + + sixteen_to_eight_SOURCES = sixteen-to-eight.c TestUtilities.cpp TestUtilities.h ++sixteen_stereo_to_eight_mono_SOURCES = sixteen-stereo-to-eight-mono.c TestUtilities.cpp TestUtilities.h + + testchannelmatrix_SOURCES = testchannelmatrix.c TestUtilities.cpp TestUtilities.h + +Index: audiofile-0.3.6/test/sixteen-stereo-to-eight-mono.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ audiofile-0.3.6/test/sixteen-stereo-to-eight-mono.c 2015-10-20 08:33:57.512286416 -0400 +@@ -0,0 +1,117 @@ ++/* ++ Audio File Library ++ ++ Copyright 2000, Silicon Graphics, Inc. ++ ++ This program is free software; you can redistribute it and/or modify ++ it under the terms of the GNU General Public License as published by ++ the Free Software Foundation; either version 2 of the License, or ++ (at your option) any later version. ++ ++ This program is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++ GNU General Public License for more details. ++ ++ You should have received a copy of the GNU General Public License along ++ with this program; if not, write to the Free Software Foundation, Inc., ++ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. ++*/ ++ ++/* ++ sixteen-stereo-to-eight-mono.c ++ ++ This program tests the conversion from 2-channel 16-bit integers to ++ 1-channel 8-bit integers. ++*/ ++ ++#ifdef HAVE_CONFIG_H ++#include ++#endif ++ ++#include ++#include ++#include ++#include ++#include ++#include ++ ++#include ++ ++#include "TestUtilities.h" ++ ++int main (int argc, char **argv) ++{ ++ AFfilehandle file; ++ AFfilesetup setup; ++ int16_t frames16[] = {14298, 392, 3923, -683, 958, -1921}; ++ int8_t frames8[] = {28, 6, -2}; ++ int i, frameCount = 3; ++ int8_t byte; ++ AFframecount result; ++ ++ setup = afNewFileSetup(); ++ ++ afInitFileFormat(setup, AF_FILE_WAVE); ++ ++ afInitSampleFormat(setup, AF_DEFAULT_TRACK, AF_SAMPFMT_TWOSCOMP, 16); ++ afInitChannels(setup, AF_DEFAULT_TRACK, 2); ++ ++ char testFileName[PATH_MAX]; ++ if (!createTemporaryFile("sixteen-to-eight", testFileName)) ++ { ++ fprintf(stderr, "Could not create temporary file.\n"); ++ exit(EXIT_FAILURE); ++ } ++ ++ file = afOpenFile(testFileName, "w", setup); ++ if (file == AF_NULL_FILEHANDLE) ++ { ++ fprintf(stderr, "could not open file for writing\n"); ++ exit(EXIT_FAILURE); ++ } ++ ++ afFreeFileSetup(setup); ++ ++ afWriteFrames(file, AF_DEFAULT_TRACK, frames16, frameCount); ++ ++ afCloseFile(file); ++ ++ file = afOpenFile(testFileName, "r", AF_NULL_FILESETUP); ++ if (file == AF_NULL_FILEHANDLE) ++ { ++ fprintf(stderr, "could not open file for reading\n"); ++ exit(EXIT_FAILURE); ++ } ++ ++ afSetVirtualSampleFormat(file, AF_DEFAULT_TRACK, AF_SAMPFMT_TWOSCOMP, 8); ++ afSetVirtualChannels(file, AF_DEFAULT_TRACK, 1); ++ ++ for (i=0; i Date: Thu, 5 Nov 2015 18:25:39 -0800 Subject: icu: 55.1 -> 56.1 --- pkgs/development/libraries/icu/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/icu/default.nix b/pkgs/development/libraries/icu/default.nix index 909f4e936a9..a2196d26524 100644 --- a/pkgs/development/libraries/icu/default.nix +++ b/pkgs/development/libraries/icu/default.nix @@ -2,7 +2,7 @@ let pname = "icu4c"; - version = "55.1"; + version = "56.1"; in stdenv.mkDerivation { name = pname + "-" + version; @@ -10,7 +10,7 @@ stdenv.mkDerivation { src = fetchurl { url = "http://download.icu-project.org/files/${pname}/${version}/${pname}-" + (stdenv.lib.replaceChars ["."] ["_"] version) + "-src.tgz"; - sha256 = "0ys5f5spizg45qlaa31j2lhgry0jka2gfha527n4ndfxxz5j4sz1"; + sha256 = "05j86714qaj0lvhvyr2s1xncw6sk0h2dcghb3iiwykbkbh8fjr1s"; }; makeFlags = stdenv.lib.optionalString stdenv.isDarwin -- cgit 1.4.1 From 974dd8012d890ce0a1932caacfb068fe92cf2f33 Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Thu, 5 Nov 2015 18:25:49 -0800 Subject: sqlite: 3.9.1 -> 3.9.2 --- pkgs/development/libraries/sqlite/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/sqlite/default.nix b/pkgs/development/libraries/sqlite/default.nix index c337de867e0..d9fbde9aa09 100644 --- a/pkgs/development/libraries/sqlite/default.nix +++ b/pkgs/development/libraries/sqlite/default.nix @@ -3,11 +3,11 @@ assert interactive -> readline != null && ncurses != null; stdenv.mkDerivation { - name = "sqlite-3.9.1"; + name = "sqlite-3.9.2"; src = fetchurl { - url = "http://sqlite.org/2015/sqlite-autoconf-3090100.tar.gz"; - sha1 = "6b7d22c24c9695118a2706c8e026fb3c31780a30"; + url = "http://sqlite.org/2015/sqlite-autoconf-3090200.tar.gz"; + sha1 = "dae1ae5297fece9671ae0c434a7ecd0cda09c76a"; }; buildInputs = lib.optionals interactive [ readline ncurses ]; -- cgit 1.4.1 From 767f1d5a74404d7c60a62227fa0d0bb57be87e5f Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Sat, 7 Nov 2015 16:32:17 -0800 Subject: glib: 2.46.0 -> 2.46.2 --- pkgs/development/libraries/glib/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/glib/default.nix b/pkgs/development/libraries/glib/default.nix index 137fe943637..bafe8949e93 100644 --- a/pkgs/development/libraries/glib/default.nix +++ b/pkgs/development/libraries/glib/default.nix @@ -40,7 +40,7 @@ let ''; ver_maj = "2.46"; - ver_min = "0"; + ver_min = "2"; in stdenv.mkDerivation rec { @@ -48,7 +48,7 @@ stdenv.mkDerivation rec { src = fetchurl { url = "mirror://gnome/sources/glib/${ver_maj}/${name}.tar.xz"; - sha256 = "b1cee83469ae7d80f17c267c37f090414e93960bd62d2b254a5a96fbc5baacb4"; + sha256 = "5031722e37036719c1a09163cc6cf7c326e4c4f1f1e074b433c156862bd733db"; }; patches = optional stdenv.isDarwin ./darwin-compilation.patch ++ optional doCheck ./skip-timer-test.patch; -- cgit 1.4.1 From 63385e971250812a232c5853b28cd46d80836a2c Mon Sep 17 00:00:00 2001 From: taku0 Date: Mon, 26 Oct 2015 21:08:51 +0900 Subject: ncurses: revived clang patch (close #10622) --- pkgs/development/libraries/ncurses/clang.patch | 42 ++++++++++++++++++++++++++ pkgs/development/libraries/ncurses/default.nix | 2 +- 2 files changed, 43 insertions(+), 1 deletion(-) create mode 100644 pkgs/development/libraries/ncurses/clang.patch (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/ncurses/clang.patch b/pkgs/development/libraries/ncurses/clang.patch new file mode 100644 index 00000000000..ce33049bf40 --- /dev/null +++ b/pkgs/development/libraries/ncurses/clang.patch @@ -0,0 +1,42 @@ +diff -ruNp ncurses-5.8.orig/c++/cursesf.h ncurses-5.8/c++/cursesf.h +--- ncurses-5.8.orig/c++/cursesf.h 2005-08-13 21:08:24.000000000 +0300 ++++ ncurses-5.8/c++/cursesf.h 2011-04-03 18:29:29.000000000 +0300 +@@ -681,7 +681,7 @@ public: + const T* p_UserData = STATIC_CAST(T*)(0), + bool with_frame=FALSE, + bool autoDelete_Fields=FALSE) +- : NCursesForm (Fields, with_frame, autoDelete_Fields) { ++ : NCursesForm (&Fields, with_frame, autoDelete_Fields) { + if (form) + set_user (const_cast(p_UserData)); + }; +@@ -694,7 +694,7 @@ public: + const T* p_UserData = STATIC_CAST(T*)(0), + bool with_frame=FALSE, + bool autoDelete_Fields=FALSE) +- : NCursesForm (Fields, nlines, ncols, begin_y, begin_x, ++ : NCursesForm (&Fields, nlines, ncols, begin_y, begin_x, + with_frame, autoDelete_Fields) { + if (form) + set_user (const_cast(p_UserData)); +diff -ruNp ncurses-5.8.orig/c++/cursesm.h ncurses-5.8/c++/cursesm.h +--- ncurses-5.8.orig/c++/cursesm.h 2005-08-13 21:10:36.000000000 +0300 ++++ ncurses-5.8/c++/cursesm.h 2011-04-03 18:31:42.000000000 +0300 +@@ -639,7 +639,7 @@ public: + const T* p_UserData = STATIC_CAST(T*)(0), + bool with_frame=FALSE, + bool autoDelete_Items=FALSE) +- : NCursesMenu (Items, with_frame, autoDelete_Items) { ++ : NCursesMenu (&Items, with_frame, autoDelete_Items) { + if (menu) + set_user (const_cast(p_UserData)); + }; +@@ -651,7 +651,7 @@ public: + int begin_x = 0, + const T* p_UserData = STATIC_CAST(T*)(0), + bool with_frame=FALSE) +- : NCursesMenu (Items, nlines, ncols, begin_y, begin_x, with_frame) { ++ : NCursesMenu (&Items, nlines, ncols, begin_y, begin_x, with_frame) { + if (menu) + set_user (const_cast(p_UserData)); + }; diff --git a/pkgs/development/libraries/ncurses/default.nix b/pkgs/development/libraries/ncurses/default.nix index 51741005158..c505d89a6d8 100644 --- a/pkgs/development/libraries/ncurses/default.nix +++ b/pkgs/development/libraries/ncurses/default.nix @@ -18,7 +18,7 @@ stdenv.mkDerivation rec { }; # gcc-5.patch should be removed after 5.9 - patches = [ ./gcc-5.patch ]; + patches = [ ./clang.patch ./gcc-5.patch ]; configureFlags = [ "--with-shared" -- cgit 1.4.1 From cb21b77ff1b9ed006d1180ad7c94b2ee7ed3c096 Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Tue, 10 Nov 2015 18:25:47 -0800 Subject: gtk3: 3.18.0 -> 3.18.3 --- pkgs/development/libraries/gtk+/3.x.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/libraries') diff --git a/pkgs/development/libraries/gtk+/3.x.nix b/pkgs/development/libraries/gtk+/3.x.nix index 9bf95d015dd..2a7c7b88c38 100644 --- a/pkgs/development/libraries/gtk+/3.x.nix +++ b/pkgs/development/libraries/gtk+/3.x.nix @@ -10,7 +10,7 @@ assert cupsSupport -> cups != null; let ver_maj = "3.18"; - ver_min = "0"; + ver_min = "3"; version = "${ver_maj}.${ver_min}"; in stdenv.mkDerivation rec { @@ -18,7 +18,7 @@ stdenv.mkDerivation rec { src = fetchurl { url = "mirror://gnome/sources/gtk+/${ver_maj}/gtk+-${version}.tar.xz"; - sha256 = "7fb8ae257403317d3852bad28d064d35f67e978b1fed8b71d5997e87204271b9"; + sha256 = "f3c76791f93f51e260b03676f83007730b9875a0a9bf5cd42442e2f14e593546"; }; nativeBuildInputs = [ pkgconfig gettext gobjectIntrospection perl ]; -- cgit 1.4.1