Merge commit '2d464f75ed46869b5942c4b479772a0367b30608' into master.upstream

This is a partial commit from staging in an attempt to make merges
smaller.

+3689 -257
+7 -1
pkgs/applications/editors/emacs-24/default.nix
··· 1 { stdenv, fetchurl, ncurses, xlibsWrapper, libXaw, libXpm, Xaw3d 2 , pkgconfig, gettext, libXft, dbus, libpng, libjpeg, libungif 3 , libtiff, librsvg, texinfo, gconf, libxml2, imagemagick, gnutls 4 - , alsaLib, cairo, acl, gpm 5 , withX ? !stdenv.isDarwin 6 , withGTK3 ? false, gtk3 ? null 7 , withGTK2 ? true, gtk2 ··· 48 ++ stdenv.lib.optional (withX && withGTK2) gtk2 49 ++ stdenv.lib.optional (withX && withGTK3) gtk3 50 ++ stdenv.lib.optional (stdenv.isDarwin && withX) cairo; 51 52 configureFlags = 53 if stdenv.isDarwin
··· 1 { stdenv, fetchurl, ncurses, xlibsWrapper, libXaw, libXpm, Xaw3d 2 , pkgconfig, gettext, libXft, dbus, libpng, libjpeg, libungif 3 , libtiff, librsvg, texinfo, gconf, libxml2, imagemagick, gnutls 4 + , alsaLib, cairo, acl, gpm, AppKit, Foundation, libobjc 5 , withX ? !stdenv.isDarwin 6 , withGTK3 ? false, gtk3 ? null 7 , withGTK2 ? true, gtk2 ··· 48 ++ stdenv.lib.optional (withX && withGTK2) gtk2 49 ++ stdenv.lib.optional (withX && withGTK3) gtk3 50 ++ stdenv.lib.optional (stdenv.isDarwin && withX) cairo; 51 + 52 + propagatedBuildInputs = stdenv.lib.optionals stdenv.isDarwin [ AppKit Foundation libobjc 53 + ]; 54 + 55 + NIX_LDFLAGS = stdenv.lib.optional stdenv.isDarwin 56 + "/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation"; 57 58 configureFlags = 59 if stdenv.isDarwin
+1 -1
pkgs/applications/kde-apps-15.04/default.nix
··· 177 strigi taglib udev xorg xplanet xscreensaver xz; 178 alsa = alsaLib; 179 assuan = libassuan; 180 - boost = boost156; 181 canberra = libcanberra; 182 eigen3 = eigen; 183 epub = ebook_tools;
··· 177 strigi taglib udev xorg xplanet xscreensaver xz; 178 alsa = alsaLib; 179 assuan = libassuan; 180 + boost = boost155; 181 canberra = libcanberra; 182 eigen3 = eigen; 183 epub = ebook_tools;
+1 -1
pkgs/build-support/setup-hooks/patch-shebangs.sh
··· 5 # rewritten to /nix/store/<hash>/bin/python. Interpreters that are 6 # already in the store are left untouched. 7 8 - fixupOutputHooks+=('if [ -z "$dontPatchShebangs" ]; then patchShebangs "$prefix"; fi') 9 10 patchShebangs() { 11 local dir="$1"
··· 5 # rewritten to /nix/store/<hash>/bin/python. Interpreters that are 6 # already in the store are left untouched. 7 8 + fixupOutputHooks+=('if [ -z "$dontPatchShebangs" -a -e "$prefix" ]; then patchShebangs "$prefix"; fi') 9 10 patchShebangs() { 11 local dir="$1"
+1 -1
pkgs/desktops/plasma-5.3/default.nix
··· 129 modemmanager openconnect openexr pam pango qt4 samba 130 socat substituteAll taglib utillinux wayland xapian 131 xkeyboard_config xorg; 132 - boost = boost156; 133 canberra = libcanberra; 134 epub = ebook_tools; 135 fontforge_executable = fontforge;
··· 129 modemmanager openconnect openexr pam pango qt4 samba 130 socat substituteAll taglib utillinux wayland xapian 131 xkeyboard_config xorg; 132 + boost = boost155; 133 canberra = libcanberra; 134 epub = ebook_tools; 135 fontforge_executable = fontforge;
-10
pkgs/development/libraries/boost/1.56.nix
··· 1 - { callPackage, fetchurl, ... } @ args: 2 - 3 - callPackage ./generic.nix (args // rec { 4 - version = "1.56.0"; 5 - 6 - src = fetchurl { 7 - url = "mirror://sourceforge/boost/boost_1_56_0.tar.bz2"; 8 - sha256 = "07gz62nj767qzwqm3xjh11znpyph8gcii0cqhnx7wvismyn34iqk"; 9 - }; 10 - })
···
-40
pkgs/development/libraries/boost/1.57.nix
··· 1 - { stdenv, callPackage, fetchurl, ... } @ args: 2 - 3 - callPackage ./generic.nix (args // rec { 4 - version = "1.57.0"; 5 - 6 - src = fetchurl { 7 - url = "mirror://sourceforge/boost/boost_1_57_0.tar.bz2"; 8 - sha256 = "0rs94vdmg34bwwj23fllva6mhrml2i7mvmlb11zyrk1k5818q34i"; 9 - }; 10 - 11 - patches = if stdenv.isCygwin then [ 12 - ./cygwin-fedora-boost-1.50.0-fix-non-utf8-files.patch 13 - ./cygwin-fedora-boost-1.50.0-pool.patch 14 - ./cygwin-fedora-boost-1.57.0-mpl-print.patch 15 - ./cygwin-fedora-boost-1.57.0-spirit-unused_typedef.patch 16 - ./cygwin-fedora-boost-1.54.0-locale-unused_typedef.patch 17 - ./cygwin-fedora-boost-1.54.0-python-unused_typedef.patch 18 - ./cygwin-fedora-boost-1.57.0-pool-test_linking.patch 19 - ./cygwin-fedora-boost-1.54.0-pool-max_chunks_shadow.patch 20 - ./cygwin-fedora-boost-1.57.0-signals2-weak_ptr.patch 21 - ./cygwin-fedora-boost-1.57.0-uuid-comparison.patch 22 - ./cygwin-fedora-boost-1.57.0-move-is_class.patch 23 - ./cygwin-1.40.0-cstdint-cygwin.patch 24 - ./cygwin-1.57.0-asio-cygwin.patch 25 - ./cygwin-1.55.0-asio-MSG_EOR.patch 26 - ./cygwin-1.57.0-config-cygwin.patch 27 - ./cygwin-1.57.0-context-cygwin.patch 28 - ./cygwin-1.57.0-filesystem-cygwin.patch 29 - ./cygwin-1.55.0-interlocked-cygwin.patch 30 - ./cygwin-1.40.0-iostreams-cygwin.patch 31 - ./cygwin-1.57.0-locale-cygwin.patch 32 - ./cygwin-1.57.0-log-cygwin.patch 33 - ./cygwin-1.40.0-python-cygwin.patch 34 - ./cygwin-1.40.0-regex-cygwin.patch 35 - ./cygwin-1.57.0-smart_ptr-cygwin.patch 36 - ./cygwin-1.57.0-system-cygwin.patch 37 - ./cygwin-1.45.0-jam-cygwin.patch 38 - ./cygwin-1.50.0-jam-pep3149.patch 39 - ] else null; 40 - })
···
-40
pkgs/development/libraries/boost/1.58.nix
··· 1 - { stdenv, callPackage, fetchurl, ... } @ args: 2 - 3 - callPackage ./generic.nix (args // rec { 4 - version = "1.58.0"; 5 - 6 - src = fetchurl { 7 - url = "mirror://sourceforge/boost/boost_1_58_0.tar.bz2"; 8 - sha256 = "1rfkqxns60171q62cppiyzj8pmsbwp1l8jd7p6crriryqd7j1z7x"; 9 - }; 10 - 11 - patches = if stdenv.isCygwin then [ 12 - ./cygwin-fedora-boost-1.50.0-fix-non-utf8-files.patch 13 - ./cygwin-fedora-boost-1.50.0-pool.patch 14 - ./cygwin-fedora-boost-1.57.0-mpl-print.patch 15 - ./cygwin-fedora-boost-1.57.0-spirit-unused_typedef.patch 16 - ./cygwin-fedora-boost-1.54.0-locale-unused_typedef.patch 17 - ./cygwin-fedora-boost-1.54.0-python-unused_typedef.patch 18 - ./cygwin-fedora-boost-1.57.0-pool-test_linking.patch 19 - ./cygwin-fedora-boost-1.54.0-pool-max_chunks_shadow.patch 20 - ./cygwin-fedora-boost-1.57.0-signals2-weak_ptr.patch 21 - ./cygwin-fedora-boost-1.57.0-uuid-comparison.patch 22 - ./cygwin-fedora-boost-1.57.0-move-is_class.patch 23 - ./cygwin-1.40.0-cstdint-cygwin.patch 24 - ./cygwin-1.57.0-asio-cygwin.patch 25 - ./cygwin-1.55.0-asio-MSG_EOR.patch 26 - ./cygwin-1.57.0-config-cygwin.patch 27 - ./cygwin-1.57.0-context-cygwin.patch 28 - ./cygwin-1.57.0-filesystem-cygwin.patch 29 - ./cygwin-1.55.0-interlocked-cygwin.patch 30 - ./cygwin-1.40.0-iostreams-cygwin.patch 31 - ./cygwin-1.57.0-locale-cygwin.patch 32 - ./cygwin-1.57.0-log-cygwin.patch 33 - ./cygwin-1.40.0-python-cygwin.patch 34 - ./cygwin-1.40.0-regex-cygwin.patch 35 - ./cygwin-1.57.0-smart_ptr-cygwin.patch 36 - ./cygwin-1.57.0-system-cygwin.patch 37 - ./cygwin-1.45.0-jam-cygwin.patch 38 - ./cygwin-1.50.0-jam-pep3149.patch 39 - ] else null; 40 - })
···
+3 -3
pkgs/development/libraries/folly/default.nix
··· 2 , google-gflags, python, libiberty, openssl }: 3 4 stdenv.mkDerivation rec { 5 - version = "0.57.0"; 6 name = "folly-${version}"; 7 8 src = fetchFromGitHub { 9 owner = "facebook"; 10 repo = "folly"; 11 - rev = "v${version}"; 12 - sha256 = "12b9bkwmndfwmsknc209kpplxn9wqmwr3p2h0l2szrppq4qqyfq9"; 13 }; 14 15 nativeBuildInputs = [ autoreconfHook python ];
··· 2 , google-gflags, python, libiberty, openssl }: 3 4 stdenv.mkDerivation rec { 5 + version = "2015-09-17"; 6 name = "folly-${version}"; 7 8 src = fetchFromGitHub { 9 owner = "facebook"; 10 repo = "folly"; 11 + rev = "e4527fb5d04f5fec823bd6a2402b620a6e1a64e3"; 12 + sha256 = "0iicq19yylafr7qs221xgk8pcwf6nnyx6srgsx9y9cyf72siadcb"; 13 }; 14 15 nativeBuildInputs = [ autoreconfHook python ];
+4 -4
pkgs/development/libraries/gdk-pixbuf/default.nix
··· 1 { stdenv, fetchurl, pkgconfig, glib, libtiff, libjpeg, libpng, libX11 2 - , jasper, libintlOrEmpty, gobjectIntrospection }: 3 4 let 5 ver_maj = "2.31"; 6 - ver_min = "6"; 7 in 8 stdenv.mkDerivation rec { 9 name = "gdk-pixbuf-${ver_maj}.${ver_min}"; 10 11 src = fetchurl { 12 url = "mirror://gnome/sources/gdk-pixbuf/${ver_maj}/${name}.tar.xz"; 13 - sha256 = "062x2gqd7p6yxhxlib1ha4l3gk9ihcj080hrwwv9vmlmybb064hi"; 14 }; 15 16 setupHook = ./setup-hook.sh; ··· 27 ; 28 29 # The tests take an excessive amount of time (> 1.5 hours) and memory (> 6 GB). 30 - doCheck = false; 31 32 postInstall = "rm -rf $out/share/gtk-doc"; 33
··· 1 { stdenv, fetchurl, pkgconfig, glib, libtiff, libjpeg, libpng, libX11 2 + , jasper, libintlOrEmpty, gobjectIntrospection, doCheck ? false }: 3 4 let 5 ver_maj = "2.31"; 6 + ver_min = "7"; 7 in 8 stdenv.mkDerivation rec { 9 name = "gdk-pixbuf-${ver_maj}.${ver_min}"; 10 11 src = fetchurl { 12 url = "mirror://gnome/sources/gdk-pixbuf/${ver_maj}/${name}.tar.xz"; 13 + sha256 = "046n9wz16kh3rpzxaiiwphf5bihxgj4g14cjn65wwmw82q4y0dj7"; 14 }; 15 16 setupHook = ./setup-hook.sh; ··· 27 ; 28 29 # The tests take an excessive amount of time (> 1.5 hours) and memory (> 6 GB). 30 + inherit (doCheck); 31 32 postInstall = "rm -rf $out/share/gtk-doc"; 33
+8 -8
pkgs/development/libraries/gtk+/3.x.nix
··· 10 11 let 12 ver_maj = "3.16"; 13 - ver_min = "6"; 14 version = "${ver_maj}.${ver_min}"; 15 in 16 stdenv.mkDerivation rec { ··· 18 19 src = fetchurl { 20 url = "mirror://gnome/sources/gtk+/${ver_maj}/gtk+-${version}.tar.xz"; 21 - sha256 = "1gpzlnfrifc17yfk0zki6b2vmsfpf5cmrbh232s6iaan11np44jd"; 22 }; 23 24 nativeBuildInputs = [ pkgconfig gettext gobjectIntrospection perl ]; ··· 30 ++ optional xineramaSupport libXinerama 31 ++ optional cupsSupport cups; 32 33 - NIX_LDFLAGS = if stdenv.isDarwin then "-lintl" else null; 34 - 35 # demos fail to install, no idea where's the problem 36 preConfigure = "sed '/^SRC_SUBDIRS /s/demos//' -i Makefile.in"; 37 38 enableParallelBuilding = true; 39 40 postInstall = "rm -rf $out/share/gtk-doc"; 41 ··· 46 ''; # workaround for bug of nix-mode for Emacs */ ''; 47 }; 48 49 - meta = { 50 description = "A multi-platform toolkit for creating graphical user interfaces"; 51 52 longDescription = '' ··· 62 63 homepage = http://www.gtk.org/; 64 65 - license = stdenv.lib.licenses.lgpl2Plus; 66 67 - maintainers = with stdenv.lib.maintainers; [ urkud raskin vcunat lethalman ]; 68 - platforms = stdenv.lib.platforms.all; 69 }; 70 }
··· 10 11 let 12 ver_maj = "3.16"; 13 + ver_min = "7"; 14 version = "${ver_maj}.${ver_min}"; 15 in 16 stdenv.mkDerivation rec { ··· 18 19 src = fetchurl { 20 url = "mirror://gnome/sources/gtk+/${ver_maj}/gtk+-${version}.tar.xz"; 21 + sha256 = "1fkzdhqa1pjzb1qsh2ll3y2567ylyszks59qspx85lalvqa9ss0r"; 22 }; 23 24 nativeBuildInputs = [ pkgconfig gettext gobjectIntrospection perl ]; ··· 30 ++ optional xineramaSupport libXinerama 31 ++ optional cupsSupport cups; 32 33 # demos fail to install, no idea where's the problem 34 preConfigure = "sed '/^SRC_SUBDIRS /s/demos//' -i Makefile.in"; 35 36 enableParallelBuilding = true; 37 + 38 + NIX_LDFLAGS = stdenv.lib.optionalString stdenv.isDarwin "-lintl"; 39 40 postInstall = "rm -rf $out/share/gtk-doc"; 41 ··· 46 ''; # workaround for bug of nix-mode for Emacs */ ''; 47 }; 48 49 + meta = with stdenv.lib; { 50 description = "A multi-platform toolkit for creating graphical user interfaces"; 51 52 longDescription = '' ··· 62 63 homepage = http://www.gtk.org/; 64 65 + license = licenses.lgpl2Plus; 66 67 + maintainers = with maintainers; [ urkud raskin vcunat lethalman ]; 68 + platforms = platforms.all; 69 }; 70 }
+2 -2
pkgs/development/libraries/harfbuzz/default.nix
··· 8 # (icu is a ~30 MB dependency, the rest is very small in comparison) 9 10 stdenv.mkDerivation rec { 11 - name = "harfbuzz-1.0.2"; 12 13 src = fetchurl { 14 url = "http://www.freedesktop.org/software/harfbuzz/release/${name}.tar.bz2"; 15 - sha256 = "0rmlwfxyzdblnvg72hpfcz2py8rjflx0m08wlvfgq420cpwcmcxy"; 16 }; 17 18 outputs = [ "out" "doc" ];
··· 8 # (icu is a ~30 MB dependency, the rest is very small in comparison) 9 10 stdenv.mkDerivation rec { 11 + name = "harfbuzz-1.0.3"; 12 13 src = fetchurl { 14 url = "http://www.freedesktop.org/software/harfbuzz/release/${name}.tar.bz2"; 15 + sha256 = "1xrxlrvgyr6mm9qjxmkif2kvcah082y94gf1vqi0f0bdl1g8gp7b"; 16 }; 17 18 outputs = [ "out" "doc" ];
+1 -1
pkgs/development/libraries/kde-frameworks-5.10/default.nix
··· 117 inherit acl cmake docbook_xml_dtd_45 docbook5_xsl epoxy fam gpgme 118 libgcrypt libgit2 modemmanager networkmanager perl 119 perlPackages qimageblitz xorg zlib; 120 - boost = boost156; 121 gif = giflib; 122 glib2 = glib; 123 jpeg = libjpeg;
··· 117 inherit acl cmake docbook_xml_dtd_45 docbook5_xsl epoxy fam gpgme 118 libgcrypt libgit2 modemmanager networkmanager perl 119 perlPackages qimageblitz xorg zlib; 120 + boost = boost155; 121 gif = giflib; 122 glib2 = glib; 123 jpeg = libjpeg;
+1 -1
pkgs/development/libraries/kde-frameworks-5.12/default.nix
··· 117 inherit acl cmake docbook_xml_dtd_45 docbook5_xsl epoxy fam gpgme 118 libgcrypt libgit2 modemmanager networkmanager perl 119 perlPackages qimageblitz xorg zlib; 120 - boost = boost156; 121 gif = giflib; 122 glib2 = glib; 123 jpeg = libjpeg;
··· 117 inherit acl cmake docbook_xml_dtd_45 docbook5_xsl epoxy fam gpgme 118 libgcrypt libgit2 modemmanager networkmanager perl 119 perlPackages qimageblitz xorg zlib; 120 + boost = boost155; 121 gif = giflib; 122 glib2 = glib; 123 jpeg = libjpeg;
+2 -2
pkgs/development/libraries/libdrm/default.nix
··· 1 { stdenv, fetchurl, pkgconfig, libpthreadstubs, libpciaccess, udev, valgrind }: 2 3 stdenv.mkDerivation rec { 4 - name = "libdrm-2.4.64"; 5 6 src = fetchurl { 7 url = "http://dri.freedesktop.org/libdrm/${name}.tar.bz2"; 8 - sha256 = "1dilm6cwqfx9plf3i5kkaf6m5v1zyrcadqbcjsrsshkfgpz8c1xn"; 9 }; 10 11 nativeBuildInputs = [ pkgconfig ];
··· 1 { stdenv, fetchurl, pkgconfig, libpthreadstubs, libpciaccess, udev, valgrind }: 2 3 stdenv.mkDerivation rec { 4 + name = "libdrm-2.4.65"; 5 6 src = fetchurl { 7 url = "http://dri.freedesktop.org/libdrm/${name}.tar.bz2"; 8 + sha256 = "71960ac8bde7d710992b1bc8879935e8300a870c36bd06f22412d0447e3d96c4"; 9 }; 10 11 nativeBuildInputs = [ pkgconfig ];
+2 -2
pkgs/development/libraries/libtiff/default.nix
··· 1 { stdenv, fetchurl, pkgconfig, zlib, libjpeg, xz }: 2 3 let 4 - version = "4.0.5"; 5 in 6 stdenv.mkDerivation rec { 7 name = "libtiff-${version}"; ··· 11 [ "ftp://ftp.remotesensing.org/pub/libtiff/tiff-${version}.tar.gz" 12 "http://download.osgeo.org/libtiff/tiff-${version}.tar.gz" 13 ]; 14 - sha256 = "171hgy4mylwmvdm7gp6ffjva81m4j56v3fbqsbfl7avzxn1slpp2"; 15 }; 16 17 outputs = [ "out" "doc" "man" ];
··· 1 { stdenv, fetchurl, pkgconfig, zlib, libjpeg, xz }: 2 3 let 4 + version = "4.0.6"; 5 in 6 stdenv.mkDerivation rec { 7 name = "libtiff-${version}"; ··· 11 [ "ftp://ftp.remotesensing.org/pub/libtiff/tiff-${version}.tar.gz" 12 "http://download.osgeo.org/libtiff/tiff-${version}.tar.gz" 13 ]; 14 + sha256 = "136nf1rj9dp5jgv1p7z4dk0xy3wki1w0vfjbk82f645m0w4samsd"; 15 }; 16 17 outputs = [ "out" "doc" "man" ];
+2 -2
pkgs/development/libraries/libuv/default.nix
··· 1 - { stdenv, lib, fetchFromGitHub, autoconf, automake, libtool, pkgconfig 2 3 , ApplicationServices, CoreServices }: 4 ··· 61 mkWithAutotools = stability: version: sha256: stdenv.mkDerivation { 62 name = mkName stability version; 63 src = mkSrc version sha256; 64 - buildInputs = [ automake autoconf libtool pkgconfig ] 65 ++ stdenv.lib.optionals stdenv.isDarwin [ ApplicationServices CoreServices ]; 66 preConfigure = '' 67 LIBTOOLIZE=libtoolize ./autogen.sh
··· 1 + { stdenv, lib, fetchFromGitHub, autoconf, automake, realLibtool, pkgconfig 2 3 , ApplicationServices, CoreServices }: 4 ··· 61 mkWithAutotools = stability: version: sha256: stdenv.mkDerivation { 62 name = mkName stability version; 63 src = mkSrc version sha256; 64 + buildInputs = [ automake autoconf realLibtool pkgconfig ] 65 ++ stdenv.lib.optionals stdenv.isDarwin [ ApplicationServices CoreServices ]; 66 preConfigure = '' 67 LIBTOOLIZE=libtoolize ./autogen.sh
+9
pkgs/development/libraries/mesa-darwin/default.nix
··· 2 , python, libxml2Python, file, expat, makedepend, xorg, llvm, libffi, libvdpau 3 , enableTextureFloats ? false # Texture floats are patented, see docs/patents.txt 4 , enableExtraFeatures ? false # not maintained 5 }: 6 7 let ··· 22 presentproto 23 libX11 libXext libxcb libXt libxshmfence 24 libffi libvdpau 25 ]; 26 27 postUnpack = '' 28 ln -s darwin $sourceRoot/configs/current 29 ''; 30 31 patches = [
··· 2 , python, libxml2Python, file, expat, makedepend, xorg, llvm, libffi, libvdpau 3 , enableTextureFloats ? false # Texture floats are patented, see docs/patents.txt 4 , enableExtraFeatures ? false # not maintained 5 + , darwin 6 }: 7 8 let ··· 23 presentproto 24 libX11 libXext libxcb libXt libxshmfence 25 libffi libvdpau 26 + ] ++ stdenv.lib.optionals stdenv.isDarwin [ 27 + darwin.apple_sdk.frameworks.OpenGL 28 + darwin.apple_sdk.sdk 29 + darwin.apple_sdk.libs.Xplugin 30 ]; 31 32 postUnpack = '' 33 ln -s darwin $sourceRoot/configs/current 34 + ''; 35 + 36 + preBuild = stdenv.lib.optionalString stdenv.isDarwin '' 37 + substituteInPlace bin/mklib --replace g++ clang++ 38 ''; 39 40 patches = [
+2 -2
pkgs/development/libraries/mesa/default.nix
··· 22 */ 23 24 let 25 - version = "10.6.7"; 26 # this is the default search path for DRI drivers 27 driverLink = "/run/opengl-driver" + stdenv.lib.optionalString stdenv.isi686 "-32"; 28 in ··· 36 "https://launchpad.net/mesa/trunk/${version}/+download/mesa-${version}.tar.xz" 37 "ftp://ftp.freedesktop.org/pub/mesa/${version}/mesa-${version}.tar.xz" 38 ]; 39 - sha256 = "feb1f640b915dada88a7c793dfaff0ae23580f8903f87a6b76469253de0d28d8"; 40 }; 41 42 prePatch = "patchShebangs .";
··· 22 */ 23 24 let 25 + version = "10.6.8"; 26 # this is the default search path for DRI drivers 27 driverLink = "/run/opengl-driver" + stdenv.lib.optionalString stdenv.isi686 "-32"; 28 in ··· 36 "https://launchpad.net/mesa/trunk/${version}/+download/mesa-${version}.tar.xz" 37 "ftp://ftp.freedesktop.org/pub/mesa/${version}/mesa-${version}.tar.xz" 38 ]; 39 + sha256 = "e36ee5ceeadb3966fb5ce5b4cf18322dbb76a4f075558ae49c3bba94f57d58fd"; 40 }; 41 42 prePatch = "patchShebangs .";
+8 -1
pkgs/development/libraries/pcre/default.nix
··· 1 - { stdenv, fetchurl, unicodeSupport ? true, cplusplusSupport ? true 2 , windows ? null 3 }: 4 ··· 11 url = "ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/${name}.tar.bz2"; 12 sha256 = "17bqykp604p7376wj3q2nmjdhrb6v1ny8q08zdwi7qvc02l9wrsi"; 13 }; 14 15 outputs = [ "out" "doc" "man" ]; 16
··· 1 + { stdenv, fetchurl, autoreconfHook, unicodeSupport ? true, cplusplusSupport ? true 2 , windows ? null 3 }: 4 ··· 11 url = "ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/${name}.tar.bz2"; 12 sha256 = "17bqykp604p7376wj3q2nmjdhrb6v1ny8q08zdwi7qvc02l9wrsi"; 13 }; 14 + 15 + nativeBuildInputs = [ autoreconfHook ]; 16 + 17 + # A bundle of fixes which should be removed for 8.38 18 + patchPhase = '' 19 + patch -p0 -i ${./fixes.patch} 20 + ''; 21 22 outputs = [ "out" "doc" "man" ]; 23
+3538
pkgs/development/libraries/pcre/fixes.patch
···
··· 1 + Index: pcre_jit_compile.c 2 + =================================================================== 3 + --- pcre_jit_compile.c (revision 1554) 4 + +++ pcre_jit_compile.c (working copy) 5 + @@ -1064,6 +1064,7 @@ 6 + pcre_uchar *end = NULL; 7 + int private_data_ptr = *private_data_start; 8 + int space, size, bracketlen; 9 + +BOOL repeat_check = TRUE; 10 + 11 + while (cc < ccend) 12 + { 13 + @@ -1071,9 +1072,10 @@ 14 + size = 0; 15 + bracketlen = 0; 16 + if (private_data_ptr > SLJIT_MAX_LOCAL_SIZE) 17 + - return; 18 + + break; 19 + 20 + - if (*cc == OP_ONCE || *cc == OP_ONCE_NC || *cc == OP_BRA || *cc == OP_CBRA || *cc == OP_COND) 21 + + if (repeat_check && (*cc == OP_ONCE || *cc == OP_ONCE_NC || *cc == OP_BRA || *cc == OP_CBRA || *cc == OP_COND)) 22 + + { 23 + if (detect_repeat(common, cc)) 24 + { 25 + /* These brackets are converted to repeats, so no global 26 + @@ -1081,6 +1083,8 @@ 27 + if (cc >= end) 28 + end = bracketend(cc); 29 + } 30 + + } 31 + + repeat_check = TRUE; 32 + 33 + switch(*cc) 34 + { 35 + @@ -1136,6 +1140,13 @@ 36 + bracketlen = 1 + LINK_SIZE + IMM2_SIZE; 37 + break; 38 + 39 + + case OP_BRAZERO: 40 + + case OP_BRAMINZERO: 41 + + case OP_BRAPOSZERO: 42 + + repeat_check = FALSE; 43 + + size = 1; 44 + + break; 45 + + 46 + CASE_ITERATOR_PRIVATE_DATA_1 47 + space = 1; 48 + size = -2; 49 + @@ -1162,12 +1173,17 @@ 50 + size = 1; 51 + break; 52 + 53 + - CASE_ITERATOR_TYPE_PRIVATE_DATA_2B 54 + + case OP_TYPEUPTO: 55 + if (cc[1 + IMM2_SIZE] != OP_ANYNL && cc[1 + IMM2_SIZE] != OP_EXTUNI) 56 + space = 2; 57 + size = 1 + IMM2_SIZE; 58 + break; 59 + 60 + + case OP_TYPEMINUPTO: 61 + + space = 2; 62 + + size = 1 + IMM2_SIZE; 63 + + break; 64 + + 65 + case OP_CLASS: 66 + case OP_NCLASS: 67 + size += 1 + 32 / sizeof(pcre_uchar); 68 + @@ -1316,6 +1332,13 @@ 69 + cc += 1 + LINK_SIZE + IMM2_SIZE; 70 + break; 71 + 72 + + case OP_THEN: 73 + + stack_restore = TRUE; 74 + + if (common->control_head_ptr != 0) 75 + + *needs_control_head = TRUE; 76 + + cc ++; 77 + + break; 78 + + 79 + default: 80 + stack_restore = TRUE; 81 + /* Fall through. */ 82 + @@ -2220,6 +2243,7 @@ 83 + SLJIT_ASSERT_STOP(); 84 + break; 85 + } 86 + + SLJIT_ASSERT(current > (sljit_sw*)current[-1]); 87 + current = (sljit_sw*)current[-1]; 88 + } 89 + return -1; 90 + @@ -3209,7 +3233,7 @@ 91 + bytes[0] = len; 92 + } 93 + 94 + -static int scan_prefix(compiler_common *common, pcre_uchar *cc, pcre_uint32 *chars, pcre_uint8 *bytes, int max_chars) 95 + +static int scan_prefix(compiler_common *common, pcre_uchar *cc, pcre_uint32 *chars, pcre_uint8 *bytes, int max_chars, pcre_uint32 *rec_count) 96 + { 97 + /* Recursive function, which scans prefix literals. */ 98 + BOOL last, any, caseless; 99 + @@ -3227,9 +3251,14 @@ 100 + repeat = 1; 101 + while (TRUE) 102 + { 103 + + if (*rec_count == 0) 104 + + return 0; 105 + + (*rec_count)--; 106 + + 107 + last = TRUE; 108 + any = FALSE; 109 + caseless = FALSE; 110 + + 111 + switch (*cc) 112 + { 113 + case OP_CHARI: 114 + @@ -3291,7 +3320,7 @@ 115 + #ifdef SUPPORT_UTF 116 + if (common->utf && HAS_EXTRALEN(*cc)) len += GET_EXTRALEN(*cc); 117 + #endif 118 + - max_chars = scan_prefix(common, cc + len, chars, bytes, max_chars); 119 + + max_chars = scan_prefix(common, cc + len, chars, bytes, max_chars, rec_count); 120 + if (max_chars == 0) 121 + return consumed; 122 + last = FALSE; 123 + @@ -3314,7 +3343,7 @@ 124 + alternative = cc + GET(cc, 1); 125 + while (*alternative == OP_ALT) 126 + { 127 + - max_chars = scan_prefix(common, alternative + 1 + LINK_SIZE, chars, bytes, max_chars); 128 + + max_chars = scan_prefix(common, alternative + 1 + LINK_SIZE, chars, bytes, max_chars, rec_count); 129 + if (max_chars == 0) 130 + return consumed; 131 + alternative += GET(alternative, 1); 132 + @@ -3556,6 +3585,7 @@ 133 + int range_right = -1, range_len = 3 - 1; 134 + sljit_ub *update_table = NULL; 135 + BOOL in_range; 136 + +pcre_uint32 rec_count; 137 + 138 + for (i = 0; i < MAX_N_CHARS; i++) 139 + { 140 + @@ -3564,7 +3594,8 @@ 141 + bytes[i * MAX_N_BYTES] = 0; 142 + } 143 + 144 + -max = scan_prefix(common, common->start, chars, bytes, MAX_N_CHARS); 145 + +rec_count = 10000; 146 + +max = scan_prefix(common, common->start, chars, bytes, MAX_N_CHARS, &rec_count); 147 + 148 + if (max <= 1) 149 + return FALSE; 150 + @@ -4311,8 +4342,10 @@ 151 + case 4: 152 + if ((ranges[1] - ranges[0]) == (ranges[3] - ranges[2]) 153 + && (ranges[0] | (ranges[2] - ranges[0])) == ranges[2] 154 + + && (ranges[1] & (ranges[2] - ranges[0])) == 0 155 + && is_powerof2(ranges[2] - ranges[0])) 156 + { 157 + + SLJIT_ASSERT((ranges[0] & (ranges[2] - ranges[0])) == 0 && (ranges[2] & ranges[3] & (ranges[2] - ranges[0])) != 0); 158 + OP2(SLJIT_OR, TMP1, 0, TMP1, 0, SLJIT_IMM, ranges[2] - ranges[0]); 159 + if (ranges[2] + 1 != ranges[3]) 160 + { 161 + @@ -4900,9 +4933,10 @@ 162 + if (!check_class_ranges(common, (const pcre_uint8 *)cc, FALSE, TRUE, list)) 163 + { 164 + #ifdef COMPILE_PCRE8 165 + - SLJIT_ASSERT(common->utf); 166 + + jump = NULL; 167 + + if (common->utf) 168 + #endif 169 + - jump = CMP(SLJIT_GREATER, TMP1, 0, SLJIT_IMM, 255); 170 + + jump = CMP(SLJIT_GREATER, TMP1, 0, SLJIT_IMM, 255); 171 + 172 + OP2(SLJIT_AND, TMP2, 0, TMP1, 0, SLJIT_IMM, 0x7); 173 + OP2(SLJIT_LSHR, TMP1, 0, TMP1, 0, SLJIT_IMM, 3); 174 + @@ -4911,7 +4945,10 @@ 175 + OP2(SLJIT_AND | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, TMP2, 0); 176 + add_jump(compiler, list, JUMP(SLJIT_NOT_ZERO)); 177 + 178 + - JUMPHERE(jump); 179 + +#ifdef COMPILE_PCRE8 180 + + if (common->utf) 181 + +#endif 182 + + JUMPHERE(jump); 183 + } 184 + 185 + OP1(SLJIT_MOV, TMP1, 0, TMP3, 0); 186 + @@ -7665,6 +7702,10 @@ 187 + OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0); 188 + } 189 + 190 + + /* Even if the match is empty, we need to reset the control head. */ 191 + + if (needs_control_head) 192 + + OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_SP), common->control_head_ptr, SLJIT_MEM1(STACK_TOP), STACK(stack)); 193 + + 194 + if (opcode == OP_SBRAPOS || opcode == OP_SCBRAPOS) 195 + add_jump(compiler, &emptymatch, CMP(SLJIT_EQUAL, TMP1, 0, STR_PTR, 0)); 196 + 197 + @@ -7692,6 +7733,10 @@ 198 + OP1(SLJIT_MOV, SLJIT_MEM1(TMP2), (framesize + 1) * sizeof(sljit_sw), STR_PTR, 0); 199 + } 200 + 201 + + /* Even if the match is empty, we need to reset the control head. */ 202 + + if (needs_control_head) 203 + + OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_SP), common->control_head_ptr, SLJIT_MEM1(STACK_TOP), STACK(stack)); 204 + + 205 + if (opcode == OP_SBRAPOS || opcode == OP_SCBRAPOS) 206 + add_jump(compiler, &emptymatch, CMP(SLJIT_EQUAL, TMP1, 0, STR_PTR, 0)); 207 + 208 + @@ -7704,9 +7749,6 @@ 209 + } 210 + } 211 + 212 + - if (needs_control_head) 213 + - OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_SP), common->control_head_ptr, SLJIT_MEM1(STACK_TOP), STACK(stack)); 214 + - 215 + JUMPTO(SLJIT_JUMP, loop); 216 + flush_stubs(common); 217 + 218 + @@ -8441,8 +8483,7 @@ 219 + OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), STR_PTR, 0); 220 + } 221 + BACKTRACK_AS(braminzero_backtrack)->matchingpath = LABEL(); 222 + - if (cc[1] > OP_ASSERTBACK_NOT) 223 + - count_match(common); 224 + + count_match(common); 225 + break; 226 + 227 + case OP_ONCE: 228 + @@ -9624,7 +9665,7 @@ 229 + DEFINE_COMPILER; 230 + pcre_uchar *cc = common->start + common->currententry->start; 231 + pcre_uchar *ccbegin = cc + 1 + LINK_SIZE + (*cc == OP_BRA ? 0 : IMM2_SIZE); 232 + -pcre_uchar *ccend = bracketend(cc); 233 + +pcre_uchar *ccend = bracketend(cc) - (1 + LINK_SIZE); 234 + BOOL needs_control_head; 235 + int framesize = get_framesize(common, cc, NULL, TRUE, &needs_control_head); 236 + int private_data_size = get_private_data_copy_length(common, ccbegin, ccend, needs_control_head); 237 + @@ -9648,6 +9689,7 @@ 238 + 239 + sljit_emit_fast_enter(compiler, TMP2, 0); 240 + allocate_stack(common, private_data_size + framesize + alternativesize); 241 + +count_match(common); 242 + OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(private_data_size + framesize + alternativesize - 1), TMP2, 0); 243 + copy_private_data(common, ccbegin, ccend, TRUE, private_data_size + framesize + alternativesize, framesize + alternativesize, needs_control_head); 244 + if (needs_control_head) 245 + @@ -9992,6 +10034,7 @@ 246 + OP1(SLJIT_MOV_UI, TMP1, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, limit_match)); 247 + OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(TMP2), SLJIT_OFFSETOF(struct sljit_stack, base)); 248 + OP1(SLJIT_MOV, STACK_LIMIT, 0, SLJIT_MEM1(TMP2), SLJIT_OFFSETOF(struct sljit_stack, limit)); 249 + +OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 1); 250 + OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_SP), LIMIT_MATCH, TMP1, 0); 251 + 252 + if (mode == JIT_PARTIAL_SOFT_COMPILE) 253 + Index: RunGrepTest 254 + =================================================================== 255 + --- RunGrepTest (revision 1554) 256 + +++ RunGrepTest (working copy) 257 + @@ -512,6 +512,14 @@ 258 + (cd $srcdir; $valgrind $pcregrep --line-offsets '(?<=\Ka)' $builddir/testtemp1grep) >>testtrygrep 2>&1 259 + echo "RC=$?" >>testtrygrep 260 + 261 + +echo "---------------------------- Test 108 ------------------------------" >>testtrygrep 262 + +(cd $srcdir; $valgrind $pcregrep -lq PATTERN ./testdata/grepinput ./testdata/grepinputx) >>testtrygrep 263 + +echo "RC=$?" >>testtrygrep 264 + + 265 + +echo "---------------------------- Test 109 -----------------------------" >>testtrygrep 266 + +(cd $srcdir; $valgrind $pcregrep -cq lazy ./testdata/grepinput*) >>testtrygrep 267 + +echo "RC=$?" >>testtrygrep 268 + + 269 + # Now compare the results. 270 + 271 + $cf $srcdir/testdata/grepoutput testtrygrep 272 + Index: pcre_compile.c 273 + =================================================================== 274 + --- pcre_compile.c (revision 1554) 275 + +++ pcre_compile.c (working copy) 276 + @@ -174,7 +174,7 @@ 277 + -ESC_Z, CHAR_LEFT_SQUARE_BRACKET, 278 + CHAR_BACKSLASH, CHAR_RIGHT_SQUARE_BRACKET, 279 + CHAR_CIRCUMFLEX_ACCENT, CHAR_UNDERSCORE, 280 + - CHAR_GRAVE_ACCENT, 7, 281 + + CHAR_GRAVE_ACCENT, ESC_a, 282 + -ESC_b, 0, 283 + -ESC_d, ESC_e, 284 + ESC_f, 0, 285 + @@ -202,9 +202,9 @@ 286 + /* 68 */ 0, 0, '|', ',', '%', '_', '>', '?', 287 + /* 70 */ 0, 0, 0, 0, 0, 0, 0, 0, 288 + /* 78 */ 0, '`', ':', '#', '@', '\'', '=', '"', 289 + -/* 80 */ 0, 7, -ESC_b, 0, -ESC_d, ESC_e, ESC_f, 0, 290 + +/* 80 */ 0, ESC_a, -ESC_b, 0, -ESC_d, ESC_e, ESC_f, 0, 291 + /* 88 */-ESC_h, 0, 0, '{', 0, 0, 0, 0, 292 + -/* 90 */ 0, 0, -ESC_k, 'l', 0, ESC_n, 0, -ESC_p, 293 + +/* 90 */ 0, 0, -ESC_k, 0, 0, ESC_n, 0, -ESC_p, 294 + /* 98 */ 0, ESC_r, 0, '}', 0, 0, 0, 0, 295 + /* A0 */ 0, '~', -ESC_s, ESC_tee, 0,-ESC_v, -ESC_w, 0, 296 + /* A8 */ 0,-ESC_z, 0, 0, 0, '[', 0, 0, 297 + @@ -219,6 +219,12 @@ 298 + /* F0 */ 0, 0, 0, 0, 0, 0, 0, 0, 299 + /* F8 */ 0, 0, 0, 0, 0, 0, 0, 0 300 + }; 301 + + 302 + +/* We also need a table of characters that may follow \c in an EBCDIC 303 + +environment for characters 0-31. */ 304 + + 305 + +static unsigned char ebcdic_escape_c[] = "@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_"; 306 + + 307 + #endif 308 + 309 + 310 + @@ -458,7 +464,7 @@ 311 + "range out of order in character class\0" 312 + "nothing to repeat\0" 313 + /* 10 */ 314 + - "operand of unlimited repeat could match the empty string\0" /** DEAD **/ 315 + + "internal error: invalid forward reference offset\0" 316 + "internal error: unexpected repeat\0" 317 + "unrecognized character after (? or (?-\0" 318 + "POSIX named classes are supported only within a class\0" 319 + @@ -527,7 +533,11 @@ 320 + "different names for subpatterns of the same number are not allowed\0" 321 + "(*MARK) must have an argument\0" 322 + "this version of PCRE is not compiled with Unicode property support\0" 323 + +#ifndef EBCDIC 324 + "\\c must be followed by an ASCII character\0" 325 + +#else 326 + + "\\c must be followed by a letter or one of [\\]^_?\0" 327 + +#endif 328 + "\\k is not followed by a braced, angle-bracketed, or quoted name\0" 329 + /* 70 */ 330 + "internal error: unknown opcode in find_fixedlength()\0" 331 + @@ -1425,7 +1435,16 @@ 332 + c ^= 0x40; 333 + #else /* EBCDIC coding */ 334 + if (c >= CHAR_a && c <= CHAR_z) c += 64; 335 + - c ^= 0xC0; 336 + + if (c == CHAR_QUESTION_MARK) 337 + + c = ('\\' == 188 && '`' == 74)? 0x5f : 0xff; 338 + + else 339 + + { 340 + + for (i = 0; i < 32; i++) 341 + + { 342 + + if (c == ebcdic_escape_c[i]) break; 343 + + } 344 + + if (i < 32) c = i; else *errorcodeptr = ERR68; 345 + + } 346 + #endif 347 + break; 348 + 349 + @@ -1799,7 +1818,7 @@ 350 + case OP_ASSERTBACK: 351 + case OP_ASSERTBACK_NOT: 352 + do cc += GET(cc, 1); while (*cc == OP_ALT); 353 + - cc += PRIV(OP_lengths)[*cc]; 354 + + cc += 1 + LINK_SIZE; 355 + break; 356 + 357 + /* Skip over things that don't match chars */ 358 + @@ -2487,7 +2506,7 @@ 359 + if (c == OP_BRA || c == OP_BRAPOS || 360 + c == OP_CBRA || c == OP_CBRAPOS || 361 + c == OP_ONCE || c == OP_ONCE_NC || 362 + - c == OP_COND) 363 + + c == OP_COND || c == OP_SCOND) 364 + { 365 + BOOL empty_branch; 366 + if (GET(code, 1) == 0) return TRUE; /* Hit unclosed bracket */ 367 + @@ -3886,11 +3905,11 @@ 368 + The problem in trying to be exactly like Perl is in the handling of escapes. We 369 + have to be sure that [abc[:x\]pqr] is *not* treated as containing a POSIX 370 + class, but [abc[:x\]pqr:]] is (so that an error can be generated). The code 371 + -below handles the special case of \], but does not try to do any other escape 372 + -processing. This makes it different from Perl for cases such as [:l\ower:] 373 + -where Perl recognizes it as the POSIX class "lower" but PCRE does not recognize 374 + -"l\ower". This is a lesser evil than not diagnosing bad classes when Perl does, 375 + -I think. 376 + +below handles the special cases \\ and \], but does not try to do any other 377 + +escape processing. This makes it different from Perl for cases such as 378 + +[:l\ower:] where Perl recognizes it as the POSIX class "lower" but PCRE does 379 + +not recognize "l\ower". This is a lesser evil than not diagnosing bad classes 380 + +when Perl does, I think. 381 + 382 + A user pointed out that PCRE was rejecting [:a[:digit:]] whereas Perl was not. 383 + It seems that the appearance of a nested POSIX class supersedes an apparent 384 + @@ -3917,21 +3936,16 @@ 385 + terminator = *(++ptr); /* compiler warns about "non-constant" initializer. */ 386 + for (++ptr; *ptr != CHAR_NULL; ptr++) 387 + { 388 + - if (*ptr == CHAR_BACKSLASH && ptr[1] == CHAR_RIGHT_SQUARE_BRACKET) 389 + + if (*ptr == CHAR_BACKSLASH && 390 + + (ptr[1] == CHAR_RIGHT_SQUARE_BRACKET || 391 + + ptr[1] == CHAR_BACKSLASH)) 392 + ptr++; 393 + - else if (*ptr == CHAR_RIGHT_SQUARE_BRACKET) return FALSE; 394 + - else 395 + + else if ((*ptr == CHAR_LEFT_SQUARE_BRACKET && ptr[1] == terminator) || 396 + + *ptr == CHAR_RIGHT_SQUARE_BRACKET) return FALSE; 397 + + else if (*ptr == terminator && ptr[1] == CHAR_RIGHT_SQUARE_BRACKET) 398 + { 399 + - if (*ptr == terminator && ptr[1] == CHAR_RIGHT_SQUARE_BRACKET) 400 + - { 401 + - *endptr = ptr; 402 + - return TRUE; 403 + - } 404 + - if (*ptr == CHAR_LEFT_SQUARE_BRACKET && 405 + - (ptr[1] == CHAR_COLON || ptr[1] == CHAR_DOT || 406 + - ptr[1] == CHAR_EQUALS_SIGN) && 407 + - check_posix_syntax(ptr, endptr)) 408 + - return FALSE; 409 + + *endptr = ptr; 410 + + return TRUE; 411 + } 412 + } 413 + return FALSE; 414 + @@ -3985,11 +3999,12 @@ 415 + is called, the partially compiled regex must be temporarily terminated with 416 + OP_END. 417 + 418 + -This function has been extended with the possibility of forward references for 419 + -recursions and subroutine calls. It must also check the list of such references 420 + -for the group we are dealing with. If it finds that one of the recursions in 421 + -the current group is on this list, it adjusts the offset in the list, not the 422 + -value in the reference (which is a group number). 423 + +This function has been extended to cope with forward references for recursions 424 + +and subroutine calls. It must check the list of such references for the 425 + +group we are dealing with. If it finds that one of the recursions in the 426 + +current group is on this list, it does not adjust the value in the reference 427 + +(which is a group number). After the group has been scanned, all the offsets in 428 + +the forward reference list for the group are adjusted. 429 + 430 + Arguments: 431 + group points to the start of the group 432 + @@ -4005,29 +4020,21 @@ 433 + adjust_recurse(pcre_uchar *group, int adjust, BOOL utf, compile_data *cd, 434 + size_t save_hwm_offset) 435 + { 436 + +int offset; 437 + +pcre_uchar *hc; 438 + pcre_uchar *ptr = group; 439 + 440 + while ((ptr = (pcre_uchar *)find_recurse(ptr, utf)) != NULL) 441 + { 442 + - int offset; 443 + - pcre_uchar *hc; 444 + - 445 + - /* See if this recursion is on the forward reference list. If so, adjust the 446 + - reference. */ 447 + - 448 + for (hc = (pcre_uchar *)cd->start_workspace + save_hwm_offset; hc < cd->hwm; 449 + hc += LINK_SIZE) 450 + { 451 + offset = (int)GET(hc, 0); 452 + - if (cd->start_code + offset == ptr + 1) 453 + - { 454 + - PUT(hc, 0, offset + adjust); 455 + - break; 456 + - } 457 + + if (cd->start_code + offset == ptr + 1) break; 458 + } 459 + 460 + - /* Otherwise, adjust the recursion offset if it's after the start of this 461 + - group. */ 462 + + /* If we have not found this recursion on the forward reference list, adjust 463 + + the recursion's offset if it's after the start of this group. */ 464 + 465 + if (hc >= cd->hwm) 466 + { 467 + @@ -4037,6 +4044,15 @@ 468 + 469 + ptr += 1 + LINK_SIZE; 470 + } 471 + + 472 + +/* Now adjust all forward reference offsets for the group. */ 473 + + 474 + +for (hc = (pcre_uchar *)cd->start_workspace + save_hwm_offset; hc < cd->hwm; 475 + + hc += LINK_SIZE) 476 + + { 477 + + offset = (int)GET(hc, 0); 478 + + PUT(hc, 0, offset + adjust); 479 + + } 480 + } 481 + 482 + 483 + @@ -4465,7 +4481,7 @@ 484 + const pcre_uchar *nestptr = NULL; 485 + pcre_uchar *previous = NULL; 486 + pcre_uchar *previous_callout = NULL; 487 + -size_t save_hwm_offset = 0; 488 + +size_t item_hwm_offset = 0; 489 + pcre_uint8 classbits[32]; 490 + 491 + /* We can fish out the UTF-8 setting once and for all into a BOOL, but we 492 + @@ -4623,8 +4639,7 @@ 493 + /* In the real compile phase, just check the workspace used by the forward 494 + reference list. */ 495 + 496 + - else if (cd->hwm > cd->start_workspace + cd->workspace_size - 497 + - WORK_SIZE_SAFETY_MARGIN) 498 + + else if (cd->hwm > cd->start_workspace + cd->workspace_size) 499 + { 500 + *errorcodeptr = ERR52; 501 + goto FAILED; 502 + @@ -4767,6 +4782,7 @@ 503 + zeroreqchar = reqchar; 504 + zeroreqcharflags = reqcharflags; 505 + previous = code; 506 + + item_hwm_offset = cd->hwm - cd->start_workspace; 507 + *code++ = ((options & PCRE_DOTALL) != 0)? OP_ALLANY: OP_ANY; 508 + break; 509 + 510 + @@ -4818,6 +4834,7 @@ 511 + /* Handle a real character class. */ 512 + 513 + previous = code; 514 + + item_hwm_offset = cd->hwm - cd->start_workspace; 515 + 516 + /* PCRE supports POSIX class stuff inside a class. Perl gives an error if 517 + they are encountered at the top level, so we'll do that too. */ 518 + @@ -5195,9 +5212,9 @@ 519 + cd, PRIV(vspace_list)); 520 + continue; 521 + 522 + -#ifdef SUPPORT_UCP 523 + case ESC_p: 524 + case ESC_P: 525 + +#ifdef SUPPORT_UCP 526 + { 527 + BOOL negated; 528 + unsigned int ptype = 0, pdata = 0; 529 + @@ -5211,6 +5228,9 @@ 530 + class_has_8bitchar--; /* Undo! */ 531 + continue; 532 + } 533 + +#else 534 + + *errorcodeptr = ERR45; 535 + + goto FAILED; 536 + #endif 537 + /* Unrecognized escapes are faulted if PCRE is running in its 538 + strict mode. By default, for compatibility with Perl, they are 539 + @@ -5930,7 +5950,7 @@ 540 + { 541 + register int i; 542 + int len = (int)(code - previous); 543 + - size_t base_hwm_offset = save_hwm_offset; 544 + + size_t base_hwm_offset = item_hwm_offset; 545 + pcre_uchar *bralink = NULL; 546 + pcre_uchar *brazeroptr = NULL; 547 + 548 + @@ -5985,7 +6005,7 @@ 549 + if (repeat_max <= 1) /* Covers 0, 1, and unlimited */ 550 + { 551 + *code = OP_END; 552 + - adjust_recurse(previous, 1, utf, cd, save_hwm_offset); 553 + + adjust_recurse(previous, 1, utf, cd, item_hwm_offset); 554 + memmove(previous + 1, previous, IN_UCHARS(len)); 555 + code++; 556 + if (repeat_max == 0) 557 + @@ -6009,7 +6029,7 @@ 558 + { 559 + int offset; 560 + *code = OP_END; 561 + - adjust_recurse(previous, 2 + LINK_SIZE, utf, cd, save_hwm_offset); 562 + + adjust_recurse(previous, 2 + LINK_SIZE, utf, cd, item_hwm_offset); 563 + memmove(previous + 2 + LINK_SIZE, previous, IN_UCHARS(len)); 564 + code += 2 + LINK_SIZE; 565 + *previous++ = OP_BRAZERO + repeat_type; 566 + @@ -6254,6 +6274,12 @@ 567 + while (*scode == OP_ALT); 568 + } 569 + 570 + + /* A conditional group with only one branch has an implicit empty 571 + + alternative branch. */ 572 + + 573 + + if (*bracode == OP_COND && bracode[GET(bracode,1)] != OP_ALT) 574 + + *bracode = OP_SCOND; 575 + + 576 + /* Handle possessive quantifiers. */ 577 + 578 + if (possessive_quantifier) 579 + @@ -6267,11 +6293,11 @@ 580 + { 581 + int nlen = (int)(code - bracode); 582 + *code = OP_END; 583 + - adjust_recurse(bracode, 1 + LINK_SIZE, utf, cd, save_hwm_offset); 584 + + adjust_recurse(bracode, 1 + LINK_SIZE, utf, cd, item_hwm_offset); 585 + memmove(bracode + 1 + LINK_SIZE, bracode, IN_UCHARS(nlen)); 586 + code += 1 + LINK_SIZE; 587 + nlen += 1 + LINK_SIZE; 588 + - *bracode = OP_BRAPOS; 589 + + *bracode = (*bracode == OP_COND)? OP_BRAPOS : OP_SBRAPOS; 590 + *code++ = OP_KETRPOS; 591 + PUTINC(code, 0, nlen); 592 + PUT(bracode, 1, nlen); 593 + @@ -6401,7 +6427,7 @@ 594 + else 595 + { 596 + *code = OP_END; 597 + - adjust_recurse(tempcode, 1 + LINK_SIZE, utf, cd, save_hwm_offset); 598 + + adjust_recurse(tempcode, 1 + LINK_SIZE, utf, cd, item_hwm_offset); 599 + memmove(tempcode + 1 + LINK_SIZE, tempcode, IN_UCHARS(len)); 600 + code += 1 + LINK_SIZE; 601 + len += 1 + LINK_SIZE; 602 + @@ -6450,7 +6476,7 @@ 603 + 604 + default: 605 + *code = OP_END; 606 + - adjust_recurse(tempcode, 1 + LINK_SIZE, utf, cd, save_hwm_offset); 607 + + adjust_recurse(tempcode, 1 + LINK_SIZE, utf, cd, item_hwm_offset); 608 + memmove(tempcode + 1 + LINK_SIZE, tempcode, IN_UCHARS(len)); 609 + code += 1 + LINK_SIZE; 610 + len += 1 + LINK_SIZE; 611 + @@ -6623,7 +6649,7 @@ 612 + newoptions = options; 613 + skipbytes = 0; 614 + bravalue = OP_CBRA; 615 + - save_hwm_offset = cd->hwm - cd->start_workspace; 616 + + item_hwm_offset = cd->hwm - cd->start_workspace; 617 + reset_bracount = FALSE; 618 + 619 + /* Deal with the extended parentheses; all are introduced by '?', and the 620 + @@ -6641,6 +6667,7 @@ 621 + /* ------------------------------------------------------------ */ 622 + case CHAR_VERTICAL_LINE: /* Reset capture count for each branch */ 623 + reset_bracount = TRUE; 624 + + cd->dupgroups = TRUE; /* Record (?| encountered */ 625 + /* Fall through */ 626 + 627 + /* ------------------------------------------------------------ */ 628 + @@ -6741,6 +6768,12 @@ 629 + { 630 + while (IS_DIGIT(*ptr)) 631 + { 632 + + if (recno > INT_MAX / 10 - 1) /* Integer overflow */ 633 + + { 634 + + while (IS_DIGIT(*ptr)) ptr++; 635 + + *errorcodeptr = ERR61; 636 + + goto FAILED; 637 + + } 638 + recno = recno * 10 + (int)(*ptr - CHAR_0); 639 + ptr++; 640 + } 641 + @@ -6769,7 +6802,7 @@ 642 + ptr++; 643 + } 644 + namelen = (int)(ptr - name); 645 + - if (lengthptr != NULL) *lengthptr += IMM2_SIZE; 646 + + if (lengthptr != NULL) skipbytes += IMM2_SIZE; 647 + } 648 + 649 + /* Check the terminator */ 650 + @@ -6875,6 +6908,11 @@ 651 + *errorcodeptr = ERR15; 652 + goto FAILED; 653 + } 654 + + if (recno > INT_MAX / 10 - 1) /* Integer overflow */ 655 + + { 656 + + *errorcodeptr = ERR61; 657 + + goto FAILED; 658 + + } 659 + recno = recno * 10 + name[i] - CHAR_0; 660 + } 661 + if (recno == 0) recno = RREF_ANY; 662 + @@ -7151,7 +7189,8 @@ 663 + if (lengthptr != NULL) 664 + { 665 + named_group *ng; 666 + - 667 + + recno = 0; 668 + + 669 + if (namelen == 0) 670 + { 671 + *errorcodeptr = ERR62; 672 + @@ -7168,20 +7207,6 @@ 673 + goto FAILED; 674 + } 675 + 676 + - /* The name table does not exist in the first pass; instead we must 677 + - scan the list of names encountered so far in order to get the 678 + - number. If the name is not found, set the value to 0 for a forward 679 + - reference. */ 680 + - 681 + - ng = cd->named_groups; 682 + - for (i = 0; i < cd->names_found; i++, ng++) 683 + - { 684 + - if (namelen == ng->length && 685 + - STRNCMP_UC_UC(name, ng->name, namelen) == 0) 686 + - break; 687 + - } 688 + - recno = (i < cd->names_found)? ng->number : 0; 689 + - 690 + /* Count named back references. */ 691 + 692 + if (!is_recurse) cd->namedrefcount++; 693 + @@ -7191,6 +7216,56 @@ 694 + 16-bit data item. */ 695 + 696 + *lengthptr += IMM2_SIZE; 697 + + 698 + + /* If this is a forward reference and we are within a (?|...) group, 699 + + the reference may end up as the number of a group which we are 700 + + currently inside, that is, it could be a recursive reference. In the 701 + + real compile this will be picked up and the reference wrapped with 702 + + OP_ONCE to make it atomic, so we must space in case this occurs. */ 703 + + 704 + + /* In fact, this can happen for a non-forward reference because 705 + + another group with the same number might be created later. This 706 + + issue is fixed "properly" in PCRE2. As PCRE1 is now in maintenance 707 + + only mode, we finesse the bug by allowing more memory always. */ 708 + + 709 + + *lengthptr += 2 + 2*LINK_SIZE; 710 + + 711 + + /* It is even worse than that. The current reference may be to an 712 + + existing named group with a different number (so apparently not 713 + + recursive) but which later on is also attached to a group with the 714 + + current number. This can only happen if $(| has been previous 715 + + encountered. In that case, we allow yet more memory, just in case. 716 + + (Again, this is fixed "properly" in PCRE2. */ 717 + + 718 + + if (cd->dupgroups) *lengthptr += 4 + 4*LINK_SIZE; 719 + + 720 + + /* Otherwise, check for recursion here. The name table does not exist 721 + + in the first pass; instead we must scan the list of names encountered 722 + + so far in order to get the number. If the name is not found, leave 723 + + the value of recno as 0 for a forward reference. */ 724 + + 725 + + else 726 + + { 727 + + ng = cd->named_groups; 728 + + for (i = 0; i < cd->names_found; i++, ng++) 729 + + { 730 + + if (namelen == ng->length && 731 + + STRNCMP_UC_UC(name, ng->name, namelen) == 0) 732 + + { 733 + + open_capitem *oc; 734 + + recno = ng->number; 735 + + if (is_recurse) break; 736 + + for (oc = cd->open_caps; oc != NULL; oc = oc->next) 737 + + { 738 + + if (oc->number == recno) 739 + + { 740 + + oc->flag = TRUE; 741 + + break; 742 + + } 743 + + } 744 + + } 745 + + } 746 + + } 747 + } 748 + 749 + /* In the real compile, search the name table. We check the name 750 + @@ -7237,8 +7312,6 @@ 751 + for (i++; i < cd->names_found; i++) 752 + { 753 + if (STRCMP_UC_UC(slot + IMM2_SIZE, cslot + IMM2_SIZE) != 0) break; 754 + - 755 + - 756 + count++; 757 + cslot += cd->name_entry_size; 758 + } 759 + @@ -7247,6 +7320,7 @@ 760 + { 761 + if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE; 762 + previous = code; 763 + + item_hwm_offset = cd->hwm - cd->start_workspace; 764 + *code++ = ((options & PCRE_CASELESS) != 0)? OP_DNREFI : OP_DNREF; 765 + PUT2INC(code, 0, index); 766 + PUT2INC(code, 0, count); 767 + @@ -7284,9 +7358,14 @@ 768 + 769 + 770 + /* ------------------------------------------------------------ */ 771 + - case CHAR_R: /* Recursion */ 772 + - ptr++; /* Same as (?0) */ 773 + - /* Fall through */ 774 + + case CHAR_R: /* Recursion, same as (?0) */ 775 + + recno = 0; 776 + + if (*(++ptr) != CHAR_RIGHT_PARENTHESIS) 777 + + { 778 + + *errorcodeptr = ERR29; 779 + + goto FAILED; 780 + + } 781 + + goto HANDLE_RECURSION; 782 + 783 + 784 + /* ------------------------------------------------------------ */ 785 + @@ -7323,7 +7402,15 @@ 786 + 787 + recno = 0; 788 + while(IS_DIGIT(*ptr)) 789 + + { 790 + + if (recno > INT_MAX / 10 - 1) /* Integer overflow */ 791 + + { 792 + + while (IS_DIGIT(*ptr)) ptr++; 793 + + *errorcodeptr = ERR61; 794 + + goto FAILED; 795 + + } 796 + recno = recno * 10 + *ptr++ - CHAR_0; 797 + + } 798 + 799 + if (*ptr != (pcre_uchar)terminator) 800 + { 801 + @@ -7360,6 +7447,7 @@ 802 + HANDLE_RECURSION: 803 + 804 + previous = code; 805 + + item_hwm_offset = cd->hwm - cd->start_workspace; 806 + called = cd->start_code; 807 + 808 + /* When we are actually compiling, find the bracket that is being 809 + @@ -7561,7 +7649,11 @@ 810 + previous = NULL; 811 + cd->iscondassert = FALSE; 812 + } 813 + - else previous = code; 814 + + else 815 + + { 816 + + previous = code; 817 + + item_hwm_offset = cd->hwm - cd->start_workspace; 818 + + } 819 + 820 + *code = bravalue; 821 + tempcode = code; 822 + @@ -7809,7 +7901,7 @@ 823 + const pcre_uchar *p; 824 + pcre_uint32 cf; 825 + 826 + - save_hwm_offset = cd->hwm - cd->start_workspace; /* Normally this is set when '(' is read */ 827 + + item_hwm_offset = cd->hwm - cd->start_workspace; /* Normally this is set when '(' is read */ 828 + terminator = (*(++ptr) == CHAR_LESS_THAN_SIGN)? 829 + CHAR_GREATER_THAN_SIGN : CHAR_APOSTROPHE; 830 + 831 + @@ -7838,7 +7930,7 @@ 832 + if (*p != (pcre_uchar)terminator) 833 + { 834 + *errorcodeptr = ERR57; 835 + - break; 836 + + goto FAILED; 837 + } 838 + ptr++; 839 + goto HANDLE_NUMERICAL_RECURSION; 840 + @@ -7853,7 +7945,7 @@ 841 + ptr[1] != CHAR_APOSTROPHE && ptr[1] != CHAR_LEFT_CURLY_BRACKET)) 842 + { 843 + *errorcodeptr = ERR69; 844 + - break; 845 + + goto FAILED; 846 + } 847 + is_recurse = FALSE; 848 + terminator = (*(++ptr) == CHAR_LESS_THAN_SIGN)? 849 + @@ -7877,6 +7969,7 @@ 850 + HANDLE_REFERENCE: 851 + if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE; 852 + previous = code; 853 + + item_hwm_offset = cd->hwm - cd->start_workspace; 854 + *code++ = ((options & PCRE_CASELESS) != 0)? OP_REFI : OP_REF; 855 + PUT2INC(code, 0, recno); 856 + cd->backref_map |= (recno < 32)? (1 << recno) : 1; 857 + @@ -7906,6 +7999,7 @@ 858 + if (!get_ucp(&ptr, &negated, &ptype, &pdata, errorcodeptr)) 859 + goto FAILED; 860 + previous = code; 861 + + item_hwm_offset = cd->hwm - cd->start_workspace; 862 + *code++ = ((escape == ESC_p) != negated)? OP_PROP : OP_NOTPROP; 863 + *code++ = ptype; 864 + *code++ = pdata; 865 + @@ -7946,6 +8040,7 @@ 866 + 867 + { 868 + previous = (escape > ESC_b && escape < ESC_Z)? code : NULL; 869 + + item_hwm_offset = cd->hwm - cd->start_workspace; 870 + *code++ = (!utf && escape == ESC_C)? OP_ALLANY : escape; 871 + } 872 + } 873 + @@ -7989,6 +8084,7 @@ 874 + 875 + ONE_CHAR: 876 + previous = code; 877 + + item_hwm_offset = cd->hwm - cd->start_workspace; 878 + 879 + /* For caseless UTF-8 mode when UCP support is available, check whether 880 + this character has more than one other case. If so, generate a special 881 + @@ -9164,6 +9260,7 @@ 882 + cd->name_entry_size = 0; 883 + cd->name_table = NULL; 884 + cd->dupnames = FALSE; 885 + +cd->dupgroups = FALSE; 886 + cd->namedrefcount = 0; 887 + cd->start_code = cworkspace; 888 + cd->hwm = cworkspace; 889 + @@ -9198,7 +9295,7 @@ 890 + 891 + DPRINTF(("end pre-compile: length=%d workspace=%d\n", length, 892 + (int)(cd->hwm - cworkspace))); 893 + - 894 + + 895 + if (length > MAX_PATTERN_SIZE) 896 + { 897 + errorcode = ERR20; 898 + @@ -9336,6 +9433,16 @@ 899 + int offset, recno; 900 + cd->hwm -= LINK_SIZE; 901 + offset = GET(cd->hwm, 0); 902 + + 903 + + /* Check that the hwm handling hasn't gone wrong. This whole area is 904 + + rewritten in PCRE2 because there are some obscure cases. */ 905 + + 906 + + if (offset == 0 || codestart[offset-1] != OP_RECURSE) 907 + + { 908 + + errorcode = ERR10; 909 + + break; 910 + + } 911 + + 912 + recno = GET(codestart, offset); 913 + if (recno != prev_recno) 914 + { 915 + @@ -9366,7 +9473,7 @@ 916 + "const" attribute if the cast (pcre_uchar *)codestart is used directly in the 917 + function call. */ 918 + 919 + -if ((options & PCRE_NO_AUTO_POSSESS) == 0) 920 + +if (errorcode == 0 && (options & PCRE_NO_AUTO_POSSESS) == 0) 921 + { 922 + pcre_uchar *temp = (pcre_uchar *)codestart; 923 + auto_possessify(temp, utf, cd); 924 + @@ -9380,7 +9487,7 @@ 925 + exceptional ones forgo this. We scan the pattern to check that they are fixed 926 + length, and set their lengths. */ 927 + 928 + -if (cd->check_lookbehind) 929 + +if (errorcode == 0 && cd->check_lookbehind) 930 + { 931 + pcre_uchar *cc = (pcre_uchar *)codestart; 932 + 933 + @@ -9593,4 +9700,3 @@ 934 + } 935 + 936 + /* End of pcre_compile.c */ 937 + - 938 + Index: ChangeLog 939 + =================================================================== 940 + --- ChangeLog (revision 1554) 941 + +++ ChangeLog (working copy) 942 + @@ -1,6 +1,162 @@ 943 + ChangeLog for PCRE 944 + ------------------ 945 + 946 + +Note that the PCRE 8.xx series (PCRE1) is now in a bugfix-only state. All 947 + +development is happening in the PCRE2 10.xx series. 948 + + 949 + +Version 8.38 xx-xxx-xxxx 950 + +------------------------ 951 + + 952 + +1. If a group that contained a recursive back reference also contained a 953 + + forward reference subroutine call followed by a non-forward-reference 954 + + subroutine call, for example /.((?2)(?R)\1)()/, pcre2_compile() failed to 955 + + compile correct code, leading to undefined behaviour or an internally 956 + + detected error. This bug was discovered by the LLVM fuzzer. 957 + + 958 + +2. Quantification of certain items (e.g. atomic back references) could cause 959 + + incorrect code to be compiled when recursive forward references were 960 + + involved. For example, in this pattern: /(?1)()((((((\1++))\x85)+)|))/. 961 + + This bug was discovered by the LLVM fuzzer. 962 + + 963 + +3. A repeated conditional group whose condition was a reference by name caused 964 + + a buffer overflow if there was more than one group with the given name. 965 + + This bug was discovered by the LLVM fuzzer. 966 + + 967 + +4. A recursive back reference by name within a group that had the same name as 968 + + another group caused a buffer overflow. For example: 969 + + /(?J)(?'d'(?'d'\g{d}))/. This bug was discovered by the LLVM fuzzer. 970 + + 971 + +5. A forward reference by name to a group whose number is the same as the 972 + + current group, for example in this pattern: /(?|(\k'Pm')|(?'Pm'))/, caused 973 + + a buffer overflow at compile time. This bug was discovered by the LLVM 974 + + fuzzer. 975 + + 976 + +6. A lookbehind assertion within a set of mutually recursive subpatterns could 977 + + provoke a buffer overflow. This bug was discovered by the LLVM fuzzer. 978 + + 979 + +7. Another buffer overflow bug involved duplicate named groups with a 980 + + reference between their definition, with a group that reset capture 981 + + numbers, for example: /(?J:(?|(?'R')(\k'R')|((?'R'))))/. This has been 982 + + fixed by always allowing for more memory, even if not needed. (A proper fix 983 + + is implemented in PCRE2, but it involves more refactoring.) 984 + + 985 + +8. There was no check for integer overflow in subroutine calls such as (?123). 986 + + 987 + +9. The table entry for \l in EBCDIC environments was incorrect, leading to its 988 + + being treated as a literal 'l' instead of causing an error. 989 + + 990 + +10. There was a buffer overflow if pcre_exec() was called with an ovector of 991 + + size 1. This bug was found by american fuzzy lop. 992 + + 993 + +11. If a non-capturing group containing a conditional group that could match 994 + + an empty string was repeated, it was not identified as matching an empty 995 + + string itself. For example: /^(?:(?(1)x|)+)+$()/. 996 + + 997 + +12. In an EBCDIC environment, pcretest was mishandling the escape sequences 998 + + \a and \e in test subject lines. 999 + + 1000 + +13. In an EBCDIC environment, \a in a pattern was converted to the ASCII 1001 + + instead of the EBCDIC value. 1002 + + 1003 + +14. The handling of \c in an EBCDIC environment has been revised so that it is 1004 + + now compatible with the specification in Perl's perlebcdic page. 1005 + + 1006 + +15. The EBCDIC character 0x41 is a non-breaking space, equivalent to 0xa0 in 1007 + + ASCII/Unicode. This has now been added to the list of characters that are 1008 + + recognized as white space in EBCDIC. 1009 + + 1010 + +16. When PCRE was compiled without UCP support, the use of \p and \P gave an 1011 + + error (correctly) when used outside a class, but did not give an error 1012 + + within a class. 1013 + + 1014 + +17. \h within a class was incorrectly compiled in EBCDIC environments. 1015 + + 1016 + +18. A pattern with an unmatched closing parenthesis that contained a backward 1017 + + assertion which itself contained a forward reference caused buffer 1018 + + overflow. And example pattern is: /(?=di(?<=(?1))|(?=(.))))/. 1019 + + 1020 + +19. JIT should return with error when the compiled pattern requires more stack 1021 + + space than the maximum. 1022 + + 1023 + +20. A possessively repeated conditional group that could match an empty string, 1024 + + for example, /(?(R))*+/, was incorrectly compiled. 1025 + + 1026 + +21. Fix infinite recursion in the JIT compiler when certain patterns such as 1027 + + /(?:|a|){100}x/ are analysed. 1028 + + 1029 + +22. Some patterns with character classes involving [: and \\ were incorrectly 1030 + + compiled and could cause reading from uninitialized memory or an incorrect 1031 + + error diagnosis. 1032 + + 1033 + +23. Pathological patterns containing many nested occurrences of [: caused 1034 + + pcre_compile() to run for a very long time. 1035 + + 1036 + +24. A conditional group with only one branch has an implicit empty alternative 1037 + + branch and must therefore be treated as potentially matching an empty 1038 + + string. 1039 + + 1040 + +25. If (?R was followed by - or + incorrect behaviour happened instead of a 1041 + + diagnostic. 1042 + + 1043 + +26. Arrange to give up on finding the minimum matching length for overly 1044 + + complex patterns. 1045 + + 1046 + +27. Similar to (4) above: in a pattern with duplicated named groups and an 1047 + + occurrence of (?| it is possible for an apparently non-recursive back 1048 + + reference to become recursive if a later named group with the relevant 1049 + + number is encountered. This could lead to a buffer overflow. Wen Guanxing 1050 + + from Venustech ADLAB discovered this bug. 1051 + + 1052 + +28. If pcregrep was given the -q option with -c or -l, or when handling a 1053 + + binary file, it incorrectly wrote output to stdout. 1054 + + 1055 + +29. The JIT compiler did not restore the control verb head in case of *THEN 1056 + + control verbs. This issue was found by Karl Skomski with a custom LLVM 1057 + + fuzzer. 1058 + + 1059 + +30. Error messages for syntax errors following \g and \k were giving inaccurate 1060 + + offsets in the pattern. 1061 + + 1062 + +31. Added a check for integer overflow in conditions (?(<digits>) and 1063 + + (?(R<digits>). This omission was discovered by Karl Skomski with the LLVM 1064 + + fuzzer. 1065 + + 1066 + +32. Handling recursive references such as (?2) when the reference is to a group 1067 + + later in the pattern uses code that is very hacked about and error-prone. 1068 + + It has been re-written for PCRE2. Here in PCRE1, a check has been added to 1069 + + give an internal error if it is obvious that compiling has gone wrong. 1070 + + 1071 + +33. The JIT compiler should not check repeats after a {0,1} repeat byte code. 1072 + + This issue was found by Karl Skomski with a custom LLVM fuzzer. 1073 + + 1074 + +34. The JIT compiler should restore the control chain for empty possessive 1075 + + repeats. This issue was found by Karl Skomski with a custom LLVM fuzzer. 1076 + + 1077 + +35. Match limit check added to JIT recursion. This issue was found by Karl 1078 + + Skomski with a custom LLVM fuzzer. 1079 + + 1080 + +36. Yet another case similar to 27 above has been circumvented by an 1081 + + unconditional allocation of extra memory. This issue is fixed "properly" in 1082 + + PCRE2 by refactoring the way references are handled. Wen Guanxing 1083 + + from Venustech ADLAB discovered this bug. 1084 + + 1085 + +37. Fix two assertion fails in JIT. These issues were found by Karl Skomski 1086 + + with a custom LLVM fuzzer. 1087 + + 1088 + +38. Fixed a corner case of range optimization in JIT. 1089 + + 1090 + +39. An incorrect error "overran compiling workspace" was given if there were 1091 + + exactly enough group forward references such that the last one extended 1092 + + into the workspace safety margin. The next one would have expanded the 1093 + + workspace. The test for overflow was not including the safety margin. 1094 + + 1095 + +40. A match limit issue is fixed in JIT which was found by Karl Skomski 1096 + + with a custom LLVM fuzzer. 1097 + + 1098 + +41. Remove the use of /dev/null in testdata/testinput2, because it doesn't 1099 + + work under Windows. (Why has it taken so long for anyone to notice?) 1100 + + 1101 + + 1102 + Version 8.37 28-April-2015 1103 + -------------------------- 1104 + 1105 + Index: pcretest.c 1106 + =================================================================== 1107 + --- pcretest.c (revision 1554) 1108 + +++ pcretest.c (working copy) 1109 + @@ -4621,9 +4621,9 @@ 1110 + 1111 + else switch ((c = *p++)) 1112 + { 1113 + - case 'a': c = 7; break; 1114 + + case 'a': c = CHAR_BEL; break; 1115 + case 'b': c = '\b'; break; 1116 + - case 'e': c = 27; break; 1117 + + case 'e': c = CHAR_ESC; break; 1118 + case 'f': c = '\f'; break; 1119 + case 'n': c = '\n'; break; 1120 + case 'r': c = '\r'; break; 1121 + Index: sljit/sljitLir.c 1122 + =================================================================== 1123 + --- sljit/sljitLir.c (revision 1554) 1124 + +++ sljit/sljitLir.c (working copy) 1125 + @@ -845,8 +845,8 @@ 1126 + } 1127 + 1128 + static SLJIT_CONST char* op0_names[] = { 1129 + - (char*)"breakpoint", (char*)"nop", 1130 + - (char*)"lumul", (char*)"lsmul", (char*)"ludiv", (char*)"lsdiv", 1131 + + (char*)"breakpoint", (char*)"nop", (char*)"lumul", (char*)"lsmul", 1132 + + (char*)"udivmod", (char*)"sdivmod", (char*)"udivi", (char*)"sdivi" 1133 + }; 1134 + 1135 + static SLJIT_CONST char* op1_names[] = { 1136 + @@ -1036,7 +1036,7 @@ 1137 + { 1138 + #if (defined SLJIT_ARGUMENT_CHECKS && SLJIT_ARGUMENT_CHECKS) 1139 + CHECK_ARGUMENT((op >= SLJIT_BREAKPOINT && op <= SLJIT_LSMUL) 1140 + - || ((op & ~SLJIT_INT_OP) >= SLJIT_LUDIV && (op & ~SLJIT_INT_OP) <= SLJIT_LSDIV)); 1141 + + || ((op & ~SLJIT_INT_OP) >= SLJIT_UDIVMOD && (op & ~SLJIT_INT_OP) <= SLJIT_SDIVI)); 1142 + CHECK_ARGUMENT(op < SLJIT_LUMUL || compiler->scratches >= 2); 1143 + #endif 1144 + #if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) 1145 + @@ -1447,6 +1447,8 @@ 1146 + 1147 + static SLJIT_INLINE CHECK_RETURN_TYPE check_sljit_get_local_base(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw offset) 1148 + { 1149 + + SLJIT_UNUSED_ARG(offset); 1150 + + 1151 + #if (defined SLJIT_ARGUMENT_CHECKS && SLJIT_ARGUMENT_CHECKS) 1152 + FUNCTION_CHECK_DST(dst, dstw); 1153 + #endif 1154 + @@ -1462,6 +1464,8 @@ 1155 + 1156 + static SLJIT_INLINE CHECK_RETURN_TYPE check_sljit_emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw init_value) 1157 + { 1158 + + SLJIT_UNUSED_ARG(init_value); 1159 + + 1160 + #if (defined SLJIT_ARGUMENT_CHECKS && SLJIT_ARGUMENT_CHECKS) 1161 + FUNCTION_CHECK_DST(dst, dstw); 1162 + #endif 1163 + Index: sljit/sljitNativeSPARC_common.c 1164 + =================================================================== 1165 + --- sljit/sljitNativeSPARC_common.c (revision 1554) 1166 + +++ sljit/sljitNativeSPARC_common.c (working copy) 1167 + @@ -777,20 +777,25 @@ 1168 + #else 1169 + #error "Implementation required" 1170 + #endif 1171 + - case SLJIT_LUDIV: 1172 + - case SLJIT_LSDIV: 1173 + + case SLJIT_UDIVMOD: 1174 + + case SLJIT_SDIVMOD: 1175 + + case SLJIT_UDIVI: 1176 + + case SLJIT_SDIVI: 1177 + + SLJIT_COMPILE_ASSERT((SLJIT_UDIVMOD & 0x2) == 0 && SLJIT_UDIVI - 0x2 == SLJIT_UDIVMOD, bad_div_opcode_assignments); 1178 + #if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32) 1179 + - if (op == SLJIT_LUDIV) 1180 + + if ((op | 0x2) == SLJIT_UDIVI) 1181 + FAIL_IF(push_inst(compiler, WRY | S1(0), MOVABLE_INS)); 1182 + else { 1183 + FAIL_IF(push_inst(compiler, SRA | D(TMP_REG1) | S1(SLJIT_R0) | IMM(31), DR(TMP_REG1))); 1184 + FAIL_IF(push_inst(compiler, WRY | S1(TMP_REG1), MOVABLE_INS)); 1185 + } 1186 + - FAIL_IF(push_inst(compiler, OR | D(TMP_REG2) | S1(0) | S2(SLJIT_R0), DR(TMP_REG2))); 1187 + - FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? UDIV : SDIV) | D(SLJIT_R0) | S1(SLJIT_R0) | S2(SLJIT_R1), DR(SLJIT_R0))); 1188 + + if (op <= SLJIT_SDIVMOD) 1189 + + FAIL_IF(push_inst(compiler, OR | D(TMP_REG2) | S1(0) | S2(SLJIT_R0), DR(TMP_REG2))); 1190 + + FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_UDIVI ? UDIV : SDIV) | D(SLJIT_R0) | S1(SLJIT_R0) | S2(SLJIT_R1), DR(SLJIT_R0))); 1191 + + if (op >= SLJIT_UDIVI) 1192 + + return SLJIT_SUCCESS; 1193 + FAIL_IF(push_inst(compiler, SMUL | D(SLJIT_R1) | S1(SLJIT_R0) | S2(SLJIT_R1), DR(SLJIT_R1))); 1194 + - FAIL_IF(push_inst(compiler, SUB | D(SLJIT_R1) | S1(TMP_REG2) | S2(SLJIT_R1), DR(SLJIT_R1))); 1195 + - return SLJIT_SUCCESS; 1196 + + return push_inst(compiler, SUB | D(SLJIT_R1) | S1(TMP_REG2) | S2(SLJIT_R1), DR(SLJIT_R1)); 1197 + #else 1198 + #error "Implementation required" 1199 + #endif 1200 + Index: sljit/sljitNativeMIPS_common.c 1201 + =================================================================== 1202 + --- sljit/sljitNativeMIPS_common.c (revision 1554) 1203 + +++ sljit/sljitNativeMIPS_common.c (working copy) 1204 + @@ -1053,8 +1053,11 @@ 1205 + #endif 1206 + FAIL_IF(push_inst(compiler, MFLO | D(SLJIT_R0), DR(SLJIT_R0))); 1207 + return push_inst(compiler, MFHI | D(SLJIT_R1), DR(SLJIT_R1)); 1208 + - case SLJIT_LUDIV: 1209 + - case SLJIT_LSDIV: 1210 + + case SLJIT_UDIVMOD: 1211 + + case SLJIT_SDIVMOD: 1212 + + case SLJIT_UDIVI: 1213 + + case SLJIT_SDIVI: 1214 + + SLJIT_COMPILE_ASSERT((SLJIT_UDIVMOD & 0x2) == 0 && SLJIT_UDIVI - 0x2 == SLJIT_UDIVMOD, bad_div_opcode_assignments); 1215 + #if !(defined SLJIT_MIPS_R1 && SLJIT_MIPS_R1) 1216 + FAIL_IF(push_inst(compiler, NOP, UNMOVABLE_INS)); 1217 + FAIL_IF(push_inst(compiler, NOP, UNMOVABLE_INS)); 1218 + @@ -1062,15 +1065,15 @@ 1219 + 1220 + #if (defined SLJIT_CONFIG_MIPS_64 && SLJIT_CONFIG_MIPS_64) 1221 + if (int_op) 1222 + - FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? DIVU : DIV) | S(SLJIT_R0) | T(SLJIT_R1), MOVABLE_INS)); 1223 + + FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_UDIVI ? DIVU : DIV) | S(SLJIT_R0) | T(SLJIT_R1), MOVABLE_INS)); 1224 + else 1225 + - FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? DDIVU : DDIV) | S(SLJIT_R0) | T(SLJIT_R1), MOVABLE_INS)); 1226 + + FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_UDIVI ? DDIVU : DDIV) | S(SLJIT_R0) | T(SLJIT_R1), MOVABLE_INS)); 1227 + #else 1228 + - FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? DIVU : DIV) | S(SLJIT_R0) | T(SLJIT_R1), MOVABLE_INS)); 1229 + + FAIL_IF(push_inst(compiler, ((op | 0x2) == SLJIT_UDIVI ? DIVU : DIV) | S(SLJIT_R0) | T(SLJIT_R1), MOVABLE_INS)); 1230 + #endif 1231 + 1232 + FAIL_IF(push_inst(compiler, MFLO | D(SLJIT_R0), DR(SLJIT_R0))); 1233 + - return push_inst(compiler, MFHI | D(SLJIT_R1), DR(SLJIT_R1)); 1234 + + return (op >= SLJIT_UDIVI) ? SLJIT_SUCCESS : push_inst(compiler, MFHI | D(SLJIT_R1), DR(SLJIT_R1)); 1235 + } 1236 + 1237 + return SLJIT_SUCCESS; 1238 + Index: sljit/sljitNativeARM_32.c 1239 + =================================================================== 1240 + --- sljit/sljitNativeARM_32.c (revision 1554) 1241 + +++ sljit/sljitNativeARM_32.c (working copy) 1242 + @@ -1833,18 +1833,33 @@ 1243 + | (reg_map[SLJIT_R0] << 8) 1244 + | reg_map[TMP_REG1]); 1245 + #endif 1246 + - case SLJIT_LUDIV: 1247 + - case SLJIT_LSDIV: 1248 + - if (compiler->scratches >= 3) 1249 + + case SLJIT_UDIVMOD: 1250 + + case SLJIT_SDIVMOD: 1251 + + case SLJIT_UDIVI: 1252 + + case SLJIT_SDIVI: 1253 + + SLJIT_COMPILE_ASSERT((SLJIT_UDIVMOD & 0x2) == 0 && SLJIT_UDIVI - 0x2 == SLJIT_UDIVMOD, bad_div_opcode_assignments); 1254 + + SLJIT_COMPILE_ASSERT(reg_map[2] == 1 && reg_map[3] == 2, bad_register_mapping); 1255 + + 1256 + + if ((op >= SLJIT_UDIVI) && (compiler->scratches >= 3)) { 1257 + FAIL_IF(push_inst(compiler, 0xe52d2008 /* str r2, [sp, #-8]! */)); 1258 + + FAIL_IF(push_inst(compiler, 0xe58d1004 /* str r1, [sp, #4] */)); 1259 + + } 1260 + + else if ((op >= SLJIT_UDIVI) || (compiler->scratches >= 3)) 1261 + + FAIL_IF(push_inst(compiler, 0xe52d0008 | (op >= SLJIT_UDIVI ? 0x1000 : 0x2000) /* str r1/r2, [sp, #-8]! */)); 1262 + + 1263 + #if defined(__GNUC__) 1264 + FAIL_IF(sljit_emit_ijump(compiler, SLJIT_FAST_CALL, SLJIT_IMM, 1265 + - (op == SLJIT_LUDIV ? SLJIT_FUNC_OFFSET(__aeabi_uidivmod) : SLJIT_FUNC_OFFSET(__aeabi_idivmod)))); 1266 + + ((op | 0x2) == SLJIT_UDIVI ? SLJIT_FUNC_OFFSET(__aeabi_uidivmod) : SLJIT_FUNC_OFFSET(__aeabi_idivmod)))); 1267 + #else 1268 + #error "Software divmod functions are needed" 1269 + #endif 1270 + - if (compiler->scratches >= 3) 1271 + - return push_inst(compiler, 0xe49d2008 /* ldr r2, [sp], #8 */); 1272 + + 1273 + + if ((op >= SLJIT_UDIVI) && (compiler->scratches >= 3)) { 1274 + + FAIL_IF(push_inst(compiler, 0xe59d1004 /* ldr r1, [sp, #4] */)); 1275 + + FAIL_IF(push_inst(compiler, 0xe49d2008 /* ldr r2, [sp], #8 */)); 1276 + + } 1277 + + else if ((op >= SLJIT_UDIVI) || (compiler->scratches >= 3)) 1278 + + return push_inst(compiler, 0xe49d0008 | (op >= SLJIT_UDIVI ? 0x1000 : 0x2000) /* ldr r1/r2, [sp], #8 */); 1279 + return SLJIT_SUCCESS; 1280 + } 1281 + 1282 + Index: sljit/sljitLir.h 1283 + =================================================================== 1284 + --- sljit/sljitLir.h (revision 1554) 1285 + +++ sljit/sljitLir.h (working copy) 1286 + @@ -687,7 +687,7 @@ 1287 + #define SLJIT_OP0_BASE 0 1288 + 1289 + /* Flags: - (never set any flags) 1290 + - Note: breakpoint instruction is not supported by all architectures (namely ppc) 1291 + + Note: breakpoint instruction is not supported by all architectures (e.g. ppc) 1292 + It falls back to SLJIT_NOP in those cases. */ 1293 + #define SLJIT_BREAKPOINT (SLJIT_OP0_BASE + 0) 1294 + /* Flags: - (never set any flags) 1295 + @@ -696,24 +696,42 @@ 1296 + #define SLJIT_NOP (SLJIT_OP0_BASE + 1) 1297 + /* Flags: - (may destroy flags) 1298 + Unsigned multiplication of SLJIT_R0 and SLJIT_R1. 1299 + - Result goes to SLJIT_R1:SLJIT_R0 (high:low) word */ 1300 + + Result is placed into SLJIT_R1:SLJIT_R0 (high:low) word */ 1301 + #define SLJIT_LUMUL (SLJIT_OP0_BASE + 2) 1302 + /* Flags: - (may destroy flags) 1303 + Signed multiplication of SLJIT_R0 and SLJIT_R1. 1304 + - Result goes to SLJIT_R1:SLJIT_R0 (high:low) word */ 1305 + + Result is placed into SLJIT_R1:SLJIT_R0 (high:low) word */ 1306 + #define SLJIT_LSMUL (SLJIT_OP0_BASE + 3) 1307 + /* Flags: I - (may destroy flags) 1308 + Unsigned divide of the value in SLJIT_R0 by the value in SLJIT_R1. 1309 + - The result is placed in SLJIT_R0 and the remainder goes to SLJIT_R1. 1310 + - Note: if SLJIT_R1 contains 0, the behaviour is undefined. */ 1311 + -#define SLJIT_LUDIV (SLJIT_OP0_BASE + 4) 1312 + -#define SLJIT_ILUDIV (SLJIT_LUDIV | SLJIT_INT_OP) 1313 + + The result is placed into SLJIT_R0 and the remainder into SLJIT_R1. 1314 + + Note: if SLJIT_R1 is 0, the behaviour is undefined. */ 1315 + +#define SLJIT_UDIVMOD (SLJIT_OP0_BASE + 4) 1316 + +#define SLJIT_IUDIVMOD (SLJIT_UDIVMOD | SLJIT_INT_OP) 1317 + /* Flags: I - (may destroy flags) 1318 + Signed divide of the value in SLJIT_R0 by the value in SLJIT_R1. 1319 + - The result is placed in SLJIT_R0 and the remainder goes to SLJIT_R1. 1320 + - Note: if SLJIT_R1 contains 0, the behaviour is undefined. */ 1321 + -#define SLJIT_LSDIV (SLJIT_OP0_BASE + 5) 1322 + -#define SLJIT_ILSDIV (SLJIT_LSDIV | SLJIT_INT_OP) 1323 + + The result is placed into SLJIT_R0 and the remainder into SLJIT_R1. 1324 + + Note: if SLJIT_R1 is 0, the behaviour is undefined. 1325 + + Note: if SLJIT_R1 is -1 and SLJIT_R0 is integer min (0x800..00), 1326 + + the behaviour is undefined. */ 1327 + +#define SLJIT_SDIVMOD (SLJIT_OP0_BASE + 5) 1328 + +#define SLJIT_ISDIVMOD (SLJIT_SDIVMOD | SLJIT_INT_OP) 1329 + +/* Flags: I - (may destroy flags) 1330 + + Unsigned divide of the value in SLJIT_R0 by the value in SLJIT_R1. 1331 + + The result is placed into SLJIT_R0. SLJIT_R1 preserves its value. 1332 + + Note: if SLJIT_R1 is 0, the behaviour is undefined. 1333 + + Note: SLJIT_SDIV is single precision divide. */ 1334 + +#define SLJIT_UDIVI (SLJIT_OP0_BASE + 6) 1335 + +#define SLJIT_IUDIVI (SLJIT_UDIVI | SLJIT_INT_OP) 1336 + +/* Flags: I - (may destroy flags) 1337 + + Signed divide of the value in SLJIT_R0 by the value in SLJIT_R1. 1338 + + The result is placed into SLJIT_R0. SLJIT_R1 preserves its value. 1339 + + Note: if SLJIT_R1 is 0, the behaviour is undefined. 1340 + + Note: if SLJIT_R1 is -1 and SLJIT_R0 is integer min (0x800..00), 1341 + + the behaviour is undefined. 1342 + + Note: SLJIT_SDIV is single precision divide. */ 1343 + +#define SLJIT_SDIVI (SLJIT_OP0_BASE + 7) 1344 + +#define SLJIT_ISDIVI (SLJIT_SDIVI | SLJIT_INT_OP) 1345 + 1346 + SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op); 1347 + 1348 + @@ -851,34 +869,6 @@ 1349 + sljit_si src1, sljit_sw src1w, 1350 + sljit_si src2, sljit_sw src2w); 1351 + 1352 + -/* The following function is a helper function for sljit_emit_op_custom. 1353 + - It returns with the real machine register index ( >=0 ) of any SLJIT_R, 1354 + - SLJIT_S and SLJIT_SP registers. 1355 + - 1356 + - Note: it returns with -1 for virtual registers (only on x86-32). */ 1357 + - 1358 + -SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg); 1359 + - 1360 + -/* The following function is a helper function for sljit_emit_op_custom. 1361 + - It returns with the real machine register index of any SLJIT_FLOAT register. 1362 + - 1363 + - Note: the index is always an even number on ARM (except ARM-64), MIPS, and SPARC. */ 1364 + - 1365 + -SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_float_register_index(sljit_si reg); 1366 + - 1367 + -/* Any instruction can be inserted into the instruction stream by 1368 + - sljit_emit_op_custom. It has a similar purpose as inline assembly. 1369 + - The size parameter must match to the instruction size of the target 1370 + - architecture: 1371 + - 1372 + - x86: 0 < size <= 15. The instruction argument can be byte aligned. 1373 + - Thumb2: if size == 2, the instruction argument must be 2 byte aligned. 1374 + - if size == 4, the instruction argument must be 4 byte aligned. 1375 + - Otherwise: size must be 4 and instruction argument must be 4 byte aligned. */ 1376 + - 1377 + -SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler, 1378 + - void *instruction, sljit_si size); 1379 + - 1380 + /* Returns with non-zero if fpu is available. */ 1381 + 1382 + SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_is_fpu_available(void); 1383 + @@ -1196,4 +1186,64 @@ 1384 + 1385 + #endif /* !(defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL) */ 1386 + 1387 + +/* --------------------------------------------------------------------- */ 1388 + +/* CPU specific functions */ 1389 + +/* --------------------------------------------------------------------- */ 1390 + + 1391 + +/* The following function is a helper function for sljit_emit_op_custom. 1392 + + It returns with the real machine register index ( >=0 ) of any SLJIT_R, 1393 + + SLJIT_S and SLJIT_SP registers. 1394 + + 1395 + + Note: it returns with -1 for virtual registers (only on x86-32). */ 1396 + + 1397 + +SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg); 1398 + + 1399 + +/* The following function is a helper function for sljit_emit_op_custom. 1400 + + It returns with the real machine register index of any SLJIT_FLOAT register. 1401 + + 1402 + + Note: the index is always an even number on ARM (except ARM-64), MIPS, and SPARC. */ 1403 + + 1404 + +SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_float_register_index(sljit_si reg); 1405 + + 1406 + +/* Any instruction can be inserted into the instruction stream by 1407 + + sljit_emit_op_custom. It has a similar purpose as inline assembly. 1408 + + The size parameter must match to the instruction size of the target 1409 + + architecture: 1410 + + 1411 + + x86: 0 < size <= 15. The instruction argument can be byte aligned. 1412 + + Thumb2: if size == 2, the instruction argument must be 2 byte aligned. 1413 + + if size == 4, the instruction argument must be 4 byte aligned. 1414 + + Otherwise: size must be 4 and instruction argument must be 4 byte aligned. */ 1415 + + 1416 + +SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler, 1417 + + void *instruction, sljit_si size); 1418 + + 1419 + +#if (defined SLJIT_CONFIG_X86 && SLJIT_CONFIG_X86) 1420 + + 1421 + +/* Returns with non-zero if sse2 is available. */ 1422 + + 1423 + +SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_x86_is_sse2_available(void); 1424 + + 1425 + +/* Returns with non-zero if cmov instruction is available. */ 1426 + + 1427 + +SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_x86_is_cmov_available(void); 1428 + + 1429 + +/* Emit a conditional mov instruction on x86 CPUs. This instruction 1430 + + moves src to destination, if the condition is satisfied. Unlike 1431 + + other arithmetic instructions, destination must be a register. 1432 + + Before such instructions are emitted, cmov support should be 1433 + + checked by sljit_x86_is_cmov_available function. 1434 + + type must be between SLJIT_EQUAL and SLJIT_S_ORDERED 1435 + + dst_reg must be a valid register and it can be combined 1436 + + with SLJIT_INT_OP to perform 32 bit arithmetic 1437 + + Flags: I - (never set any flags) 1438 + + */ 1439 + + 1440 + +SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_x86_emit_cmov(struct sljit_compiler *compiler, 1441 + + sljit_si type, 1442 + + sljit_si dst_reg, 1443 + + sljit_si src, sljit_sw srcw); 1444 + + 1445 + +#endif 1446 + + 1447 + #endif /* _SLJIT_LIR_H_ */ 1448 + Index: sljit/sljitNativeARM_64.c 1449 + =================================================================== 1450 + --- sljit/sljitNativeARM_64.c (revision 1554) 1451 + +++ sljit/sljitNativeARM_64.c (working copy) 1452 + @@ -1087,7 +1087,8 @@ 1453 + saved_regs_size += sizeof(sljit_sw); 1454 + } 1455 + local_size -= saved_regs_size + SLJIT_LOCALS_OFFSET; 1456 + - FAIL_IF(push_inst(compiler, SUBI | RD(TMP_SP) | RN(TMP_SP) | (saved_regs_size << 10))); 1457 + + if (saved_regs_size > 0) 1458 + + FAIL_IF(push_inst(compiler, SUBI | RD(TMP_SP) | RN(TMP_SP) | (saved_regs_size << 10))); 1459 + } 1460 + 1461 + tmp = saveds < SLJIT_NUMBER_OF_SAVED_REGISTERS ? (SLJIT_S0 + 1 - saveds) : SLJIT_FIRST_SAVED_REG; 1462 + @@ -1094,7 +1095,12 @@ 1463 + prev = -1; 1464 + for (i = SLJIT_S0; i >= tmp; i--) { 1465 + if (prev == -1) { 1466 + - prev = i; 1467 + + if (!(offs & (1 << 15))) { 1468 + + prev = i; 1469 + + continue; 1470 + + } 1471 + + FAIL_IF(push_inst(compiler, STRI | RT(i) | RN(TMP_SP) | (offs >> 5))); 1472 + + offs += 1 << 15; 1473 + continue; 1474 + } 1475 + FAIL_IF(push_inst(compiler, STP | RT(prev) | RT2(i) | RN(TMP_SP) | offs)); 1476 + @@ -1104,7 +1110,12 @@ 1477 + 1478 + for (i = scratches; i >= SLJIT_FIRST_SAVED_REG; i--) { 1479 + if (prev == -1) { 1480 + - prev = i; 1481 + + if (!(offs & (1 << 15))) { 1482 + + prev = i; 1483 + + continue; 1484 + + } 1485 + + FAIL_IF(push_inst(compiler, STRI | RT(i) | RN(TMP_SP) | (offs >> 5))); 1486 + + offs += 1 << 15; 1487 + continue; 1488 + } 1489 + FAIL_IF(push_inst(compiler, STP | RT(prev) | RT2(i) | RN(TMP_SP) | offs)); 1490 + @@ -1112,8 +1123,7 @@ 1491 + prev = -1; 1492 + } 1493 + 1494 + - if (prev != -1) 1495 + - FAIL_IF(push_inst(compiler, STRI | RT(prev) | RN(TMP_SP) | (offs >> 5))); 1496 + + SLJIT_ASSERT(prev == -1); 1497 + 1498 + if (compiler->local_size > (63 * sizeof(sljit_sw))) { 1499 + /* The local_size is already adjusted by the saved registers. */ 1500 + @@ -1188,7 +1198,12 @@ 1501 + prev = -1; 1502 + for (i = SLJIT_S0; i >= tmp; i--) { 1503 + if (prev == -1) { 1504 + - prev = i; 1505 + + if (!(offs & (1 << 15))) { 1506 + + prev = i; 1507 + + continue; 1508 + + } 1509 + + FAIL_IF(push_inst(compiler, LDRI | RT(i) | RN(TMP_SP) | (offs >> 5))); 1510 + + offs += 1 << 15; 1511 + continue; 1512 + } 1513 + FAIL_IF(push_inst(compiler, LDP | RT(prev) | RT2(i) | RN(TMP_SP) | offs)); 1514 + @@ -1198,7 +1213,12 @@ 1515 + 1516 + for (i = compiler->scratches; i >= SLJIT_FIRST_SAVED_REG; i--) { 1517 + if (prev == -1) { 1518 + - prev = i; 1519 + + if (!(offs & (1 << 15))) { 1520 + + prev = i; 1521 + + continue; 1522 + + } 1523 + + FAIL_IF(push_inst(compiler, LDRI | RT(i) | RN(TMP_SP) | (offs >> 5))); 1524 + + offs += 1 << 15; 1525 + continue; 1526 + } 1527 + FAIL_IF(push_inst(compiler, LDP | RT(prev) | RT2(i) | RN(TMP_SP) | offs)); 1528 + @@ -1206,13 +1226,12 @@ 1529 + prev = -1; 1530 + } 1531 + 1532 + - if (prev != -1) 1533 + - FAIL_IF(push_inst(compiler, LDRI | RT(prev) | RN(TMP_SP) | (offs >> 5))); 1534 + + SLJIT_ASSERT(prev == -1); 1535 + 1536 + if (compiler->local_size <= (63 * sizeof(sljit_sw))) { 1537 + FAIL_IF(push_inst(compiler, LDP_PST | 29 | RT2(TMP_LR) 1538 + | RN(TMP_SP) | (((local_size >> 3) & 0x7f) << 15))); 1539 + - } else { 1540 + + } else if (saved_regs_size > 0) { 1541 + FAIL_IF(push_inst(compiler, ADDI | RD(TMP_SP) | RN(TMP_SP) | (saved_regs_size << 10))); 1542 + } 1543 + 1544 + @@ -1242,12 +1261,15 @@ 1545 + FAIL_IF(push_inst(compiler, ORR | RD(TMP_REG1) | RN(TMP_ZERO) | RM(SLJIT_R0))); 1546 + FAIL_IF(push_inst(compiler, MADD | RD(SLJIT_R0) | RN(SLJIT_R0) | RM(SLJIT_R1) | RT2(TMP_ZERO))); 1547 + return push_inst(compiler, (op == SLJIT_LUMUL ? UMULH : SMULH) | RD(SLJIT_R1) | RN(TMP_REG1) | RM(SLJIT_R1)); 1548 + - case SLJIT_LUDIV: 1549 + - case SLJIT_LSDIV: 1550 + + case SLJIT_UDIVMOD: 1551 + + case SLJIT_SDIVMOD: 1552 + FAIL_IF(push_inst(compiler, (ORR ^ inv_bits) | RD(TMP_REG1) | RN(TMP_ZERO) | RM(SLJIT_R0))); 1553 + - FAIL_IF(push_inst(compiler, ((op == SLJIT_LUDIV ? UDIV : SDIV) ^ inv_bits) | RD(SLJIT_R0) | RN(SLJIT_R0) | RM(SLJIT_R1))); 1554 + + FAIL_IF(push_inst(compiler, ((op == SLJIT_UDIVMOD ? UDIV : SDIV) ^ inv_bits) | RD(SLJIT_R0) | RN(SLJIT_R0) | RM(SLJIT_R1))); 1555 + FAIL_IF(push_inst(compiler, (MADD ^ inv_bits) | RD(SLJIT_R1) | RN(SLJIT_R0) | RM(SLJIT_R1) | RT2(TMP_ZERO))); 1556 + return push_inst(compiler, (SUB ^ inv_bits) | RD(SLJIT_R1) | RN(TMP_REG1) | RM(SLJIT_R1)); 1557 + + case SLJIT_UDIVI: 1558 + + case SLJIT_SDIVI: 1559 + + return push_inst(compiler, ((op == SLJIT_UDIVI ? UDIV : SDIV) ^ inv_bits) | RD(SLJIT_R0) | RN(SLJIT_R0) | RM(SLJIT_R1)); 1560 + } 1561 + 1562 + return SLJIT_SUCCESS; 1563 + Index: sljit/sljitNativeARM_T2_32.c 1564 + =================================================================== 1565 + --- sljit/sljitNativeARM_T2_32.c (revision 1554) 1566 + +++ sljit/sljitNativeARM_T2_32.c (working copy) 1567 + @@ -1239,6 +1239,9 @@ 1568 + 1569 + SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op) 1570 + { 1571 + + sljit_sw saved_reg_list[3]; 1572 + + sljit_sw saved_reg_count; 1573 + + 1574 + CHECK_ERROR(); 1575 + CHECK(check_sljit_emit_op0(compiler, op)); 1576 + 1577 + @@ -1255,24 +1258,53 @@ 1578 + | (reg_map[SLJIT_R0] << 12) 1579 + | (reg_map[SLJIT_R0] << 16) 1580 + | reg_map[SLJIT_R1]); 1581 + - case SLJIT_LUDIV: 1582 + - case SLJIT_LSDIV: 1583 + - if (compiler->scratches >= 4) { 1584 + - FAIL_IF(push_inst32(compiler, 0xf84d2d04 /* str r2, [sp, #-4]! */)); 1585 + - FAIL_IF(push_inst32(compiler, 0xf84dcd04 /* str ip, [sp, #-4]! */)); 1586 + - } else if (compiler->scratches >= 3) 1587 + - FAIL_IF(push_inst32(compiler, 0xf84d2d08 /* str r2, [sp, #-8]! */)); 1588 + + case SLJIT_UDIVMOD: 1589 + + case SLJIT_SDIVMOD: 1590 + + case SLJIT_UDIVI: 1591 + + case SLJIT_SDIVI: 1592 + + SLJIT_COMPILE_ASSERT((SLJIT_UDIVMOD & 0x2) == 0 && SLJIT_UDIVI - 0x2 == SLJIT_UDIVMOD, bad_div_opcode_assignments); 1593 + + SLJIT_COMPILE_ASSERT(reg_map[2] == 1 && reg_map[3] == 2 && reg_map[4] == 12, bad_register_mapping); 1594 + + 1595 + + saved_reg_count = 0; 1596 + + if (compiler->scratches >= 4) 1597 + + saved_reg_list[saved_reg_count++] = 12; 1598 + + if (compiler->scratches >= 3) 1599 + + saved_reg_list[saved_reg_count++] = 2; 1600 + + if (op >= SLJIT_UDIVI) 1601 + + saved_reg_list[saved_reg_count++] = 1; 1602 + + 1603 + + if (saved_reg_count > 0) { 1604 + + FAIL_IF(push_inst32(compiler, 0xf84d0d00 | (saved_reg_count >= 3 ? 16 : 8) 1605 + + | (saved_reg_list[0] << 12) /* str rX, [sp, #-8/-16]! */)); 1606 + + if (saved_reg_count >= 2) { 1607 + + SLJIT_ASSERT(saved_reg_list[1] < 8); 1608 + + FAIL_IF(push_inst16(compiler, 0x9001 | (saved_reg_list[1] << 8) /* str rX, [sp, #4] */)); 1609 + + } 1610 + + if (saved_reg_count >= 3) { 1611 + + SLJIT_ASSERT(saved_reg_list[2] < 8); 1612 + + FAIL_IF(push_inst16(compiler, 0x9002 | (saved_reg_list[2] << 8) /* str rX, [sp, #8] */)); 1613 + + } 1614 + + } 1615 + + 1616 + #if defined(__GNUC__) 1617 + FAIL_IF(sljit_emit_ijump(compiler, SLJIT_FAST_CALL, SLJIT_IMM, 1618 + - (op == SLJIT_LUDIV ? SLJIT_FUNC_OFFSET(__aeabi_uidivmod) : SLJIT_FUNC_OFFSET(__aeabi_idivmod)))); 1619 + + ((op | 0x2) == SLJIT_UDIVI ? SLJIT_FUNC_OFFSET(__aeabi_uidivmod) : SLJIT_FUNC_OFFSET(__aeabi_idivmod)))); 1620 + #else 1621 + #error "Software divmod functions are needed" 1622 + #endif 1623 + - if (compiler->scratches >= 4) { 1624 + - FAIL_IF(push_inst32(compiler, 0xf85dcb04 /* ldr ip, [sp], #4 */)); 1625 + - return push_inst32(compiler, 0xf85d2b04 /* ldr r2, [sp], #4 */); 1626 + - } else if (compiler->scratches >= 3) 1627 + - return push_inst32(compiler, 0xf85d2b08 /* ldr r2, [sp], #8 */); 1628 + + 1629 + + if (saved_reg_count > 0) { 1630 + + if (saved_reg_count >= 3) { 1631 + + SLJIT_ASSERT(saved_reg_list[2] < 8); 1632 + + FAIL_IF(push_inst16(compiler, 0x9802 | (saved_reg_list[2] << 8) /* ldr rX, [sp, #8] */)); 1633 + + } 1634 + + if (saved_reg_count >= 2) { 1635 + + SLJIT_ASSERT(saved_reg_list[1] < 8); 1636 + + FAIL_IF(push_inst16(compiler, 0x9801 | (saved_reg_list[1] << 8) /* ldr rX, [sp, #4] */)); 1637 + + } 1638 + + return push_inst32(compiler, 0xf85d0b00 | (saved_reg_count >= 3 ? 16 : 8) 1639 + + | (saved_reg_list[0] << 12) /* ldr rX, [sp], #8/16 */); 1640 + + } 1641 + return SLJIT_SUCCESS; 1642 + } 1643 + 1644 + Index: sljit/sljitNativePPC_common.c 1645 + =================================================================== 1646 + --- sljit/sljitNativePPC_common.c (revision 1554) 1647 + +++ sljit/sljitNativePPC_common.c (working copy) 1648 + @@ -1267,22 +1267,23 @@ 1649 + FAIL_IF(push_inst(compiler, MULLW | D(SLJIT_R0) | A(TMP_REG1) | B(SLJIT_R1))); 1650 + return push_inst(compiler, (op == SLJIT_LUMUL ? MULHWU : MULHW) | D(SLJIT_R1) | A(TMP_REG1) | B(SLJIT_R1)); 1651 + #endif 1652 + - case SLJIT_LUDIV: 1653 + - case SLJIT_LSDIV: 1654 + + case SLJIT_UDIVMOD: 1655 + + case SLJIT_SDIVMOD: 1656 + FAIL_IF(push_inst(compiler, OR | S(SLJIT_R0) | A(TMP_REG1) | B(SLJIT_R0))); 1657 + #if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64) 1658 + - if (int_op) { 1659 + - FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? DIVWU : DIVW) | D(SLJIT_R0) | A(TMP_REG1) | B(SLJIT_R1))); 1660 + - FAIL_IF(push_inst(compiler, MULLW | D(SLJIT_R1) | A(SLJIT_R0) | B(SLJIT_R1))); 1661 + - } else { 1662 + - FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? DIVDU : DIVD) | D(SLJIT_R0) | A(TMP_REG1) | B(SLJIT_R1))); 1663 + - FAIL_IF(push_inst(compiler, MULLD | D(SLJIT_R1) | A(SLJIT_R0) | B(SLJIT_R1))); 1664 + - } 1665 + - return push_inst(compiler, SUBF | D(SLJIT_R1) | A(SLJIT_R1) | B(TMP_REG1)); 1666 + + 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))); 1667 + + FAIL_IF(push_inst(compiler, (int_op ? MULLW : MULLD) | D(SLJIT_R1) | A(SLJIT_R0) | B(SLJIT_R1))); 1668 + #else 1669 + - FAIL_IF(push_inst(compiler, (op == SLJIT_LUDIV ? DIVWU : DIVW) | D(SLJIT_R0) | A(TMP_REG1) | B(SLJIT_R1))); 1670 + + FAIL_IF(push_inst(compiler, (op == SLJIT_UDIVMOD ? DIVWU : DIVW) | D(SLJIT_R0) | A(SLJIT_R0) | B(SLJIT_R1))); 1671 + FAIL_IF(push_inst(compiler, MULLW | D(SLJIT_R1) | A(SLJIT_R0) | B(SLJIT_R1))); 1672 + +#endif 1673 + return push_inst(compiler, SUBF | D(SLJIT_R1) | A(SLJIT_R1) | B(TMP_REG1)); 1674 + + case SLJIT_UDIVI: 1675 + + case SLJIT_SDIVI: 1676 + +#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64) 1677 + + 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)); 1678 + +#else 1679 + + return push_inst(compiler, (op == SLJIT_UDIVI ? DIVWU : DIVW) | D(SLJIT_R0) | A(SLJIT_R0) | B(SLJIT_R1)); 1680 + #endif 1681 + } 1682 + 1683 + Index: sljit/sljitNativeX86_common.c 1684 + =================================================================== 1685 + --- sljit/sljitNativeX86_common.c (revision 1554) 1686 + +++ sljit/sljitNativeX86_common.c (working copy) 1687 + @@ -273,7 +273,9 @@ 1688 + #endif 1689 + static sljit_si cpu_has_cmov = -1; 1690 + 1691 + -#if defined(_MSC_VER) && _MSC_VER >= 1400 1692 + +#ifdef _WIN32_WCE 1693 + +#include <cmnintrin.h> 1694 + +#elif defined(_MSC_VER) && _MSC_VER >= 1400 1695 + #include <intrin.h> 1696 + #endif 1697 + 1698 + @@ -742,8 +744,10 @@ 1699 + break; 1700 + case SLJIT_LUMUL: 1701 + case SLJIT_LSMUL: 1702 + - case SLJIT_LUDIV: 1703 + - case SLJIT_LSDIV: 1704 + + case SLJIT_UDIVMOD: 1705 + + case SLJIT_SDIVMOD: 1706 + + case SLJIT_UDIVI: 1707 + + case SLJIT_SDIVI: 1708 + compiler->flags_saved = 0; 1709 + #if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) 1710 + #ifdef _WIN64 1711 + @@ -761,9 +765,10 @@ 1712 + #endif 1713 + compiler->mode32 = op & SLJIT_INT_OP; 1714 + #endif 1715 + + SLJIT_COMPILE_ASSERT((SLJIT_UDIVMOD & 0x2) == 0 && SLJIT_UDIVI - 0x2 == SLJIT_UDIVMOD, bad_div_opcode_assignments); 1716 + 1717 + op = GET_OPCODE(op); 1718 + - if (op == SLJIT_LUDIV) { 1719 + + if ((op | 0x2) == SLJIT_UDIVI) { 1720 + #if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || defined(_WIN64) 1721 + EMIT_MOV(compiler, TMP_REG1, 0, SLJIT_R1, 0); 1722 + inst = emit_x86_instruction(compiler, 1, SLJIT_R1, 0, SLJIT_R1, 0); 1723 + @@ -774,7 +779,7 @@ 1724 + *inst = XOR_r_rm; 1725 + } 1726 + 1727 + - if (op == SLJIT_LSDIV) { 1728 + + if ((op | 0x2) == SLJIT_SDIVI) { 1729 + #if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || defined(_WIN64) 1730 + EMIT_MOV(compiler, TMP_REG1, 0, SLJIT_R1, 0); 1731 + #endif 1732 + @@ -805,10 +810,10 @@ 1733 + FAIL_IF(!inst); 1734 + INC_SIZE(2); 1735 + *inst++ = GROUP_F7; 1736 + - *inst = MOD_REG | ((op >= SLJIT_LUDIV) ? reg_map[TMP_REG1] : reg_map[SLJIT_R1]); 1737 + + *inst = MOD_REG | ((op >= SLJIT_UDIVMOD) ? reg_map[TMP_REG1] : reg_map[SLJIT_R1]); 1738 + #else 1739 + #ifdef _WIN64 1740 + - size = (!compiler->mode32 || op >= SLJIT_LUDIV) ? 3 : 2; 1741 + + size = (!compiler->mode32 || op >= SLJIT_UDIVMOD) ? 3 : 2; 1742 + #else 1743 + size = (!compiler->mode32) ? 3 : 2; 1744 + #endif 1745 + @@ -817,11 +822,11 @@ 1746 + INC_SIZE(size); 1747 + #ifdef _WIN64 1748 + if (!compiler->mode32) 1749 + - *inst++ = REX_W | ((op >= SLJIT_LUDIV) ? REX_B : 0); 1750 + - else if (op >= SLJIT_LUDIV) 1751 + + *inst++ = REX_W | ((op >= SLJIT_UDIVMOD) ? REX_B : 0); 1752 + + else if (op >= SLJIT_UDIVMOD) 1753 + *inst++ = REX_B; 1754 + *inst++ = GROUP_F7; 1755 + - *inst = MOD_REG | ((op >= SLJIT_LUDIV) ? reg_lmap[TMP_REG1] : reg_lmap[SLJIT_R1]); 1756 + + *inst = MOD_REG | ((op >= SLJIT_UDIVMOD) ? reg_lmap[TMP_REG1] : reg_lmap[SLJIT_R1]); 1757 + #else 1758 + if (!compiler->mode32) 1759 + *inst++ = REX_W; 1760 + @@ -836,15 +841,21 @@ 1761 + case SLJIT_LSMUL: 1762 + *inst |= IMUL; 1763 + break; 1764 + - case SLJIT_LUDIV: 1765 + + case SLJIT_UDIVMOD: 1766 + + case SLJIT_UDIVI: 1767 + *inst |= DIV; 1768 + break; 1769 + - case SLJIT_LSDIV: 1770 + + case SLJIT_SDIVMOD: 1771 + + case SLJIT_SDIVI: 1772 + *inst |= IDIV; 1773 + break; 1774 + } 1775 + #if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) && !defined(_WIN64) 1776 + - EMIT_MOV(compiler, SLJIT_R1, 0, TMP_REG1, 0); 1777 + + if (op <= SLJIT_SDIVMOD) 1778 + + EMIT_MOV(compiler, SLJIT_R1, 0, TMP_REG1, 0); 1779 + +#else 1780 + + if (op >= SLJIT_UDIVI) 1781 + + EMIT_MOV(compiler, SLJIT_R1, 0, TMP_REG1, 0); 1782 + #endif 1783 + break; 1784 + } 1785 + @@ -1905,60 +1916,62 @@ 1786 + return SLJIT_SUCCESS; 1787 + } 1788 + 1789 + - if (FAST_IS_REG(src1)) { 1790 + + if (!(src1 & SLJIT_IMM)) { 1791 + if (src2 & SLJIT_IMM) { 1792 + #if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) 1793 + if (IS_HALFWORD(src2w) || compiler->mode32) { 1794 + - inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, 0); 1795 + + inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, src1w); 1796 + FAIL_IF(!inst); 1797 + *inst = GROUP_F7; 1798 + } 1799 + else { 1800 + FAIL_IF(emit_load_imm64(compiler, TMP_REG2, src2w)); 1801 + - inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, src1, 0); 1802 + + inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, src1, src1w); 1803 + FAIL_IF(!inst); 1804 + *inst = TEST_rm_r; 1805 + } 1806 + #else 1807 + - inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, 0); 1808 + + inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, src1w); 1809 + FAIL_IF(!inst); 1810 + *inst = GROUP_F7; 1811 + #endif 1812 + + return SLJIT_SUCCESS; 1813 + } 1814 + - else { 1815 + + else if (FAST_IS_REG(src1)) { 1816 + inst = emit_x86_instruction(compiler, 1, src1, 0, src2, src2w); 1817 + FAIL_IF(!inst); 1818 + *inst = TEST_rm_r; 1819 + + return SLJIT_SUCCESS; 1820 + } 1821 + - return SLJIT_SUCCESS; 1822 + } 1823 + 1824 + - if (FAST_IS_REG(src2)) { 1825 + + if (!(src2 & SLJIT_IMM)) { 1826 + if (src1 & SLJIT_IMM) { 1827 + #if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) 1828 + if (IS_HALFWORD(src1w) || compiler->mode32) { 1829 + - inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src1w, src2, 0); 1830 + + inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src1w, src2, src2w); 1831 + FAIL_IF(!inst); 1832 + *inst = GROUP_F7; 1833 + } 1834 + else { 1835 + FAIL_IF(emit_load_imm64(compiler, TMP_REG2, src1w)); 1836 + - inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, src2, 0); 1837 + + inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, src2, src2w); 1838 + FAIL_IF(!inst); 1839 + *inst = TEST_rm_r; 1840 + } 1841 + #else 1842 + - inst = emit_x86_instruction(compiler, 1, src1, src1w, src2, 0); 1843 + + inst = emit_x86_instruction(compiler, 1, src1, src1w, src2, src2w); 1844 + FAIL_IF(!inst); 1845 + *inst = GROUP_F7; 1846 + #endif 1847 + + return SLJIT_SUCCESS; 1848 + } 1849 + - else { 1850 + + else if (FAST_IS_REG(src2)) { 1851 + inst = emit_x86_instruction(compiler, 1, src2, 0, src1, src1w); 1852 + FAIL_IF(!inst); 1853 + *inst = TEST_rm_r; 1854 + + return SLJIT_SUCCESS; 1855 + } 1856 + - return SLJIT_SUCCESS; 1857 + } 1858 + 1859 + EMIT_MOV(compiler, TMP_REG1, 0, src1, src1w); 1860 + @@ -2923,3 +2936,69 @@ 1861 + { 1862 + *(sljit_sw*)addr = new_constant; 1863 + } 1864 + + 1865 + +SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_x86_is_sse2_available(void) 1866 + +{ 1867 + +#if (defined SLJIT_DETECT_SSE2 && SLJIT_DETECT_SSE2) 1868 + + if (cpu_has_sse2 == -1) 1869 + + get_cpu_features(); 1870 + + return cpu_has_sse2; 1871 + +#else 1872 + + return 1; 1873 + +#endif 1874 + +} 1875 + + 1876 + +SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_x86_is_cmov_available(void) 1877 + +{ 1878 + + if (cpu_has_cmov == -1) 1879 + + get_cpu_features(); 1880 + + return cpu_has_cmov; 1881 + +} 1882 + + 1883 + +SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_x86_emit_cmov(struct sljit_compiler *compiler, 1884 + + sljit_si type, 1885 + + sljit_si dst_reg, 1886 + + sljit_si src, sljit_sw srcw) 1887 + +{ 1888 + + sljit_ub* inst; 1889 + + 1890 + + CHECK_ERROR(); 1891 + +#if (defined SLJIT_ARGUMENT_CHECKS && SLJIT_ARGUMENT_CHECKS) 1892 + + CHECK_ARGUMENT(sljit_x86_is_cmov_available()); 1893 + + CHECK_ARGUMENT(!(type & ~(0xff | SLJIT_INT_OP))); 1894 + + CHECK_ARGUMENT((type & 0xff) >= SLJIT_EQUAL && (type & 0xff) <= SLJIT_D_ORDERED); 1895 + + CHECK_ARGUMENT(FUNCTION_CHECK_IS_REG(dst_reg & ~SLJIT_INT_OP)); 1896 + + FUNCTION_CHECK_SRC(src, srcw); 1897 + +#endif 1898 + +#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) 1899 + + if (SLJIT_UNLIKELY(!!compiler->verbose)) { 1900 + + fprintf(compiler->verbose, " x86_cmov%s %s%s, ", 1901 + + !(dst_reg & SLJIT_INT_OP) ? "" : ".i", 1902 + + JUMP_PREFIX(type), jump_names[type & 0xff]); 1903 + + sljit_verbose_reg(compiler, dst_reg & ~SLJIT_INT_OP); 1904 + + fprintf(compiler->verbose, ", "); 1905 + + sljit_verbose_param(compiler, src, srcw); 1906 + + fprintf(compiler->verbose, "\n"); 1907 + + } 1908 + +#endif 1909 + + 1910 + + ADJUST_LOCAL_OFFSET(src, srcw); 1911 + + CHECK_EXTRA_REGS(src, srcw, (void)0); 1912 + + 1913 + +#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) 1914 + + compiler->mode32 = dst_reg & SLJIT_INT_OP; 1915 + +#endif 1916 + + dst_reg &= ~SLJIT_INT_OP; 1917 + + 1918 + + if (SLJIT_UNLIKELY(src & SLJIT_IMM)) { 1919 + + EMIT_MOV(compiler, TMP_REG1, 0, SLJIT_IMM, srcw); 1920 + + src = TMP_REG1; 1921 + + srcw = 0; 1922 + + } 1923 + + 1924 + + inst = emit_x86_instruction(compiler, 2, dst_reg, 0, src, srcw); 1925 + + FAIL_IF(!inst); 1926 + + *inst++ = GROUP_0F; 1927 + + *inst = get_jump_code(type & 0xff) - 0x40; 1928 + + return SLJIT_SUCCESS; 1929 + +} 1930 + Index: sljit/sljitConfigInternal.h 1931 + =================================================================== 1932 + --- sljit/sljitConfigInternal.h (revision 1554) 1933 + +++ sljit/sljitConfigInternal.h (working copy) 1934 + @@ -468,8 +468,13 @@ 1935 + 1936 + #ifndef SLJIT_CALL 1937 + 1938 + -#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) 1939 + +#if (defined SLJIT_USE_CDECL_CALLING_CONVENTION && SLJIT_USE_CDECL_CALLING_CONVENTION) 1940 + 1941 + +/* Force cdecl. */ 1942 + +#define SLJIT_CALL 1943 + + 1944 + +#elif (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) 1945 + + 1946 + #if defined(__GNUC__) && !defined(__APPLE__) 1947 + 1948 + #define SLJIT_CALL __attribute__ ((fastcall)) 1949 + @@ -608,6 +613,12 @@ 1950 + #define SLJIT_LOCALS_OFFSET_BASE ((23 + 1) * sizeof(sljit_sw)) 1951 + #endif 1952 + 1953 + +#elif (defined SLJIT_CONFIG_TILEGX && SLJIT_CONFIG_TILEGX) 1954 + + 1955 + +#define SLJIT_NUMBER_OF_REGISTERS 10 1956 + +#define SLJIT_NUMBER_OF_SAVED_REGISTERS 5 1957 + +#define SLJIT_LOCALS_OFFSET_BASE 0 1958 + + 1959 + #elif (defined SLJIT_CONFIG_UNSUPPORTED && SLJIT_CONFIG_UNSUPPORTED) 1960 + 1961 + #define SLJIT_NUMBER_OF_REGISTERS 0 1962 + Index: sljit/sljitConfig.h 1963 + =================================================================== 1964 + --- sljit/sljitConfig.h (revision 1554) 1965 + +++ sljit/sljitConfig.h (working copy) 1966 + @@ -96,6 +96,15 @@ 1967 + #define SLJIT_EXECUTABLE_ALLOCATOR 1 1968 + #endif 1969 + 1970 + +/* Force cdecl calling convention even if a better calling 1971 + + convention (e.g. fastcall) is supported by the C compiler. 1972 + + If this option is enabled, C functions without 1973 + + SLJIT_CALL can also be called from JIT code. */ 1974 + +#ifndef SLJIT_USE_CDECL_CALLING_CONVENTION 1975 + +/* Disabled by default */ 1976 + +#define SLJIT_USE_CDECL_CALLING_CONVENTION 0 1977 + +#endif 1978 + + 1979 + /* Return with error when an invalid argument is passed. */ 1980 + #ifndef SLJIT_ARGUMENT_CHECKS 1981 + /* Disabled by default */ 1982 + Index: sljit/sljitNativeTILEGX_64.c 1983 + =================================================================== 1984 + --- sljit/sljitNativeTILEGX_64.c (revision 1554) 1985 + +++ sljit/sljitNativeTILEGX_64.c (working copy) 1986 + @@ -35,21 +35,21 @@ 1987 + #define SIMM_16BIT_MIN (-0x8000) 1988 + #define SIMM_17BIT_MAX (0xffff) 1989 + #define SIMM_17BIT_MIN (-0x10000) 1990 + -#define SIMM_32BIT_MIN (-0x80000000) 1991 + #define SIMM_32BIT_MAX (0x7fffffff) 1992 + -#define SIMM_48BIT_MIN (0x800000000000L) 1993 + +#define SIMM_32BIT_MIN (-0x7fffffff - 1) 1994 + #define SIMM_48BIT_MAX (0x7fffffff0000L) 1995 + +#define SIMM_48BIT_MIN (-0x800000000000L) 1996 + #define IMM16(imm) ((imm) & 0xffff) 1997 + 1998 + #define UIMM_16BIT_MAX (0xffff) 1999 + 2000 + -#define TMP_REG1 (SLJIT_NO_REGISTERS + 1) 2001 + -#define TMP_REG2 (SLJIT_NO_REGISTERS + 2) 2002 + -#define TMP_REG3 (SLJIT_NO_REGISTERS + 3) 2003 + -#define ADDR_TMP (SLJIT_NO_REGISTERS + 4) 2004 + +#define TMP_REG1 (SLJIT_NUMBER_OF_REGISTERS + 2) 2005 + +#define TMP_REG2 (SLJIT_NUMBER_OF_REGISTERS + 3) 2006 + +#define TMP_REG3 (SLJIT_NUMBER_OF_REGISTERS + 4) 2007 + +#define ADDR_TMP (SLJIT_NUMBER_OF_REGISTERS + 5) 2008 + #define PIC_ADDR_REG TMP_REG2 2009 + 2010 + -static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 5] = { 2011 + +static SLJIT_CONST sljit_ub reg_map[SLJIT_NUMBER_OF_REGISTERS + 6] = { 2012 + 63, 0, 1, 2, 3, 4, 30, 31, 32, 33, 34, 54, 5, 16, 6, 7 2013 + }; 2014 + 2015 + @@ -58,11 +58,6 @@ 2016 + #define TMP_REG2_mapped 16 2017 + #define TMP_REG3_mapped 6 2018 + #define ADDR_TMP_mapped 7 2019 + -#define SLJIT_SAVED_REG1_mapped 30 2020 + -#define SLJIT_SAVED_REG2_mapped 31 2021 + -#define SLJIT_SAVED_REG3_mapped 32 2022 + -#define SLJIT_SAVED_EREG1_mapped 33 2023 + -#define SLJIT_SAVED_EREG2_mapped 34 2024 + 2025 + /* Flags are keept in volatile registers. */ 2026 + #define EQUAL_FLAG 8 2027 + @@ -399,6 +394,9 @@ 2028 + #define SUB(dst, srca, srcb) \ 2029 + push_3_buffer(compiler, TILEGX_OPC_SUB, dst, srca, srcb, __LINE__) 2030 + 2031 + +#define MUL(dst, srca, srcb) \ 2032 + + push_3_buffer(compiler, TILEGX_OPC_MULX, dst, srca, srcb, __LINE__) 2033 + + 2034 + #define NOR(dst, srca, srcb) \ 2035 + push_3_buffer(compiler, TILEGX_OPC_NOR, dst, srca, srcb, __LINE__) 2036 + 2037 + @@ -547,8 +545,8 @@ 2038 + 2039 + const struct Format* match = NULL; 2040 + const struct Format *b = NULL; 2041 + - unsigned int i = 0; 2042 + - for (i; i < sizeof formats / sizeof formats[0]; i++) { 2043 + + unsigned int i; 2044 + + for (i = 0; i < sizeof formats / sizeof formats[0]; i++) { 2045 + b = &formats[i]; 2046 + if ((b->pipe_mask & compatible_pipes) == b->pipe_mask) { 2047 + match = b; 2048 + @@ -625,7 +623,6 @@ 2049 + 2050 + static sljit_si update_buffer(struct sljit_compiler *compiler) 2051 + { 2052 + - int count; 2053 + int i; 2054 + int orig_index = inst_buf_index; 2055 + struct jit_instr inst0 = inst_buf[0]; 2056 + @@ -738,8 +735,10 @@ 2057 + 2058 + static sljit_si flush_buffer(struct sljit_compiler *compiler) 2059 + { 2060 + - while (inst_buf_index != 0) 2061 + - update_buffer(compiler); 2062 + + while (inst_buf_index != 0) { 2063 + + FAIL_IF(update_buffer(compiler)); 2064 + + } 2065 + + return SLJIT_SUCCESS; 2066 + } 2067 + 2068 + static sljit_si push_4_buffer(struct sljit_compiler *compiler, tilegx_mnemonic opc, int op0, int op1, int op2, int op3, int line) 2069 + @@ -787,6 +786,7 @@ 2070 + case TILEGX_OPC_ADD: 2071 + case TILEGX_OPC_AND: 2072 + case TILEGX_OPC_SUB: 2073 + + case TILEGX_OPC_MULX: 2074 + case TILEGX_OPC_OR: 2075 + case TILEGX_OPC_XOR: 2076 + case TILEGX_OPC_NOR: 2077 + @@ -905,7 +905,6 @@ 2078 + sljit_sw diff; 2079 + sljit_uw target_addr; 2080 + sljit_ins *inst; 2081 + - sljit_ins saved_inst; 2082 + 2083 + if (jump->flags & SLJIT_REWRITABLE_JUMP) 2084 + return code_ptr; 2085 + @@ -1009,7 +1008,7 @@ 2086 + struct sljit_const *const_; 2087 + 2088 + CHECK_ERROR_PTR(); 2089 + - check_sljit_generate_code(compiler); 2090 + + CHECK_PTR(check_sljit_generate_code(compiler)); 2091 + reverse_buf(compiler); 2092 + 2093 + code = (sljit_ins *)SLJIT_MALLOC_EXEC(compiler->size * sizeof(sljit_ins)); 2094 + @@ -1178,13 +1177,13 @@ 2095 + sljit_si fscratches, sljit_si fsaveds, sljit_si local_size) 2096 + { 2097 + sljit_ins base; 2098 + - sljit_ins bundle = 0; 2099 + - 2100 + + sljit_si i, tmp; 2101 + + 2102 + CHECK_ERROR(); 2103 + - check_sljit_emit_enter(compiler, options, args, scratches, saveds, fscratches, fsaveds, local_size); 2104 + + CHECK(check_sljit_emit_enter(compiler, options, args, scratches, saveds, fscratches, fsaveds, local_size)); 2105 + set_emit_enter(compiler, options, args, scratches, saveds, fscratches, fsaveds, local_size); 2106 + 2107 + - local_size += (saveds + 1) * sizeof(sljit_sw); 2108 + + local_size += GET_SAVED_REGISTERS_SIZE(scratches, saveds, 1); 2109 + local_size = (local_size + 7) & ~7; 2110 + compiler->local_size = local_size; 2111 + 2112 + @@ -1200,46 +1199,41 @@ 2113 + local_size = 0; 2114 + } 2115 + 2116 + + /* Save the return address. */ 2117 + FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 8)); 2118 + FAIL_IF(ST_ADD(ADDR_TMP_mapped, RA, -8)); 2119 + 2120 + - if (saveds >= 1) 2121 + - FAIL_IF(ST_ADD(ADDR_TMP_mapped, SLJIT_SAVED_REG1_mapped, -8)); 2122 + + /* Save the S registers. */ 2123 + + tmp = saveds < SLJIT_NUMBER_OF_SAVED_REGISTERS ? (SLJIT_S0 + 1 - saveds) : SLJIT_FIRST_SAVED_REG; 2124 + + for (i = SLJIT_S0; i >= tmp; i--) { 2125 + + FAIL_IF(ST_ADD(ADDR_TMP_mapped, reg_map[i], -8)); 2126 + + } 2127 + 2128 + - if (saveds >= 2) 2129 + - FAIL_IF(ST_ADD(ADDR_TMP_mapped, SLJIT_SAVED_REG2_mapped, -8)); 2130 + + /* Save the R registers that need to be reserved. */ 2131 + + for (i = scratches; i >= SLJIT_FIRST_SAVED_REG; i--) { 2132 + + FAIL_IF(ST_ADD(ADDR_TMP_mapped, reg_map[i], -8)); 2133 + + } 2134 + 2135 + - if (saveds >= 3) 2136 + - FAIL_IF(ST_ADD(ADDR_TMP_mapped, SLJIT_SAVED_REG3_mapped, -8)); 2137 + + /* Move the arguments to S registers. */ 2138 + + for (i = 0; i < args; i++) { 2139 + + FAIL_IF(ADD(reg_map[SLJIT_S0 - i], i, ZERO)); 2140 + + } 2141 + 2142 + - if (saveds >= 4) 2143 + - FAIL_IF(ST_ADD(ADDR_TMP_mapped, SLJIT_SAVED_EREG1_mapped, -8)); 2144 + - 2145 + - if (saveds >= 5) 2146 + - FAIL_IF(ST_ADD(ADDR_TMP_mapped, SLJIT_SAVED_EREG2_mapped, -8)); 2147 + - 2148 + - if (args >= 1) 2149 + - FAIL_IF(ADD(SLJIT_SAVED_REG1_mapped, 0, ZERO)); 2150 + - 2151 + - if (args >= 2) 2152 + - FAIL_IF(ADD(SLJIT_SAVED_REG2_mapped, 1, ZERO)); 2153 + - 2154 + - if (args >= 3) 2155 + - FAIL_IF(ADD(SLJIT_SAVED_REG3_mapped, 2, ZERO)); 2156 + - 2157 + return SLJIT_SUCCESS; 2158 + } 2159 + 2160 + -SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, 2161 + +SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_set_context(struct sljit_compiler *compiler, 2162 + sljit_si options, sljit_si args, sljit_si scratches, sljit_si saveds, 2163 + sljit_si fscratches, sljit_si fsaveds, sljit_si local_size) 2164 + { 2165 + - CHECK_ERROR_VOID(); 2166 + - check_sljit_set_context(compiler, options, args, scratches, saveds, fscratches, fsaveds, local_size); 2167 + + CHECK_ERROR(); 2168 + + CHECK(check_sljit_set_context(compiler, options, args, scratches, saveds, fscratches, fsaveds, local_size)); 2169 + set_set_context(compiler, options, args, scratches, saveds, fscratches, fsaveds, local_size); 2170 + 2171 + - local_size += (saveds + 1) * sizeof(sljit_sw); 2172 + + local_size += GET_SAVED_REGISTERS_SIZE(scratches, saveds, 1); 2173 + compiler->local_size = (local_size + 7) & ~7; 2174 + + 2175 + + return SLJIT_SUCCESS; 2176 + } 2177 + 2178 + SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_return(struct sljit_compiler *compiler, sljit_si op, sljit_si src, sljit_sw srcw) 2179 + @@ -1246,10 +1240,11 @@ 2180 + { 2181 + sljit_si local_size; 2182 + sljit_ins base; 2183 + - int addr_initialized = 0; 2184 + + sljit_si i, tmp; 2185 + + sljit_si saveds; 2186 + 2187 + CHECK_ERROR(); 2188 + - check_sljit_emit_return(compiler, op, src, srcw); 2189 + + CHECK(check_sljit_emit_return(compiler, op, src, srcw)); 2190 + 2191 + FAIL_IF(emit_mov_before_return(compiler, op, src, srcw)); 2192 + 2193 + @@ -1263,52 +1258,22 @@ 2194 + local_size = 0; 2195 + } 2196 + 2197 + + /* Restore the return address. */ 2198 + FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 8)); 2199 + - FAIL_IF(LD(RA, ADDR_TMP_mapped)); 2200 + + FAIL_IF(LD_ADD(RA, ADDR_TMP_mapped, -8)); 2201 + 2202 + - if (compiler->saveds >= 5) { 2203 + - FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 48)); 2204 + - addr_initialized = 1; 2205 + - 2206 + - FAIL_IF(LD_ADD(SLJIT_SAVED_EREG2_mapped, ADDR_TMP_mapped, 8)); 2207 + + /* Restore the S registers. */ 2208 + + saveds = compiler->saveds; 2209 + + tmp = saveds < SLJIT_NUMBER_OF_SAVED_REGISTERS ? (SLJIT_S0 + 1 - saveds) : SLJIT_FIRST_SAVED_REG; 2210 + + for (i = SLJIT_S0; i >= tmp; i--) { 2211 + + FAIL_IF(LD_ADD(reg_map[i], ADDR_TMP_mapped, -8)); 2212 + } 2213 + 2214 + - if (compiler->saveds >= 4) { 2215 + - if (addr_initialized == 0) { 2216 + - FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 40)); 2217 + - addr_initialized = 1; 2218 + - } 2219 + - 2220 + - FAIL_IF(LD_ADD(SLJIT_SAVED_EREG1_mapped, ADDR_TMP_mapped, 8)); 2221 + + /* Restore the R registers that need to be reserved. */ 2222 + + for (i = compiler->scratches; i >= SLJIT_FIRST_SAVED_REG; i--) { 2223 + + FAIL_IF(LD_ADD(reg_map[i], ADDR_TMP_mapped, -8)); 2224 + } 2225 + 2226 + - if (compiler->saveds >= 3) { 2227 + - if (addr_initialized == 0) { 2228 + - FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 32)); 2229 + - addr_initialized = 1; 2230 + - } 2231 + - 2232 + - FAIL_IF(LD_ADD(SLJIT_SAVED_REG3_mapped, ADDR_TMP_mapped, 8)); 2233 + - } 2234 + - 2235 + - if (compiler->saveds >= 2) { 2236 + - if (addr_initialized == 0) { 2237 + - FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 24)); 2238 + - addr_initialized = 1; 2239 + - } 2240 + - 2241 + - FAIL_IF(LD_ADD(SLJIT_SAVED_REG2_mapped, ADDR_TMP_mapped, 8)); 2242 + - } 2243 + - 2244 + - if (compiler->saveds >= 1) { 2245 + - if (addr_initialized == 0) { 2246 + - FAIL_IF(ADDLI(ADDR_TMP_mapped, base, local_size - 16)); 2247 + - /* addr_initialized = 1; no need to initialize as it's the last one. */ 2248 + - } 2249 + - 2250 + - FAIL_IF(LD_ADD(SLJIT_SAVED_REG1_mapped, ADDR_TMP_mapped, 8)); 2251 + - } 2252 + - 2253 + if (compiler->local_size <= SIMM_16BIT_MAX) 2254 + FAIL_IF(ADDLI(SLJIT_LOCALS_REG_mapped, SLJIT_LOCALS_REG_mapped, compiler->local_size)); 2255 + else 2256 + @@ -1585,7 +1550,7 @@ 2257 + SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_enter(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw) 2258 + { 2259 + CHECK_ERROR(); 2260 + - check_sljit_emit_fast_enter(compiler, dst, dstw); 2261 + + CHECK(check_sljit_emit_fast_enter(compiler, dst, dstw)); 2262 + ADJUST_LOCAL_OFFSET(dst, dstw); 2263 + 2264 + /* For UNUSED dst. Uncommon, but possible. */ 2265 + @@ -1602,7 +1567,7 @@ 2266 + SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_return(struct sljit_compiler *compiler, sljit_si src, sljit_sw srcw) 2267 + { 2268 + CHECK_ERROR(); 2269 + - check_sljit_emit_fast_return(compiler, src, srcw); 2270 + + CHECK(check_sljit_emit_fast_return(compiler, src, srcw)); 2271 + ADJUST_LOCAL_OFFSET(src, srcw); 2272 + 2273 + if (FAST_IS_REG(src)) 2274 + @@ -1636,9 +1601,11 @@ 2275 + if (op == SLJIT_MOV_SI) 2276 + return BFEXTS(reg_map[dst], reg_map[src2], 0, 31); 2277 + 2278 + - return BFEXTU(reg_map[dst], reg_map[src2], 0, 31); 2279 + - } else if (dst != src2) 2280 + - SLJIT_ASSERT_STOP(); 2281 + + return BFEXTU(reg_map[dst], reg_map[src2], 0, 31); 2282 + + } else if (dst != src2) { 2283 + + SLJIT_ASSERT(src2 == 0); 2284 + + return ADD(reg_map[dst], reg_map[src2], ZERO); 2285 + + } 2286 + 2287 + return SLJIT_SUCCESS; 2288 + 2289 + @@ -1650,8 +1617,10 @@ 2290 + return BFEXTS(reg_map[dst], reg_map[src2], 0, 7); 2291 + 2292 + return BFEXTU(reg_map[dst], reg_map[src2], 0, 7); 2293 + - } else if (dst != src2) 2294 + - SLJIT_ASSERT_STOP(); 2295 + + } else if (dst != src2) { 2296 + + SLJIT_ASSERT(src2 == 0); 2297 + + return ADD(reg_map[dst], reg_map[src2], ZERO); 2298 + + } 2299 + 2300 + return SLJIT_SUCCESS; 2301 + 2302 + @@ -1663,8 +1632,10 @@ 2303 + return BFEXTS(reg_map[dst], reg_map[src2], 0, 15); 2304 + 2305 + return BFEXTU(reg_map[dst], reg_map[src2], 0, 15); 2306 + - } else if (dst != src2) 2307 + - SLJIT_ASSERT_STOP(); 2308 + + } else if (dst != src2) { 2309 + + SLJIT_ASSERT(src2 == 0); 2310 + + return ADD(reg_map[dst], reg_map[src2], ZERO); 2311 + + } 2312 + 2313 + return SLJIT_SUCCESS; 2314 + 2315 + @@ -1811,7 +1782,6 @@ 2316 + else { 2317 + /* Rare ocasion. */ 2318 + FAIL_IF(ADD(TMP_EREG2, reg_map[src1], ZERO)); 2319 + - 2320 + overflow_ra = TMP_EREG2; 2321 + } 2322 + } 2323 + @@ -1903,6 +1873,17 @@ 2324 + 2325 + return SLJIT_SUCCESS; 2326 + 2327 + + case SLJIT_MUL: 2328 + + if (flags & SRC2_IMM) { 2329 + + FAIL_IF(load_immediate(compiler, TMP_REG2_mapped, src2)); 2330 + + src2 = TMP_REG2; 2331 + + flags &= ~SRC2_IMM; 2332 + + } 2333 + + 2334 + + FAIL_IF(MUL(reg_map[dst], reg_map[src1], reg_map[src2])); 2335 + + 2336 + + return SLJIT_SUCCESS; 2337 + + 2338 + #define EMIT_LOGICAL(op_imm, op_norm) \ 2339 + if (flags & SRC2_IMM) { \ 2340 + FAIL_IF(load_immediate(compiler, ADDR_TMP_mapped, src2)); \ 2341 + @@ -1950,8 +1931,8 @@ 2342 + } else { \ 2343 + if (op & SLJIT_SET_E) \ 2344 + FAIL_IF(push_3_buffer( \ 2345 + - compiler, op_imm, reg_map[dst], reg_map[src1], \ 2346 + - src2 & 0x3F, __LINE__)); \ 2347 + + compiler, op_norm, EQUAL_FLAG, reg_map[src1], \ 2348 + + reg_map[src2], __LINE__)); \ 2349 + if (CHECK_FLAGS(SLJIT_SET_E)) \ 2350 + FAIL_IF(push_3_buffer( \ 2351 + compiler, op_norm, reg_map[dst], reg_map[src1], \ 2352 + @@ -2105,9 +2086,10 @@ 2353 + { 2354 + sljit_si sugg_dst_ar, dst_ar; 2355 + sljit_si flags = GET_ALL_FLAGS(op); 2356 + + sljit_si mem_type = (op & SLJIT_INT_OP) ? (INT_DATA | SIGNED_DATA) : WORD_DATA; 2357 + 2358 + CHECK_ERROR(); 2359 + - check_sljit_emit_op_flags(compiler, op, dst, dstw, src, srcw, type); 2360 + + CHECK(check_sljit_emit_op_flags(compiler, op, dst, dstw, src, srcw, type)); 2361 + ADJUST_LOCAL_OFFSET(dst, dstw); 2362 + 2363 + if (dst == SLJIT_UNUSED) 2364 + @@ -2114,6 +2096,8 @@ 2365 + return SLJIT_SUCCESS; 2366 + 2367 + op = GET_OPCODE(op); 2368 + + if (op == SLJIT_MOV_SI || op == SLJIT_MOV_UI) 2369 + + mem_type = INT_DATA | SIGNED_DATA; 2370 + sugg_dst_ar = reg_map[(op < SLJIT_ADD && FAST_IS_REG(dst)) ? dst : TMP_REG2]; 2371 + 2372 + compiler->cache_arg = 0; 2373 + @@ -2120,51 +2104,43 @@ 2374 + compiler->cache_argw = 0; 2375 + if (op >= SLJIT_ADD && (src & SLJIT_MEM)) { 2376 + ADJUST_LOCAL_OFFSET(src, srcw); 2377 + - FAIL_IF(emit_op_mem2(compiler, WORD_DATA | LOAD_DATA, TMP_REG1_mapped, src, srcw, dst, dstw)); 2378 + + FAIL_IF(emit_op_mem2(compiler, mem_type | LOAD_DATA, TMP_REG1_mapped, src, srcw, dst, dstw)); 2379 + src = TMP_REG1; 2380 + srcw = 0; 2381 + } 2382 + 2383 + - switch (type) { 2384 + - case SLJIT_C_EQUAL: 2385 + - case SLJIT_C_NOT_EQUAL: 2386 + + switch (type & 0xff) { 2387 + + case SLJIT_EQUAL: 2388 + + case SLJIT_NOT_EQUAL: 2389 + FAIL_IF(CMPLTUI(sugg_dst_ar, EQUAL_FLAG, 1)); 2390 + dst_ar = sugg_dst_ar; 2391 + break; 2392 + - case SLJIT_C_LESS: 2393 + - case SLJIT_C_GREATER_EQUAL: 2394 + - case SLJIT_C_FLOAT_LESS: 2395 + - case SLJIT_C_FLOAT_GREATER_EQUAL: 2396 + + case SLJIT_LESS: 2397 + + case SLJIT_GREATER_EQUAL: 2398 + dst_ar = ULESS_FLAG; 2399 + break; 2400 + - case SLJIT_C_GREATER: 2401 + - case SLJIT_C_LESS_EQUAL: 2402 + - case SLJIT_C_FLOAT_GREATER: 2403 + - case SLJIT_C_FLOAT_LESS_EQUAL: 2404 + + case SLJIT_GREATER: 2405 + + case SLJIT_LESS_EQUAL: 2406 + dst_ar = UGREATER_FLAG; 2407 + break; 2408 + - case SLJIT_C_SIG_LESS: 2409 + - case SLJIT_C_SIG_GREATER_EQUAL: 2410 + + case SLJIT_SIG_LESS: 2411 + + case SLJIT_SIG_GREATER_EQUAL: 2412 + dst_ar = LESS_FLAG; 2413 + break; 2414 + - case SLJIT_C_SIG_GREATER: 2415 + - case SLJIT_C_SIG_LESS_EQUAL: 2416 + + case SLJIT_SIG_GREATER: 2417 + + case SLJIT_SIG_LESS_EQUAL: 2418 + dst_ar = GREATER_FLAG; 2419 + break; 2420 + - case SLJIT_C_OVERFLOW: 2421 + - case SLJIT_C_NOT_OVERFLOW: 2422 + + case SLJIT_OVERFLOW: 2423 + + case SLJIT_NOT_OVERFLOW: 2424 + dst_ar = OVERFLOW_FLAG; 2425 + break; 2426 + - case SLJIT_C_MUL_OVERFLOW: 2427 + - case SLJIT_C_MUL_NOT_OVERFLOW: 2428 + + case SLJIT_MUL_OVERFLOW: 2429 + + case SLJIT_MUL_NOT_OVERFLOW: 2430 + FAIL_IF(CMPLTUI(sugg_dst_ar, OVERFLOW_FLAG, 1)); 2431 + dst_ar = sugg_dst_ar; 2432 + type ^= 0x1; /* Flip type bit for the XORI below. */ 2433 + break; 2434 + - case SLJIT_C_FLOAT_EQUAL: 2435 + - case SLJIT_C_FLOAT_NOT_EQUAL: 2436 + - dst_ar = EQUAL_FLAG; 2437 + - break; 2438 + 2439 + default: 2440 + SLJIT_ASSERT_STOP(); 2441 + @@ -2180,11 +2156,11 @@ 2442 + if (op >= SLJIT_ADD) { 2443 + if (TMP_REG2_mapped != dst_ar) 2444 + FAIL_IF(ADD(TMP_REG2_mapped, dst_ar, ZERO)); 2445 + - return emit_op(compiler, op | flags, CUMULATIVE_OP | LOGICAL_OP | IMM_OP | ALT_KEEP_CACHE, dst, dstw, src, srcw, TMP_REG2, 0); 2446 + + return emit_op(compiler, op | flags, mem_type | CUMULATIVE_OP | LOGICAL_OP | IMM_OP | ALT_KEEP_CACHE, dst, dstw, src, srcw, TMP_REG2, 0); 2447 + } 2448 + 2449 + if (dst & SLJIT_MEM) 2450 + - return emit_op_mem(compiler, WORD_DATA, dst_ar, dst, dstw); 2451 + + return emit_op_mem(compiler, mem_type, dst_ar, dst, dstw); 2452 + 2453 + if (sugg_dst_ar != dst_ar) 2454 + return ADD(sugg_dst_ar, dst_ar, ZERO); 2455 + @@ -2194,7 +2170,7 @@ 2456 + 2457 + SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op) { 2458 + CHECK_ERROR(); 2459 + - check_sljit_emit_op0(compiler, op); 2460 + + CHECK(check_sljit_emit_op0(compiler, op)); 2461 + 2462 + op = GET_OPCODE(op); 2463 + switch (op) { 2464 + @@ -2204,10 +2180,10 @@ 2465 + case SLJIT_BREAKPOINT: 2466 + return PI(BPT); 2467 + 2468 + - case SLJIT_UMUL: 2469 + - case SLJIT_SMUL: 2470 + - case SLJIT_UDIV: 2471 + - case SLJIT_SDIV: 2472 + + case SLJIT_LUMUL: 2473 + + case SLJIT_LSMUL: 2474 + + case SLJIT_UDIVI: 2475 + + case SLJIT_SDIVI: 2476 + SLJIT_ASSERT_STOP(); 2477 + } 2478 + 2479 + @@ -2217,7 +2193,7 @@ 2480 + 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) 2481 + { 2482 + CHECK_ERROR(); 2483 + - check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw); 2484 + + CHECK(check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw)); 2485 + ADJUST_LOCAL_OFFSET(dst, dstw); 2486 + ADJUST_LOCAL_OFFSET(src, srcw); 2487 + 2488 + @@ -2273,7 +2249,7 @@ 2489 + return emit_op(compiler, SLJIT_SUB | GET_ALL_FLAGS(op), IMM_OP, dst, dstw, SLJIT_IMM, 0, src, srcw); 2490 + 2491 + case SLJIT_CLZ: 2492 + - return emit_op(compiler, op, 0, dst, dstw, TMP_REG1, 0, src, srcw); 2493 + + return emit_op(compiler, op, (op & SLJIT_INT_OP) ? INT_DATA : WORD_DATA, dst, dstw, TMP_REG1, 0, src, srcw); 2494 + } 2495 + 2496 + return SLJIT_SUCCESS; 2497 + @@ -2282,7 +2258,7 @@ 2498 + 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) 2499 + { 2500 + CHECK_ERROR(); 2501 + - check_sljit_emit_op2(compiler, op, dst, dstw, src1, src1w, src2, src2w); 2502 + + CHECK(check_sljit_emit_op2(compiler, op, dst, dstw, src1, src1w, src2, src2w)); 2503 + ADJUST_LOCAL_OFFSET(dst, dstw); 2504 + ADJUST_LOCAL_OFFSET(src1, src1w); 2505 + ADJUST_LOCAL_OFFSET(src2, src2w); 2506 + @@ -2325,7 +2301,7 @@ 2507 + flush_buffer(compiler); 2508 + 2509 + CHECK_ERROR_PTR(); 2510 + - check_sljit_emit_label(compiler); 2511 + + CHECK_PTR(check_sljit_emit_label(compiler)); 2512 + 2513 + if (compiler->last_label && compiler->last_label->size == compiler->size) 2514 + return compiler->last_label; 2515 + @@ -2344,7 +2320,7 @@ 2516 + flush_buffer(compiler); 2517 + 2518 + CHECK_ERROR(); 2519 + - check_sljit_emit_ijump(compiler, type, src, srcw); 2520 + + CHECK(check_sljit_emit_ijump(compiler, type, src, srcw)); 2521 + ADJUST_LOCAL_OFFSET(src, srcw); 2522 + 2523 + if (FAST_IS_REG(src)) { 2524 + @@ -2404,8 +2380,10 @@ 2525 + 2526 + return SLJIT_SUCCESS; 2527 + 2528 + - } else if (src & SLJIT_MEM) 2529 + + } else if (src & SLJIT_MEM) { 2530 + FAIL_IF(emit_op(compiler, SLJIT_MOV, WORD_DATA, TMP_REG2, 0, TMP_REG1, 0, src, srcw)); 2531 + + flush_buffer(compiler); 2532 + + } 2533 + 2534 + FAIL_IF(JR_SOLO(reg_map[src_r])); 2535 + 2536 + @@ -2432,7 +2410,7 @@ 2537 + flush_buffer(compiler); 2538 + 2539 + CHECK_ERROR_PTR(); 2540 + - check_sljit_emit_jump(compiler, type); 2541 + + CHECK_PTR(check_sljit_emit_jump(compiler, type)); 2542 + 2543 + jump = (struct sljit_jump *)ensure_abuf(compiler, sizeof(struct sljit_jump)); 2544 + PTR_FAIL_IF(!jump); 2545 + @@ -2440,48 +2418,42 @@ 2546 + type &= 0xff; 2547 + 2548 + switch (type) { 2549 + - case SLJIT_C_EQUAL: 2550 + - case SLJIT_C_FLOAT_NOT_EQUAL: 2551 + + case SLJIT_EQUAL: 2552 + BR_NZ(EQUAL_FLAG); 2553 + break; 2554 + - case SLJIT_C_NOT_EQUAL: 2555 + - case SLJIT_C_FLOAT_EQUAL: 2556 + + case SLJIT_NOT_EQUAL: 2557 + BR_Z(EQUAL_FLAG); 2558 + break; 2559 + - case SLJIT_C_LESS: 2560 + - case SLJIT_C_FLOAT_LESS: 2561 + + case SLJIT_LESS: 2562 + BR_Z(ULESS_FLAG); 2563 + break; 2564 + - case SLJIT_C_GREATER_EQUAL: 2565 + - case SLJIT_C_FLOAT_GREATER_EQUAL: 2566 + + case SLJIT_GREATER_EQUAL: 2567 + BR_NZ(ULESS_FLAG); 2568 + break; 2569 + - case SLJIT_C_GREATER: 2570 + - case SLJIT_C_FLOAT_GREATER: 2571 + + case SLJIT_GREATER: 2572 + BR_Z(UGREATER_FLAG); 2573 + break; 2574 + - case SLJIT_C_LESS_EQUAL: 2575 + - case SLJIT_C_FLOAT_LESS_EQUAL: 2576 + + case SLJIT_LESS_EQUAL: 2577 + BR_NZ(UGREATER_FLAG); 2578 + break; 2579 + - case SLJIT_C_SIG_LESS: 2580 + + case SLJIT_SIG_LESS: 2581 + BR_Z(LESS_FLAG); 2582 + break; 2583 + - case SLJIT_C_SIG_GREATER_EQUAL: 2584 + + case SLJIT_SIG_GREATER_EQUAL: 2585 + BR_NZ(LESS_FLAG); 2586 + break; 2587 + - case SLJIT_C_SIG_GREATER: 2588 + + case SLJIT_SIG_GREATER: 2589 + BR_Z(GREATER_FLAG); 2590 + break; 2591 + - case SLJIT_C_SIG_LESS_EQUAL: 2592 + + case SLJIT_SIG_LESS_EQUAL: 2593 + BR_NZ(GREATER_FLAG); 2594 + break; 2595 + - case SLJIT_C_OVERFLOW: 2596 + - case SLJIT_C_MUL_OVERFLOW: 2597 + + case SLJIT_OVERFLOW: 2598 + + case SLJIT_MUL_OVERFLOW: 2599 + BR_Z(OVERFLOW_FLAG); 2600 + break; 2601 + - case SLJIT_C_NOT_OVERFLOW: 2602 + - case SLJIT_C_MUL_NOT_OVERFLOW: 2603 + + case SLJIT_NOT_OVERFLOW: 2604 + + case SLJIT_MUL_NOT_OVERFLOW: 2605 + BR_NZ(OVERFLOW_FLAG); 2606 + break; 2607 + default: 2608 + @@ -2536,7 +2508,7 @@ 2609 + flush_buffer(compiler); 2610 + 2611 + CHECK_ERROR_PTR(); 2612 + - check_sljit_emit_const(compiler, dst, dstw, init_value); 2613 + + CHECK_PTR(check_sljit_emit_const(compiler, dst, dstw, init_value)); 2614 + ADJUST_LOCAL_OFFSET(dst, dstw); 2615 + 2616 + const_ = (struct sljit_const *)ensure_abuf(compiler, sizeof(struct sljit_const)); 2617 + @@ -2572,3 +2544,18 @@ 2618 + inst[3] = (inst[3] & ~(0xFFFFL << 43)) | ((new_constant & 0xFFFFL) << 43); 2619 + SLJIT_CACHE_FLUSH(inst, inst + 4); 2620 + } 2621 + + 2622 + +SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg) 2623 + +{ 2624 + + CHECK_REG_INDEX(check_sljit_get_register_index(reg)); 2625 + + return reg_map[reg]; 2626 + +} 2627 + + 2628 + +SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler, 2629 + + void *instruction, sljit_si size) 2630 + +{ 2631 + + CHECK_ERROR(); 2632 + + CHECK(check_sljit_emit_op_custom(compiler, instruction, size)); 2633 + + return SLJIT_ERR_UNSUPPORTED; 2634 + +} 2635 + + 2636 + Index: pcregrep.c 2637 + =================================================================== 2638 + --- pcregrep.c (revision 1554) 2639 + +++ pcregrep.c (working copy) 2640 + @@ -1692,9 +1692,13 @@ 2641 + 2642 + if (filenames == FN_NOMATCH_ONLY) return 1; 2643 + 2644 + + /* If all we want is a yes/no answer, stop now. */ 2645 + + 2646 + + if (quiet) return 0; 2647 + + 2648 + /* Just count if just counting is wanted. */ 2649 + 2650 + - if (count_only) count++; 2651 + + else if (count_only) count++; 2652 + 2653 + /* When handling a binary file and binary-files==binary, the "binary" 2654 + variable will be set true (it's false in all other cases). In this 2655 + @@ -1715,10 +1719,6 @@ 2656 + return 0; 2657 + } 2658 + 2659 + - /* Likewise, if all we want is a yes/no answer. */ 2660 + - 2661 + - else if (quiet) return 0; 2662 + - 2663 + /* The --only-matching option prints just the substring that matched, 2664 + and/or one or more captured portions of it, as long as these strings are 2665 + not empty. The --file-offsets and --line-offsets options output offsets for 2666 + @@ -2089,7 +2089,7 @@ 2667 + 2668 + /* Print the match count if wanted */ 2669 + 2670 + -if (count_only) 2671 + +if (count_only && !quiet) 2672 + { 2673 + if (count > 0 || !omit_zero_count) 2674 + { 2675 + Index: pcre_study.c 2676 + =================================================================== 2677 + --- pcre_study.c (revision 1554) 2678 + +++ pcre_study.c (working copy) 2679 + @@ -71,6 +71,7 @@ 2680 + startcode pointer to start of the whole pattern's code 2681 + options the compiling options 2682 + recurses chain of recurse_check to catch mutual recursion 2683 + + countptr pointer to call count (to catch over complexity) 2684 + 2685 + Returns: the minimum length 2686 + -1 if \C in UTF-8 mode or (*ACCEPT) was encountered 2687 + @@ -80,7 +81,8 @@ 2688 + 2689 + static int 2690 + find_minlength(const REAL_PCRE *re, const pcre_uchar *code, 2691 + - const pcre_uchar *startcode, int options, recurse_check *recurses) 2692 + + const pcre_uchar *startcode, int options, recurse_check *recurses, 2693 + + int *countptr) 2694 + { 2695 + int length = -1; 2696 + /* PCRE_UTF16 has the same value as PCRE_UTF8. */ 2697 + @@ -90,6 +92,8 @@ 2698 + register int branchlength = 0; 2699 + register pcre_uchar *cc = (pcre_uchar *)code + 1 + LINK_SIZE; 2700 + 2701 + +if ((*countptr)++ > 1000) return -1; /* too complex */ 2702 + + 2703 + if (*code == OP_CBRA || *code == OP_SCBRA || 2704 + *code == OP_CBRAPOS || *code == OP_SCBRAPOS) cc += IMM2_SIZE; 2705 + 2706 + @@ -131,7 +135,7 @@ 2707 + case OP_SBRAPOS: 2708 + case OP_ONCE: 2709 + case OP_ONCE_NC: 2710 + - d = find_minlength(re, cc, startcode, options, recurses); 2711 + + d = find_minlength(re, cc, startcode, options, recurses, countptr); 2712 + if (d < 0) return d; 2713 + branchlength += d; 2714 + do cc += GET(cc, 1); while (*cc == OP_ALT); 2715 + @@ -415,7 +419,8 @@ 2716 + int dd; 2717 + this_recurse.prev = recurses; 2718 + this_recurse.group = cs; 2719 + - dd = find_minlength(re, cs, startcode, options, &this_recurse); 2720 + + dd = find_minlength(re, cs, startcode, options, &this_recurse, 2721 + + countptr); 2722 + if (dd < d) d = dd; 2723 + } 2724 + } 2725 + @@ -451,7 +456,8 @@ 2726 + { 2727 + this_recurse.prev = recurses; 2728 + this_recurse.group = cs; 2729 + - d = find_minlength(re, cs, startcode, options, &this_recurse); 2730 + + d = find_minlength(re, cs, startcode, options, &this_recurse, 2731 + + countptr); 2732 + } 2733 + } 2734 + } 2735 + @@ -514,7 +520,7 @@ 2736 + this_recurse.prev = recurses; 2737 + this_recurse.group = cs; 2738 + branchlength += find_minlength(re, cs, startcode, options, 2739 + - &this_recurse); 2740 + + &this_recurse, countptr); 2741 + } 2742 + } 2743 + cc += 1 + LINK_SIZE; 2744 + @@ -1453,6 +1459,7 @@ 2745 + #endif 2746 + { 2747 + int min; 2748 + +int count = 0; 2749 + BOOL bits_set = FALSE; 2750 + pcre_uint8 start_bits[32]; 2751 + PUBL(extra) *extra = NULL; 2752 + @@ -1539,7 +1546,7 @@ 2753 + 2754 + /* Find the minimum length of subject string. */ 2755 + 2756 + -switch(min = find_minlength(re, code, code, re->options, NULL)) 2757 + +switch(min = find_minlength(re, code, code, re->options, NULL, &count)) 2758 + { 2759 + case -2: *errorptr = "internal error: missing capturing bracket"; return NULL; 2760 + case -3: *errorptr = "internal error: opcode not recognized"; return NULL; 2761 + Index: pcre_internal.h 2762 + =================================================================== 2763 + --- pcre_internal.h (revision 1554) 2764 + +++ pcre_internal.h (working copy) 2765 + @@ -984,7 +984,7 @@ 2766 + #ifndef EBCDIC 2767 + 2768 + #define HSPACE_LIST \ 2769 + - CHAR_HT, CHAR_SPACE, 0xa0, \ 2770 + + CHAR_HT, CHAR_SPACE, CHAR_NBSP, \ 2771 + 0x1680, 0x180e, 0x2000, 0x2001, 0x2002, 0x2003, 0x2004, 0x2005, \ 2772 + 0x2006, 0x2007, 0x2008, 0x2009, 0x200A, 0x202f, 0x205f, 0x3000, \ 2773 + NOTACHAR 2774 + @@ -1010,7 +1010,7 @@ 2775 + #define HSPACE_BYTE_CASES \ 2776 + case CHAR_HT: \ 2777 + case CHAR_SPACE: \ 2778 + - case 0xa0 /* NBSP */ 2779 + + case CHAR_NBSP 2780 + 2781 + #define HSPACE_CASES \ 2782 + HSPACE_BYTE_CASES: \ 2783 + @@ -1037,11 +1037,12 @@ 2784 + /* ------ EBCDIC environments ------ */ 2785 + 2786 + #else 2787 + -#define HSPACE_LIST CHAR_HT, CHAR_SPACE 2788 + +#define HSPACE_LIST CHAR_HT, CHAR_SPACE, CHAR_NBSP, NOTACHAR 2789 + 2790 + #define HSPACE_BYTE_CASES \ 2791 + case CHAR_HT: \ 2792 + - case CHAR_SPACE 2793 + + case CHAR_SPACE: \ 2794 + + case CHAR_NBSP 2795 + 2796 + #define HSPACE_CASES HSPACE_BYTE_CASES 2797 + 2798 + @@ -1215,6 +1216,7 @@ 2799 + 2800 + #define CHAR_ESC '\047' 2801 + #define CHAR_DEL '\007' 2802 + +#define CHAR_NBSP '\x41' 2803 + #define STR_ESC "\047" 2804 + #define STR_DEL "\007" 2805 + 2806 + @@ -1229,6 +1231,7 @@ 2807 + #define CHAR_NEL ((unsigned char)'\x85') 2808 + #define CHAR_ESC '\033' 2809 + #define CHAR_DEL '\177' 2810 + +#define CHAR_NBSP ((unsigned char)'\xa0') 2811 + 2812 + #define STR_LF "\n" 2813 + #define STR_NL STR_LF 2814 + @@ -1606,6 +1609,7 @@ 2815 + #define CHAR_VERTICAL_LINE '\174' 2816 + #define CHAR_RIGHT_CURLY_BRACKET '\175' 2817 + #define CHAR_TILDE '\176' 2818 + +#define CHAR_NBSP ((unsigned char)'\xa0') 2819 + 2820 + #define STR_HT "\011" 2821 + #define STR_VT "\013" 2822 + @@ -1762,6 +1766,10 @@ 2823 + 2824 + /* Escape items that are just an encoding of a particular data value. */ 2825 + 2826 + +#ifndef ESC_a 2827 + +#define ESC_a CHAR_BEL 2828 + +#endif 2829 + + 2830 + #ifndef ESC_e 2831 + #define ESC_e CHAR_ESC 2832 + #endif 2833 + @@ -2446,6 +2454,7 @@ 2834 + BOOL had_pruneorskip; /* (*PRUNE) or (*SKIP) encountered */ 2835 + BOOL check_lookbehind; /* Lookbehinds need later checking */ 2836 + BOOL dupnames; /* Duplicate names exist */ 2837 + + BOOL dupgroups; /* Duplicate groups exist: (?| found */ 2838 + BOOL iscondassert; /* Next assert is a condition */ 2839 + int nltype; /* Newline type */ 2840 + int nllen; /* Newline string length */ 2841 + Index: pcre_exec.c 2842 + =================================================================== 2843 + --- pcre_exec.c (revision 1554) 2844 + +++ pcre_exec.c (working copy) 2845 + @@ -6685,7 +6685,8 @@ 2846 + register int *iend = iptr - re->top_bracket; 2847 + if (iend < md->offset_vector + 2) iend = md->offset_vector + 2; 2848 + while (--iptr >= iend) *iptr = -1; 2849 + - md->offset_vector[0] = md->offset_vector[1] = -1; 2850 + + if (offsetcount > 0) md->offset_vector[0] = -1; 2851 + + if (offsetcount > 1) md->offset_vector[1] = -1; 2852 + } 2853 + 2854 + /* Set up the first character to match, if available. The first_char value is 2855 + Index: pcre_jit_test.c 2856 + =================================================================== 2857 + --- pcre_jit_test.c (revision 1554) 2858 + +++ pcre_jit_test.c (working copy) 2859 + @@ -182,6 +182,7 @@ 2860 + { CMUAP, 0, "\xf0\x90\x90\x80{2}", "\xf0\x90\x90\x80#\xf0\x90\x90\xa8\xf0\x90\x90\x80" }, 2861 + { CMUAP, 0, "\xf0\x90\x90\xa8{2}", "\xf0\x90\x90\x80#\xf0\x90\x90\xa8\xf0\x90\x90\x80" }, 2862 + { CMUAP, 0, "\xe1\xbd\xb8\xe1\xbf\xb8", "\xe1\xbf\xb8\xe1\xbd\xb8" }, 2863 + + { MA, 0, "[3-57-9]", "5" }, 2864 + 2865 + /* Assertions. */ 2866 + { MUA, 0, "\\b[^A]", "A_B#" }, 2867 + Index: configure.ac 2868 + =================================================================== 2869 + --- configure.ac (revision 1554) 2870 + +++ configure.ac (working copy) 2871 + @@ -9,9 +9,9 @@ 2872 + dnl be defined as -RC2, for example. For real releases, it should be empty. 2873 + 2874 + m4_define(pcre_major, [8]) 2875 + -m4_define(pcre_minor, [37]) 2876 + -m4_define(pcre_prerelease, []) 2877 + -m4_define(pcre_date, [2015-04-28]) 2878 + +m4_define(pcre_minor, [38]) 2879 + +m4_define(pcre_prerelease, [-RC1]) 2880 + +m4_define(pcre_date, [2015-05-03]) 2881 + 2882 + # NOTE: The CMakeLists.txt file searches for the above variables in the first 2883 + # 50 lines of this file. Please update that if the variables above are moved. 2884 + Index: doc/pcrepattern.3 2885 + =================================================================== 2886 + --- doc/pcrepattern.3 (revision 1554) 2887 + +++ doc/pcrepattern.3 (working copy) 2888 + @@ -1,4 +1,4 @@ 2889 + -.TH PCREPATTERN 3 "08 January 2014" "PCRE 8.35" 2890 + +.TH PCREPATTERN 3 "14 June 2015" "PCRE 8.38" 2891 + .SH NAME 2892 + PCRE - Perl-compatible regular expressions 2893 + .SH "PCRE REGULAR EXPRESSION DETAILS" 2894 + @@ -308,7 +308,8 @@ 2895 + in patterns in a visible manner. There is no restriction on the appearance of 2896 + non-printing characters, apart from the binary zero that terminates a pattern, 2897 + but when a pattern is being prepared by text editing, it is often easier to use 2898 + -one of the following escape sequences than the binary character it represents: 2899 + +one of the following escape sequences than the binary character it represents. 2900 + +In an ASCII or Unicode environment, these escapes are as follows: 2901 + .sp 2902 + \ea alarm, that is, the BEL character (hex 07) 2903 + \ecx "control-x", where x is any ASCII character 2904 + @@ -330,19 +331,31 @@ 2905 + but \ec{ becomes hex 3B ({ is 7B), and \ec; becomes hex 7B (; is 3B). If the 2906 + data item (byte or 16-bit value) following \ec has a value greater than 127, a 2907 + compile-time error occurs. This locks out non-ASCII characters in all modes. 2908 + +.P 2909 + +When PCRE is compiled in EBCDIC mode, \ea, \ee, \ef, \en, \er, and \et 2910 + +generate the appropriate EBCDIC code values. The \ec escape is processed 2911 + +as specified for Perl in the \fBperlebcdic\fP document. The only characters 2912 + +that are allowed after \ec are A-Z, a-z, or one of @, [, \e, ], ^, _, or ?. Any 2913 + +other character provokes a compile-time error. The sequence \e@ encodes 2914 + +character code 0; the letters (in either case) encode characters 1-26 (hex 01 2915 + +to hex 1A); [, \e, ], ^, and _ encode characters 27-31 (hex 1B to hex 1F), and 2916 + +\e? becomes either 255 (hex FF) or 95 (hex 5F). 2917 + .P 2918 + -The \ec facility was designed for use with ASCII characters, but with the 2919 + -extension to Unicode it is even less useful than it once was. It is, however, 2920 + -recognized when PCRE is compiled in EBCDIC mode, where data items are always 2921 + -bytes. In this mode, all values are valid after \ec. If the next character is a 2922 + -lower case letter, it is converted to upper case. Then the 0xc0 bits of the 2923 + -byte are inverted. Thus \ecA becomes hex 01, as in ASCII (A is C1), but because 2924 + -the EBCDIC letters are disjoint, \ecZ becomes hex 29 (Z is E9), and other 2925 + -characters also generate different values. 2926 + +Thus, apart from \e?, these escapes generate the same character code values as 2927 + +they do in an ASCII environment, though the meanings of the values mostly 2928 + +differ. For example, \eG always generates code value 7, which is BEL in ASCII 2929 + +but DEL in EBCDIC. 2930 + .P 2931 + +The sequence \e? generates DEL (127, hex 7F) in an ASCII environment, but 2932 + +because 127 is not a control character in EBCDIC, Perl makes it generate the 2933 + +APC character. Unfortunately, there are several variants of EBCDIC. In most of 2934 + +them the APC character has the value 255 (hex FF), but in the one Perl calls 2935 + +POSIX-BC its value is 95 (hex 5F). If certain other characters have POSIX-BC 2936 + +values, PCRE makes \e? generate 95; otherwise it generates 255. 2937 + +.P 2938 + After \e0 up to two further octal digits are read. If there are fewer than two 2939 + -digits, just those that are present are used. Thus the sequence \e0\ex\e07 2940 + -specifies two binary zeros followed by a BEL character (code value 7). Make 2941 + +digits, just those that are present are used. Thus the sequence \e0\ex\e015 2942 + +specifies two binary zeros followed by a CR character (code value 13). Make 2943 + sure you supply two digits after the initial zero if the pattern character that 2944 + follows is itself an octal digit. 2945 + .P 2946 + @@ -3283,6 +3296,6 @@ 2947 + .rs 2948 + .sp 2949 + .nf 2950 + -Last updated: 08 January 2014 2951 + -Copyright (c) 1997-2014 University of Cambridge. 2952 + +Last updated: 14 June 2015 2953 + +Copyright (c) 1997-2015 University of Cambridge. 2954 + .fi 2955 + Index: testdata/testoutput11-32 2956 + =================================================================== 2957 + --- testdata/testoutput11-32 (revision 1554) 2958 + +++ testdata/testoutput11-32 (working copy) 2959 + @@ -231,7 +231,7 @@ 2960 + ------------------------------------------------------------------ 2961 + 2962 + /(?P<a>a)...(?P=a)bbb(?P>a)d/BM 2963 + -Memory allocation (code space): 125 2964 + +Memory allocation (code space): 157 2965 + ------------------------------------------------------------------ 2966 + 0 24 Bra 2967 + 2 5 CBra 1 2968 + @@ -748,4 +748,21 @@ 2969 + 22 End 2970 + ------------------------------------------------------------------ 2971 + 2972 + +/.((?2)(?R)\1)()/B 2973 + +------------------------------------------------------------------ 2974 + + 0 23 Bra 2975 + + 2 Any 2976 + + 3 13 Once 2977 + + 5 9 CBra 1 2978 + + 8 18 Recurse 2979 + + 10 0 Recurse 2980 + + 12 \1 2981 + + 14 9 Ket 2982 + + 16 13 Ket 2983 + + 18 3 CBra 2 2984 + + 21 3 Ket 2985 + + 23 23 Ket 2986 + + 25 End 2987 + +------------------------------------------------------------------ 2988 + + 2989 + /-- End of testinput11 --/ 2990 + Index: testdata/testinputEBC 2991 + =================================================================== 2992 + --- testdata/testinputEBC (revision 1554) 2993 + +++ testdata/testinputEBC (working copy) 2994 + @@ -29,13 +29,16 @@ 2995 + 2996 + /^A\�/ 2997 + A B 2998 + + A\x41B 2999 + 3000 + /-- Test \H --/ 3001 + 3002 + /^A\�/ 3003 + AB 3004 + + A\x42B 3005 + ** Fail 3006 + A B 3007 + + A\x41B 3008 + 3009 + /-- Test \R --/ 3010 + 3011 + Index: testdata/testoutput1 3012 + =================================================================== 3013 + --- testdata/testoutput1 (revision 1554) 3014 + +++ testdata/testoutput1 (working copy) 3015 + @@ -9429,4 +9429,9 @@ 3016 + 0: aaaaaaaaa 3017 + 1: a 3018 + 3019 + +"(?|(\k'Pm')|(?'Pm'))" 3020 + + abcd 3021 + + 0: 3022 + + 1: 3023 + + 3024 + /-- End of testinput1 --/ 3025 + Index: testdata/testoutput2 3026 + =================================================================== 3027 + --- testdata/testoutput2 (revision 1554) 3028 + +++ testdata/testoutput2 (working copy) 3029 + @@ -5614,9 +5614,9 @@ 3030 + 123456\P 3031 + No match 3032 + 3033 + -//KF>/dev/null 3034 + -Compiled pattern written to /dev/null 3035 + -Study data written to /dev/null 3036 + +//KF>testsavedregex 3037 + +Compiled pattern written to testsavedregex 3038 + +Study data written to testsavedregex 3039 + 3040 + /abc/IS>testsavedregex 3041 + Capturing subpattern count = 0 3042 + @@ -9135,10 +9135,10 @@ 3043 + Failed: subpattern name expected at offset 3 3044 + 3045 + /\k/ 3046 + -Failed: \k is not followed by a braced, angle-bracketed, or quoted name at offset 2 3047 + +Failed: \k is not followed by a braced, angle-bracketed, or quoted name at offset 1 3048 + 3049 + /\kabc/ 3050 + -Failed: \k is not followed by a braced, angle-bracketed, or quoted name at offset 5 3051 + +Failed: \k is not followed by a braced, angle-bracketed, or quoted name at offset 1 3052 + 3053 + /(?P=)/ 3054 + Failed: subpattern name expected at offset 4 3055 + @@ -9186,7 +9186,7 @@ 3056 + Failed: unknown POSIX class name at offset 3 3057 + 3058 + /(^(a|b\g<-1'c))/ 3059 + -Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 15 3060 + +Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 8 3061 + 3062 + /^(?+1)(?<a>x|y){0}z/ 3063 + xzxx 3064 + @@ -14098,10 +14098,10 @@ 3065 + Failed: group name must start with a non-digit at offset 4 3066 + 3067 + /\g'3gh'/ 3068 + -Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 7 3069 + +Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 2 3070 + 3071 + /\g<5fg>/ 3072 + -Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 7 3073 + +Failed: \g is not followed by a braced, angle-bracketed, or quoted name/number or by a plain number at offset 2 3074 + 3075 + /(?(<4gh>)abc)/ 3076 + Failed: group name must start with a non-digit at offset 4 3077 + @@ -14423,4 +14423,146 @@ 3078 + 3079 + /((?2){73}(?2))((?1))/ 3080 + 3081 + +/.((?2)(?R)\1)()/BZ 3082 + +------------------------------------------------------------------ 3083 + + Bra 3084 + + Any 3085 + + Once 3086 + + CBra 1 3087 + + Recurse 3088 + + Recurse 3089 + + \1 3090 + + Ket 3091 + + Ket 3092 + + CBra 2 3093 + + Ket 3094 + + Ket 3095 + + End 3096 + +------------------------------------------------------------------ 3097 + + 3098 + +/(?1)()((((((\1++))\x85)+)|))/ 3099 + + 3100 + +/(\9*+(?2);\3++()2|)++{/ 3101 + +Failed: reference to non-existent subpattern at offset 22 3102 + + 3103 + +/\V\x85\9*+((?2)\3++()2)*:2/ 3104 + +Failed: reference to non-existent subpattern at offset 26 3105 + + 3106 + +/(((?(R)){0,2}) (?''((?'R')((?'R')))))/J 3107 + + 3108 + +/(((?(X)){0,2}) (?''((?'X')((?'X')))))/J 3109 + + 3110 + +/(((?(R)){0,2}) (?''((?'X')((?'R')))))/ 3111 + + 3112 + +"(?J)(?'d'(?'d'\g{d}))" 3113 + + 3114 + +".*?\h.+.\.+\R*?\xd(?i)(?=!(?=b`b`b`\`b\xa9b!)`\a`bbbbbbbbbbbbb`bbbbbbbbbbbb*R\x85bbbbbbb\C?{((?2)(?))(( 3115 + +\H){8(?<=(?1){29}\xa8bbbb\x16\xd\xc6^($(?<! )(\xa9H4){4}h}1)B))\x15')" 3116 + + 3117 + +"(?J:(?|(?'R')(\k'R')|((?'R'))))" 3118 + + 3119 + +/(?<=|(\,\$(?73591620449005828816)\xa8.{7}){6}\x09)/ 3120 + +Failed: number is too big at offset 32 3121 + + 3122 + +// 3123 + +\O1 3124 + +Matched, but too many substrings 3125 + + 3126 + +/^(?:(?(1)x|)+)+$()/BZ 3127 + +------------------------------------------------------------------ 3128 + + Bra 3129 + + ^ 3130 + + SBra 3131 + + SCond 3132 + + 1 Cond ref 3133 + + x 3134 + + Alt 3135 + + KetRmax 3136 + + KetRmax 3137 + + $ 3138 + + CBra 1 3139 + + Ket 3140 + + Ket 3141 + + End 3142 + +------------------------------------------------------------------ 3143 + + 3144 + +/(?=di(?<=(?1))|(?=(.))))/ 3145 + +Failed: unmatched parentheses at offset 23 3146 + + 3147 + +/(?(R))*+/BZ 3148 + +------------------------------------------------------------------ 3149 + + Bra 3150 + + Braposzero 3151 + + SBraPos 3152 + + SCond 3153 + + Cond recurse any 3154 + + Ket 3155 + + KetRpos 3156 + + Ket 3157 + + End 3158 + +------------------------------------------------------------------ 3159 + + 3160 + +/[[:\\](?'abc')[a:]/ 3161 + + 3162 + +"[[[.\xe8Nq\xffq\xff\xe0\x2|||::Nq\xffq\xff\xe0\x6\x2|||::[[[:[::::::[[[[[::::::::[:[[[:[:::[[[[[[[[[[[[:::::::::::::::::[[.\xe8Nq\xffq\xff\xe0\x2|||::Nq\xffq\xff\xe0\x6\x2|||::[[[:[::::::[[[[[::::::::[:[[[:[:::[[[[[[[[[[[[[[:::E[[[:[:[[:[:::[[:::E[[[:[:[[:'[:::::E[[[:[::::::[[[:[[[[[[[::E[[[:[::::::[[[:[[[[[[[[:[[::[::::[[:::::::[[:[[[[[[[:[[::[:[[:[~" 3163 + +Failed: missing terminating ] for character class at offset 353 3164 + + 3165 + +/()(?(R)0)*+/BZ 3166 + +------------------------------------------------------------------ 3167 + + Bra 3168 + + CBra 1 3169 + + Ket 3170 + + Braposzero 3171 + + SBraPos 3172 + + SCond 3173 + + Cond recurse any 3174 + + 0 3175 + + Ket 3176 + + KetRpos 3177 + + Ket 3178 + + End 3179 + +------------------------------------------------------------------ 3180 + + 3181 + +/(?R-:(?</ 3182 + +Failed: (?R or (?[+-]digits must be followed by ) at offset 3 3183 + + 3184 + +/(?1){3918}(((((0(\k'R'))))(?J)(?'R'(?'R'\3){99})))/I 3185 + +Capturing subpattern count = 8 3186 + +Max back reference = 8 3187 + +Named capturing subpatterns: 3188 + + R 7 3189 + + R 8 3190 + +No options 3191 + +Duplicate name status changes 3192 + +No first char 3193 + +Need char = '0' 3194 + + 3195 + +/(?J:(?|(:(?|(?'R')(\k'R')|((?'R')))H'Rk'Rf)|s(?'R')))/ 3196 + + 3197 + +/0(?0)|(1)(*THEN)(*SKIP:0)(*FAIL)/ 3198 + + 01 3199 + +No match 3200 + + 3201 + +/((?(R8000000000)))/ 3202 + +Failed: number is too big at offset 16 3203 + + 3204 + +/(?(8000000000/ 3205 + +Failed: number is too big at offset 13 3206 + + 3207 + +/(?:ab)?(?:ab)(?:ab)/ 3208 + + abab 3209 + + 0: abab 3210 + + ababab 3211 + + 0: ababab 3212 + + aba 3213 + +No match 3214 + + 3215 + +/((*MARK:A))++a(*SKIP:B)b/ 3216 + + aacb 3217 + +No match 3218 + + 3219 + +/(?J:(?|(:(?|(?'R')(\z(?|(?'R')(\k'R')|((?'R')))k'R')|((?'R')))H'Ak'Rf)|s(?'R')))/ 3220 + + 3221 + +/(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?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a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?<a>1)/ 3222 + + 3223 + /-- End of testinput2 --/ 3224 + Index: testdata/testoutput11-16 3225 + =================================================================== 3226 + --- testdata/testoutput11-16 (revision 1554) 3227 + +++ testdata/testoutput11-16 (working copy) 3228 + @@ -231,7 +231,7 @@ 3229 + ------------------------------------------------------------------ 3230 + 3231 + /(?P<a>a)...(?P=a)bbb(?P>a)d/BM 3232 + -Memory allocation (code space): 61 3233 + +Memory allocation (code space): 77 3234 + ------------------------------------------------------------------ 3235 + 0 24 Bra 3236 + 2 5 CBra 1 3237 + @@ -748,4 +748,21 @@ 3238 + 22 End 3239 + ------------------------------------------------------------------ 3240 + 3241 + +/.((?2)(?R)\1)()/B 3242 + +------------------------------------------------------------------ 3243 + + 0 23 Bra 3244 + + 2 Any 3245 + + 3 13 Once 3246 + + 5 9 CBra 1 3247 + + 8 18 Recurse 3248 + + 10 0 Recurse 3249 + + 12 \1 3250 + + 14 9 Ket 3251 + + 16 13 Ket 3252 + + 18 3 CBra 2 3253 + + 21 3 Ket 3254 + + 23 23 Ket 3255 + + 25 End 3256 + +------------------------------------------------------------------ 3257 + + 3258 + /-- End of testinput11 --/ 3259 + Index: testdata/testoutput6 3260 + =================================================================== 3261 + --- testdata/testoutput6 (revision 1554) 3262 + +++ testdata/testoutput6 (working copy) 3263 + @@ -2469,4 +2469,8 @@ 3264 + Ӆ\x0aT 3265 + No match 3266 + 3267 + +/[\pS#moq]/ 3268 + + = 3269 + + 0: = 3270 + + 3271 + /-- End of testinput6 --/ 3272 + Index: testdata/testinput11 3273 + =================================================================== 3274 + --- testdata/testinput11 (revision 1554) 3275 + +++ testdata/testinput11 (working copy) 3276 + @@ -136,4 +136,6 @@ 3277 + 3278 + /((?+1)(\1))/B 3279 + 3280 + +/.((?2)(?R)\1)()/B 3281 + + 3282 + /-- End of testinput11 --/ 3283 + Index: testdata/testinput12 3284 + =================================================================== 3285 + --- testdata/testinput12 (revision 1554) 3286 + +++ testdata/testinput12 (working copy) 3287 + @@ -8,6 +8,8 @@ 3288 + 3289 + /(?(?C1)(?=a)a)/S!+I 3290 + 3291 + +/b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*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b*b*b*/S+I 3292 + + 3293 + /abc/S+I>testsavedregex 3294 + 3295 + <testsavedregex 3296 + @@ -95,4 +97,11 @@ 3297 + 3298 + /(a(?:a|b|c|d|e)b){8,16}/S++ 3299 + 3300 + +/(?:|a|){100}x/S++ 3301 + + 3302 + +/(x(?1)){4}/S++ 3303 + + 3304 + +/(.|.)*?bx/ 3305 + + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabax 3306 + + 3307 + /-- End of testinput12 --/ 3308 + Index: testdata/testoutput12 3309 + =================================================================== 3310 + --- testdata/testoutput12 (revision 1554) 3311 + +++ testdata/testoutput12 (working copy) 3312 + @@ -30,6 +30,15 @@ 3313 + No starting char list 3314 + JIT study was not successful 3315 + 3316 + +/b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b*b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 + +No need char 3322 + +Study returned NULL 3323 + +JIT study was not successful 3324 + + 3325 + /abc/S+I>testsavedregex 3326 + Capturing subpattern count = 0 3327 + No options 3328 + @@ -184,4 +193,12 @@ 3329 + 3330 + /(a(?:a|b|c|d|e)b){8,16}/S++ 3331 + 3332 + +/(?:|a|){100}x/S++ 3333 + + 3334 + +/(x(?1)){4}/S++ 3335 + + 3336 + +/(.|.)*?bx/ 3337 + + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabax 3338 + +Error -8 (match limit exceeded) 3339 + + 3340 + /-- End of testinput12 --/ 3341 + Index: testdata/testoutput11-8 3342 + =================================================================== 3343 + --- testdata/testoutput11-8 (revision 1554) 3344 + +++ testdata/testoutput11-8 (working copy) 3345 + @@ -231,7 +231,7 @@ 3346 + ------------------------------------------------------------------ 3347 + 3348 + /(?P<a>a)...(?P=a)bbb(?P>a)d/BM 3349 + -Memory allocation (code space): 38 3350 + +Memory allocation (code space): 50 3351 + ------------------------------------------------------------------ 3352 + 0 30 Bra 3353 + 3 7 CBra 1 3354 + @@ -748,4 +748,21 @@ 3355 + 34 End 3356 + ------------------------------------------------------------------ 3357 + 3358 + +/.((?2)(?R)\1)()/B 3359 + +------------------------------------------------------------------ 3360 + + 0 35 Bra 3361 + + 3 Any 3362 + + 4 20 Once 3363 + + 7 14 CBra 1 3364 + + 12 27 Recurse 3365 + + 15 0 Recurse 3366 + + 18 \1 3367 + + 21 14 Ket 3368 + + 24 20 Ket 3369 + + 27 5 CBra 2 3370 + + 32 5 Ket 3371 + + 35 35 Ket 3372 + + 38 End 3373 + +------------------------------------------------------------------ 3374 + + 3375 + /-- End of testinput11 --/ 3376 + Index: testdata/testoutputEBC 3377 + =================================================================== 3378 + --- testdata/testoutputEBC (revision 1554) 3379 + +++ testdata/testoutputEBC (working copy) 3380 + @@ -41,6 +41,8 @@ 3381 + /^A\�/ 3382 + A B 3383 + 0: A\x20 3384 + + A\x41B 3385 + + 0: AA 3386 + 3387 + /-- Test \H --/ 3388 + 3389 + @@ -47,10 +49,14 @@ 3390 + /^A\�/ 3391 + AB 3392 + 0: AB 3393 + + A\x42B 3394 + + 0: AB 3395 + ** Fail 3396 + No match 3397 + A B 3398 + No match 3399 + + A\x41B 3400 + +No match 3401 + 3402 + /-- Test \R --/ 3403 + 3404 + Index: testdata/grepoutput 3405 + =================================================================== 3406 + --- testdata/grepoutput (revision 1554) 3407 + +++ testdata/grepoutput (working copy) 3408 + @@ -751,3 +751,7 @@ 3409 + 2:3,1 3410 + 2:4,1 3411 + RC=0 3412 + +---------------------------- Test 108 ------------------------------ 3413 + +RC=0 3414 + +---------------------------- Test 109 ----------------------------- 3415 + +RC=0 3416 + Index: testdata/testinput1 3417 + =================================================================== 3418 + --- testdata/testinput1 (revision 1554) 3419 + +++ testdata/testinput1 (working copy) 3420 + @@ -5730,4 +5730,7 @@ 3421 + "(?1)(?#?'){8}(a)" 3422 + baaaaaaaaac 3423 + 3424 + +"(?|(\k'Pm')|(?'Pm'))" 3425 + + abcd 3426 + + 3427 + /-- End of testinput1 --/ 3428 + Index: testdata/testinput2 3429 + =================================================================== 3430 + --- testdata/testinput2 (revision 1554) 3431 + +++ testdata/testinput2 (working copy) 3432 + @@ -1380,7 +1380,7 @@ 3433 + 1X 3434 + 123456\P 3435 + 3436 + -//KF>/dev/null 3437 + +//KF>testsavedregex 3438 + 3439 + /abc/IS>testsavedregex 3440 + <testsavedregex 3441 + @@ -4152,4 +4152,67 @@ 3442 + 3443 + /((?2){73}(?2))((?1))/ 3444 + 3445 + +/.((?2)(?R)\1)()/BZ 3446 + + 3447 + +/(?1)()((((((\1++))\x85)+)|))/ 3448 + + 3449 + +/(\9*+(?2);\3++()2|)++{/ 3450 + + 3451 + +/\V\x85\9*+((?2)\3++()2)*:2/ 3452 + + 3453 + +/(((?(R)){0,2}) (?''((?'R')((?'R')))))/J 3454 + + 3455 + +/(((?(X)){0,2}) (?''((?'X')((?'X')))))/J 3456 + + 3457 + +/(((?(R)){0,2}) (?''((?'X')((?'R')))))/ 3458 + + 3459 + +"(?J)(?'d'(?'d'\g{d}))" 3460 + + 3461 + +".*?\h.+.\.+\R*?\xd(?i)(?=!(?=b`b`b`\`b\xa9b!)`\a`bbbbbbbbbbbbb`bbbbbbbbbbbb*R\x85bbbbbbb\C?{((?2)(?))(( 3462 + +\H){8(?<=(?1){29}\xa8bbbb\x16\xd\xc6^($(?<! )(\xa9H4){4}h}1)B))\x15')" 3463 + + 3464 + +"(?J:(?|(?'R')(\k'R')|((?'R'))))" 3465 + + 3466 + +/(?<=|(\,\$(?73591620449005828816)\xa8.{7}){6}\x09)/ 3467 + + 3468 + +// 3469 + +\O1 3470 + + 3471 + +/^(?:(?(1)x|)+)+$()/BZ 3472 + + 3473 + +/(?=di(?<=(?1))|(?=(.))))/ 3474 + + 3475 + +/(?(R))*+/BZ 3476 + + 3477 + +/[[:\\](?'abc')[a:]/ 3478 + + 3479 + +"[[[.\xe8Nq\xffq\xff\xe0\x2|||::Nq\xffq\xff\xe0\x6\x2|||::[[[:[::::::[[[[[::::::::[:[[[:[:::[[[[[[[[[[[[:::::::::::::::::[[.\xe8Nq\xffq\xff\xe0\x2|||::Nq\xffq\xff\xe0\x6\x2|||::[[[:[::::::[[[[[::::::::[:[[[:[:::[[[[[[[[[[[[[[:::E[[[:[:[[:[:::[[:::E[[[:[:[[:'[:::::E[[[:[::::::[[[:[[[[[[[::E[[[:[::::::[[[:[[[[[[[[:[[::[::::[[:::::::[[:[[[[[[[:[[::[:[[:[~" 3480 + + 3481 + +/()(?(R)0)*+/BZ 3482 + + 3483 + +/(?R-:(?</ 3484 + + 3485 + +/(?1){3918}(((((0(\k'R'))))(?J)(?'R'(?'R'\3){99})))/I 3486 + + 3487 + +/(?J:(?|(:(?|(?'R')(\k'R')|((?'R')))H'Rk'Rf)|s(?'R')))/ 3488 + + 3489 + +/0(?0)|(1)(*THEN)(*SKIP:0)(*FAIL)/ 3490 + + 01 3491 + + 3492 + +/((?(R8000000000)))/ 3493 + + 3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(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?&a)(?<a>1)/ 3507 + + 3508 + /-- End of testinput2 --/ 3509 + Index: testdata/testinput6 3510 + =================================================================== 3511 + --- testdata/testinput6 (revision 1554) 3512 + +++ testdata/testinput6 (working copy) 3513 + @@ -1502,4 +1502,7 @@ 3514 + /\C\X*QT/8 3515 + Ӆ\x0aT 3516 + 3517 + +/[\pS#moq]/ 3518 + + = 3519 + + 3520 + /-- End of testinput6 --/ 3521 + Index: NON-AUTOTOOLS-BUILD 3522 + =================================================================== 3523 + --- NON-AUTOTOOLS-BUILD (revision 1554) 3524 + +++ NON-AUTOTOOLS-BUILD (working copy) 3525 + @@ -764,9 +764,9 @@ 3526 + 3527 + http://www.zaconsultants.net 3528 + 3529 + -There is also a mirror here: 3530 + +You may download PCRE from WWW.CBTTAPE.ORG, file 882.  Everything, source and 3531 + +executable, is in EBCDIC and native z/OS file formats and this is the 3532 + +recommended download site. 3533 + 3534 + - http://www.vsoft-software.com/downloads.html 3535 + - 3536 + ========================== 3537 + -Last Updated: 10 February 2015 3538 + +Last Updated: 25 June 2015
+2 -2
pkgs/development/tools/build-managers/cmake/default.nix
··· 11 let 12 os = stdenv.lib.optionalString; 13 majorVersion = "3.3"; 14 - minorVersion = "1"; 15 version = "${majorVersion}.${minorVersion}"; 16 in 17 ··· 22 23 src = fetchurl { 24 url = "${meta.homepage}files/v${majorVersion}/cmake-${version}.tar.gz"; 25 - sha256 = "1mp32dqywk4dfw7zmpgp31axszv7h74yk69g273z21q7d8n04rfd"; 26 }; 27 28 enableParallelBuilding = true;
··· 11 let 12 os = stdenv.lib.optionalString; 13 majorVersion = "3.3"; 14 + minorVersion = "2"; 15 version = "${majorVersion}.${minorVersion}"; 16 in 17 ··· 22 23 src = fetchurl { 24 url = "${meta.homepage}files/v${majorVersion}/cmake-${version}.tar.gz"; 25 + sha256 = "08pwy9ip9cgwgynhn5vrjw8drw29gijy1rmziq22n65zds6ifnp7"; 26 }; 27 28 enableParallelBuilding = true;
+3 -3
pkgs/development/tools/misc/autogen/default.nix
··· 2 3 stdenv.mkDerivation rec { 4 name = "autogen-${version}"; 5 - version = "5.18.5"; 6 7 src = fetchurl { 8 - url = "mirror://gnu/autogen/rel${version}/autogen-${version}.tar.gz"; 9 - sha256 = "1flnbnmkbqmbfgammkl8m36wrlk6rhpgnf9pdm6gdfhqalxvggbv"; 10 }; 11 12 nativeBuildInputs = [ which pkgconfig perl ];
··· 2 3 stdenv.mkDerivation rec { 4 name = "autogen-${version}"; 5 + version = "5.18.6"; 6 7 src = fetchurl { 8 + url = "mirror://gnu/autogen/rel${version}/autogen-${version}.tar.xz"; 9 + sha256 = "0sfmmy19k9z0j3f738fyk6ljf6b66410cvd5zzyplxi2683j10qs"; 10 }; 11 12 nativeBuildInputs = [ which pkgconfig perl ];
+2 -4
pkgs/os-specific/darwin/apple-sdk/default.nix
··· 120 __propagatedImpureHostDeps = [ "/usr/lib/libXplugin.1.dylib" ]; 121 122 propagatedBuildInputs = with frameworks; [ 123 - OpenGL ApplicationServices Carbon IOKit CoreFoundation CoreGraphics CoreServices CoreText 124 ]; 125 126 installPhase = '' ··· 144 }; 145 }; 146 147 - frameworks = (stdenv.lib.mapAttrs framework (import ./frameworks.nix { inherit frameworks libs; })) // { 148 - CoreFoundation = CF; 149 - }; 150 151 inherit sdk; 152 }
··· 120 __propagatedImpureHostDeps = [ "/usr/lib/libXplugin.1.dylib" ]; 121 122 propagatedBuildInputs = with frameworks; [ 123 + OpenGL ApplicationServices Carbon IOKit CF CoreGraphics CoreServices CoreText 124 ]; 125 126 installPhase = '' ··· 144 }; 145 }; 146 147 + frameworks = stdenv.lib.mapAttrs framework (import ./frameworks.nix { inherit frameworks libs CF; }); 148 149 inherit sdk; 150 }
+38 -38
pkgs/os-specific/darwin/apple-sdk/frameworks.nix
··· 2 # Epic weird knot-tying happening here. 3 # TODO: clean up the process for generating this and include it 4 5 - { frameworks, libs }: 6 7 with frameworks; with libs; { 8 AGL = [ Carbon OpenGL ]; 9 AVFoundation = [ ApplicationServices CoreGraphics ]; 10 AVKit = []; 11 Accounts = []; 12 - AddressBook = [ Carbon CoreFoundation ]; 13 AppKit = [ AudioToolbox QuartzCore ]; 14 AppKitScripting = []; 15 AppleScriptKit = []; 16 AppleScriptObjC = []; 17 AppleShareClientCore = [ CoreServices ]; 18 - AudioToolbox = [ AudioUnit CoreAudio CoreFoundation CoreMIDI ]; 19 - AudioUnit = [ Carbon CoreAudio CoreFoundation ]; 20 AudioVideoBridging = [ Foundation ]; 21 Automator = []; 22 - CFNetwork = [ CoreFoundation ]; 23 CalendarStore = []; 24 Cocoa = []; 25 Collaboration = []; 26 - CoreAudio = [ CoreFoundation IOKit ]; 27 CoreAudioKit = [ AudioUnit ]; 28 CoreData = []; 29 - CoreGraphics = [ Accelerate CoreFoundation IOKit IOSurface SystemConfiguration ]; 30 CoreLocation = []; 31 - CoreMIDI = [ CoreFoundation ]; 32 CoreMIDIServer = []; 33 - CoreMedia = [ ApplicationServices AudioToolbox CoreAudio CoreFoundation CoreGraphics CoreVideo ]; 34 - CoreMediaIO = [ CoreFoundation CoreMedia ]; 35 - CoreText = [ CoreFoundation CoreGraphics ]; 36 - CoreVideo = [ ApplicationServices CoreFoundation CoreGraphics IOSurface OpenGL ]; 37 CoreWLAN = [ SecurityFoundation ]; 38 DVComponentGlue = [ CoreServices QuickTime ]; 39 DVDPlayback = []; 40 - DirectoryService = [ CoreFoundation ]; 41 - DiscRecording = [ CoreFoundation CoreServices IOKit ]; 42 DiscRecordingUI = []; 43 - DiskArbitration = [ CoreFoundation IOKit ]; 44 DrawSprocket = [ Carbon ]; 45 EventKit = []; 46 ExceptionHandling = []; 47 FWAUserLib = []; 48 - ForceFeedback = [ CoreFoundation IOKit ]; 49 - Foundation = [ CoreFoundation Security ApplicationServices AppKit SystemConfiguration ]; 50 - GLKit = [ CoreFoundation ]; 51 GLUT = [ GL OpenGL ]; 52 GSS = []; 53 GameController = []; 54 GameKit = [ Foundation ]; 55 - ICADevices = [ Carbon CoreFoundation IOBluetooth ]; 56 IMServicePlugIn = []; 57 IOBluetoothUI = [ IOBluetooth ]; 58 - IOKit = [ CoreFoundation ]; 59 - IOSurface = [ CoreFoundation IOKit xpc ]; 60 ImageCaptureCore = []; 61 - ImageIO = [ CoreFoundation CoreGraphics ]; 62 InputMethodKit = [ Carbon ]; 63 InstallerPlugins = []; 64 InstantMessage = []; 65 JavaFrameEmbedding = []; 66 - JavaScriptCore = [ CoreFoundation ]; 67 Kerberos = []; 68 - Kernel = [ CoreFoundation IOKit ]; 69 LDAP = []; 70 - LatentSemanticMapping = [ Carbon CoreFoundation ]; 71 MapKit = []; 72 - MediaAccessibility = [ CoreFoundation CoreGraphics CoreText QuartzCore ]; 73 - MediaToolbox = [ AudioToolbox CoreFoundation CoreMedia ]; 74 - NetFS = [ CoreFoundation ]; 75 OSAKit = [ Carbon ]; 76 OpenAL = []; 77 OpenCL = [ IOSurface OpenGL ]; ··· 81 PubSub = []; 82 Python = [ ApplicationServices ]; 83 QTKit = [ QuickTime ]; 84 - QuickLook = [ ApplicationServices CoreFoundation ]; 85 QuickTime = [ ApplicationServices AudioUnit Carbon CoreAudio CoreServices OpenGL QuartzCore ]; 86 Ruby = []; 87 RubyCocoa = []; ··· 89 ScreenSaver = []; 90 Scripting = []; 91 ScriptingBridge = []; 92 - Security = [ CoreFoundation IOKit ]; 93 SecurityFoundation = []; 94 SecurityInterface = [ Security ]; 95 - ServiceManagement = [ CoreFoundation Security ]; 96 Social = []; 97 SpriteKit = []; 98 StoreKit = []; 99 SyncServices = []; 100 - SystemConfiguration = [ CoreFoundation Security ]; 101 TWAIN = [ Carbon ]; 102 Tcl = []; 103 Tk = [ ApplicationServices Carbon X11 ]; 104 - VideoDecodeAcceleration = [ CoreFoundation CoreVideo ]; 105 - VideoToolbox = [ CoreFoundation CoreMedia CoreVideo ]; 106 WebKit = [ ApplicationServices Carbon JavaScriptCore OpenGL X11 ]; 107 108 # Umbrellas 109 Accelerate = [ CoreWLAN IOBluetooth ]; 110 - ApplicationServices = [ CoreFoundation CoreServices CoreText ImageIO ]; 111 - Carbon = [ ApplicationServices CoreFoundation CoreServices IOKit Security QuartzCore ]; 112 CoreBluetooth = []; 113 - CoreServices = [ CFNetwork CoreAudio CoreData CoreFoundation DiskArbitration Security NetFS OpenDirectory ServiceManagement ]; 114 IOBluetooth = [ IOKit ]; 115 JavaVM = []; 116 OpenDirectory = []; 117 Quartz = [ QuickLook ]; 118 - QuartzCore = [ ApplicationServices CoreFoundation CoreVideo OpenCL ]; 119 }
··· 2 # Epic weird knot-tying happening here. 3 # TODO: clean up the process for generating this and include it 4 5 + { frameworks, libs, CF }: 6 7 with frameworks; with libs; { 8 AGL = [ Carbon OpenGL ]; 9 AVFoundation = [ ApplicationServices CoreGraphics ]; 10 AVKit = []; 11 Accounts = []; 12 + AddressBook = [ Carbon CF ]; 13 AppKit = [ AudioToolbox QuartzCore ]; 14 AppKitScripting = []; 15 AppleScriptKit = []; 16 AppleScriptObjC = []; 17 AppleShareClientCore = [ CoreServices ]; 18 + AudioToolbox = [ AudioUnit CoreAudio CF CoreMIDI ]; 19 + AudioUnit = [ Carbon CoreAudio CF ]; 20 AudioVideoBridging = [ Foundation ]; 21 Automator = []; 22 + CFNetwork = [ CF ]; 23 CalendarStore = []; 24 Cocoa = []; 25 Collaboration = []; 26 + CoreAudio = [ CF IOKit ]; 27 CoreAudioKit = [ AudioUnit ]; 28 CoreData = []; 29 + CoreGraphics = [ Accelerate CF IOKit IOSurface SystemConfiguration ]; 30 CoreLocation = []; 31 + CoreMIDI = [ CF ]; 32 CoreMIDIServer = []; 33 + CoreMedia = [ ApplicationServices AudioToolbox CoreAudio CF CoreGraphics CoreVideo ]; 34 + CoreMediaIO = [ CF CoreMedia ]; 35 + CoreText = [ CF CoreGraphics ]; 36 + CoreVideo = [ ApplicationServices CF CoreGraphics IOSurface OpenGL ]; 37 CoreWLAN = [ SecurityFoundation ]; 38 DVComponentGlue = [ CoreServices QuickTime ]; 39 DVDPlayback = []; 40 + DirectoryService = [ CF ]; 41 + DiscRecording = [ CF CoreServices IOKit ]; 42 DiscRecordingUI = []; 43 + DiskArbitration = [ CF IOKit ]; 44 DrawSprocket = [ Carbon ]; 45 EventKit = []; 46 ExceptionHandling = []; 47 FWAUserLib = []; 48 + ForceFeedback = [ CF IOKit ]; 49 + Foundation = [ CF Security ApplicationServices AppKit SystemConfiguration ]; 50 + GLKit = [ CF ]; 51 GLUT = [ GL OpenGL ]; 52 GSS = []; 53 GameController = []; 54 GameKit = [ Foundation ]; 55 + ICADevices = [ Carbon CF IOBluetooth ]; 56 IMServicePlugIn = []; 57 IOBluetoothUI = [ IOBluetooth ]; 58 + IOKit = [ CF ]; 59 + IOSurface = [ CF IOKit xpc ]; 60 ImageCaptureCore = []; 61 + ImageIO = [ CF CoreGraphics ]; 62 InputMethodKit = [ Carbon ]; 63 InstallerPlugins = []; 64 InstantMessage = []; 65 JavaFrameEmbedding = []; 66 + JavaScriptCore = [ CF ]; 67 Kerberos = []; 68 + Kernel = [ CF IOKit ]; 69 LDAP = []; 70 + LatentSemanticMapping = [ Carbon CF ]; 71 MapKit = []; 72 + MediaAccessibility = [ CF CoreGraphics CoreText QuartzCore ]; 73 + MediaToolbox = [ AudioToolbox CF CoreMedia ]; 74 + NetFS = [ CF ]; 75 OSAKit = [ Carbon ]; 76 OpenAL = []; 77 OpenCL = [ IOSurface OpenGL ]; ··· 81 PubSub = []; 82 Python = [ ApplicationServices ]; 83 QTKit = [ QuickTime ]; 84 + QuickLook = [ ApplicationServices CF ]; 85 QuickTime = [ ApplicationServices AudioUnit Carbon CoreAudio CoreServices OpenGL QuartzCore ]; 86 Ruby = []; 87 RubyCocoa = []; ··· 89 ScreenSaver = []; 90 Scripting = []; 91 ScriptingBridge = []; 92 + Security = [ CF IOKit ]; 93 SecurityFoundation = []; 94 SecurityInterface = [ Security ]; 95 + ServiceManagement = [ CF Security ]; 96 Social = []; 97 SpriteKit = []; 98 StoreKit = []; 99 SyncServices = []; 100 + SystemConfiguration = [ CF Security ]; 101 TWAIN = [ Carbon ]; 102 Tcl = []; 103 Tk = [ ApplicationServices Carbon X11 ]; 104 + VideoDecodeAcceleration = [ CF CoreVideo ]; 105 + VideoToolbox = [ CF CoreMedia CoreVideo ]; 106 WebKit = [ ApplicationServices Carbon JavaScriptCore OpenGL X11 ]; 107 108 # Umbrellas 109 Accelerate = [ CoreWLAN IOBluetooth ]; 110 + ApplicationServices = [ CF CoreServices CoreText ImageIO ]; 111 + Carbon = [ ApplicationServices CF CoreServices IOKit Security QuartzCore ]; 112 CoreBluetooth = []; 113 + CoreServices = [ CFNetwork CoreAudio CoreData CF DiskArbitration Security NetFS OpenDirectory ServiceManagement ]; 114 IOBluetooth = [ IOKit ]; 115 JavaVM = []; 116 OpenDirectory = []; 117 Quartz = [ QuickLook ]; 118 + QuartzCore = [ ApplicationServices CF CoreVideo OpenCL ]; 119 }
-3
pkgs/os-specific/darwin/apple-sdk/impure-deps.nix
··· 6 ]; 7 IOKit = [ 8 "/System/Library/Frameworks/IOKit.framework" 9 - "/usr/lib/libenergytrace.dylib" 10 ]; 11 DiskArbitration = [ 12 "/System/Library/Frameworks/DiskArbitration.framework" ··· 31 "/System/Library/PrivateFrameworks/DataDetectorsCore.framework/Versions/A/DataDetectorsCore" 32 "/System/Library/PrivateFrameworks/TCC.framework/Versions/A/TCC" 33 "/System/Library/PrivateFrameworks/LanguageModeling.framework/Versions/A/LanguageModeling" 34 - "/usr/lib/libChineseTokenizer.dylib" 35 - "/usr/lib/libmarisa.dylib" 36 "/usr/lib/libmecabra.dylib" 37 "/usr/lib/libcmph.dylib" 38 "/usr/lib/libiconv.2.dylib"
··· 6 ]; 7 IOKit = [ 8 "/System/Library/Frameworks/IOKit.framework" 9 ]; 10 DiskArbitration = [ 11 "/System/Library/Frameworks/DiskArbitration.framework" ··· 30 "/System/Library/PrivateFrameworks/DataDetectorsCore.framework/Versions/A/DataDetectorsCore" 31 "/System/Library/PrivateFrameworks/TCC.framework/Versions/A/TCC" 32 "/System/Library/PrivateFrameworks/LanguageModeling.framework/Versions/A/LanguageModeling" 33 "/usr/lib/libmecabra.dylib" 34 "/usr/lib/libcmph.dylib" 35 "/usr/lib/libiconv.2.dylib"
+3 -2
pkgs/os-specific/darwin/apple-source-releases/CF/default.nix
··· 47 ''; 48 49 postInstall = '' 50 - # gross! convince apple to release this as part of CF 51 - cp /System/Library/Frameworks/CoreFoundation.framework/Headers/CFAttributedString.h "$out/System/Library/Frameworks/CoreFoundation.framework/Headers" 52 53 mv $out/System/* $out 54 rmdir $out/System
··· 47 ''; 48 49 postInstall = '' 50 + # gross! convince apple to release these as part of CF 51 + cp /System/Library/Frameworks/CoreFoundation.framework/Headers/{CFAttributedString,CFNotificationCenter}.h \ 52 + "$out/System/Library/Frameworks/CoreFoundation.framework/Headers" 53 54 mv $out/System/* $out 55 rmdir $out/System
+2 -2
pkgs/os-specific/darwin/cctools/port.nix
··· 1 - { stdenv, fetchurl, autoconf, automake, libtool 2 , llvm, libcxx, libcxxabi, clang, openssl, libuuid 3 , libobjc ? null 4 }: ··· 18 sha256 = "01f31ijpnplbiyp7ldwzy8vbkn3j3m56n5blsvsav5nlp4lp2g71"; 19 }; 20 21 - buildInputs = [ autoconf automake libtool openssl libuuid ] ++ 22 # Only need llvm and clang if the stdenv isn't already clang-based (TODO: just make a stdenv.cc.isClang) 23 stdenv.lib.optionals (!stdenv.isDarwin) [ llvm clang ] ++ 24 stdenv.lib.optionals stdenv.isDarwin [ libcxxabi libobjc ];
··· 1 + { stdenv, fetchurl, autoconf, automake, libtool_2 2 , llvm, libcxx, libcxxabi, clang, openssl, libuuid 3 , libobjc ? null 4 }: ··· 18 sha256 = "01f31ijpnplbiyp7ldwzy8vbkn3j3m56n5blsvsav5nlp4lp2g71"; 19 }; 20 21 + buildInputs = [ autoconf automake libtool_2 openssl libuuid ] ++ 22 # Only need llvm and clang if the stdenv isn't already clang-based (TODO: just make a stdenv.cc.isClang) 23 stdenv.lib.optionals (!stdenv.isDarwin) [ llvm clang ] ++ 24 stdenv.lib.optionals stdenv.isDarwin [ libcxxabi libobjc ];
+4
pkgs/servers/x11/xorg/overrides.nix
··· 93 outputs = [ "out" "man" ]; 94 }; 95 96 libXfont = attrs: attrs // { 97 propagatedBuildInputs = [ args.freetype ]; # propagate link reqs. like bzip2 98 # prevents "misaligned_stack_error_entering_dyld_stub_binder"
··· 93 outputs = [ "out" "man" ]; 94 }; 95 96 + libAppleWM = attrs: attrs // { 97 + propagatedBuildInputs = [ args.apple_sdk.frameworks.ApplicationServices ]; 98 + }; 99 + 100 libXfont = attrs: attrs // { 101 propagatedBuildInputs = [ args.freetype ]; # propagate link reqs. like bzip2 102 # prevents "misaligned_stack_error_entering_dyld_stub_binder"
-15
pkgs/tools/archivers/cpio/darwin-fix.patch
··· 1 - Fix Darwin builds. 2 - 3 - From <http://git.savannah.gnu.org/cgit/cpio.git/commit/?id=3a7a1820d4cecbd77c7b74c785af5942510bf080>. 4 - See also <http://lists.gnu.org/archive/html/bug-cpio/2010-07/msg00001.html>. 5 - 6 - diff --git a/src/filetypes.h b/src/filetypes.h 7 - index f80faab..81f0c32 100644 8 - --- a/src/filetypes.h 9 - +++ b/src/filetypes.h 10 - @@ -81,5 +81,3 @@ 11 - #ifndef S_ISLNK 12 - #define lstat stat 13 - #endif 14 - -int lstat (); 15 - -int stat ();
···
+15 -19
pkgs/tools/archivers/cpio/default.nix
··· 1 { stdenv, fetchurl, fetchpatch }: 2 3 - stdenv.mkDerivation { 4 - name = "cpio-2.11"; 5 6 src = fetchurl { 7 - url = mirror://gnu/cpio/cpio-2.11.tar.bz2; 8 - sha256 = "bb820bfd96e74fc6ce43104f06fe733178517e7f5d1cdee553773e8eff7d5bbd"; 9 }; 10 11 patches = [ 12 - ./no-gets.patch 13 (fetchpatch { 14 - name = "CVE-2014-9112.diff"; 15 - url = "http://pkgs.fedoraproject.org/cgit/cpio.git/plain/cpio-2.11" 16 - + "-CVE-2014-9112.patch?h=f21&id=b475b4d6f31c95e073edc95c742a33a39ef4ec95"; 17 - sha256 = "0c9yrysvpwbmiq7ph84dk6mv46hddiyvkgya1zsmj76n9ypb1b4i"; 18 }) 19 - ] ++ stdenv.lib.optional stdenv.isDarwin ./darwin-fix.patch; 20 - 21 - postPatch = let pp = 22 - fetchpatch { 23 - name = "CVE-2015-1197.diff"; 24 - url = "https://marc.info/?l=oss-security&m=142289947619786&w=2"; 25 - sha256 = "0fr95bj416zfljv40fl1sh50059d18wdmfgaq8ad2fqi5cnbk859"; 26 - }; 27 - # one "<" and one "&" sign get mangled in the patch 28 - in "cat ${pp} | sed 's/&lt;/</;s/&amp;/\\&/' | patch -p1"; 29 30 preConfigure = if stdenv.isCygwin then '' 31 sed -i gnu/fpending.h -e 's,include <stdio_ext.h>,,' 32 '' else null; 33 34 meta = { 35 homepage = http://www.gnu.org/software/cpio/;
··· 1 { stdenv, fetchurl, fetchpatch }: 2 3 + let 4 + version = "2.12"; 5 + name = "cpio-${version}"; 6 + in stdenv.mkDerivation { 7 + inherit name; 8 9 src = fetchurl { 10 + url = "mirror://gnu/cpio/${name}.tar.bz2"; 11 + sha256 = "0vi9q475h1rki53100zml75vxsykzyhrn70hidy41s5c2rc8r6bh"; 12 }; 13 14 patches = [ 15 (fetchpatch { 16 + name = "CVE-2015-1197-cpio-2.12.patch"; 17 + url = "https://gist.github.com/nckx/70b0bfa80ddfb86c2967/" 18 + + "raw/e9b40d4d4b701f584f826775b75beb10751dc884/" 19 + + "CVE-2015-1197-cpio-2.12.patch"; 20 + sha256 = "0ph43m4lavwkc4gnl5h9p3da4kb1pnhwk5l2qsky70dqri8pcr8v"; 21 }) 22 + ]; 23 24 preConfigure = if stdenv.isCygwin then '' 25 sed -i gnu/fpending.h -e 's,include <stdio_ext.h>,,' 26 '' else null; 27 + 28 + enableParallelBuilding = true; 29 30 meta = { 31 homepage = http://www.gnu.org/software/cpio/;
-24
pkgs/tools/archivers/cpio/no-gets.patch
··· 1 - https://bugs.gentoo.org/424974 2 - 3 - hack until gzip pulls a newer gnulib version 4 - 5 - From 66712c23388e93e5c518ebc8515140fa0c807348 Mon Sep 17 00:00:00 2001 6 - From: Eric Blake <eblake@redhat.com> 7 - Date: Thu, 29 Mar 2012 13:30:41 -0600 8 - Subject: [PATCH] stdio: don't assume gets any more 9 - 10 - Gnulib intentionally does not have a gets module, and now that C11 11 - and glibc have dropped it, we should be more proactive about warning 12 - any user on a platform that still has a declaration of this dangerous 13 - interface. 14 - 15 - --- a/gnu/stdio.in.h 16 - +++ b/gnu/stdio.in.h 17 - @@ -125,7 +125,6 @@ 18 - so any use of gets warrants an unconditional warning. Assume it is 19 - always declared, since it is required by C89. */ 20 - #undef gets 21 - -_GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead"); 22 - 23 - #if @GNULIB_FOPEN@ 24 - # if @REPLACE_FOPEN@
···
+28 -23
pkgs/top-level/all-packages.nix
··· 258 autonix = import ../build-support/autonix { inherit pkgs; }; 259 260 autoreconfHook = makeSetupHook 261 - { substitutions = { inherit autoconf automake libtool gettext; }; } 262 ../build-support/setup-hooks/autoreconf.sh; 263 264 buildEnv = callPackage ../build-support/buildenv {}; ··· 1044 cksfv = callPackage ../tools/networking/cksfv { }; 1045 1046 clementine = callPackage ../applications/audio/clementine { 1047 - boost = boost156; 1048 gst_plugins = [ gst_plugins_base gst_plugins_good gst_plugins_ugly gst_ffmpeg ]; 1049 }; 1050 ··· 1695 1696 calamares = callPackage ../tools/misc/calamares rec { 1697 python = python3; 1698 - boost = callPackage ../development/libraries/boost/1.57.nix { python=python3; }; 1699 libyamlcpp = callPackage ../development/libraries/libyaml-cpp { makePIC=true; boost=boost; }; 1700 inherit (kf5_stable) extra-cmake-modules kconfig ki18n kcoreaddons solid; 1701 }; ··· 2008 2009 nodejs-0_12 = callPackage ../development/web/nodejs { 2010 libuv = libuvVersions.v1_6_1; 2011 - libtool = darwin.cctools; 2012 }; 2013 nodejs-0_10 = callPackage ../development/web/nodejs/v0_10.nix { 2014 - libtool = darwin.cctools; 2015 inherit (darwin.apple_sdk.frameworks) CoreServices ApplicationServices Carbon Foundation; 2016 }; 2017 ··· 5576 5577 lemon = callPackage ../development/tools/parsing/lemon { }; 5578 5579 - libtool = libtool_2; 5580 5581 libtool_1_5 = callPackage ../development/tools/misc/libtool { }; 5582 ··· 5781 texi2html = callPackage ../development/tools/misc/texi2html { }; 5782 5783 uhd = callPackage ../development/tools/misc/uhd { 5784 - boost = boost157; 5785 }; 5786 5787 uisp = callPackage ../development/tools/misc/uisp { }; ··· 5911 boolstuff = callPackage ../development/libraries/boolstuff { }; 5912 5913 boost155 = callPackage ../development/libraries/boost/1.55.nix { }; 5914 - boost156 = callPackage ../development/libraries/boost/1.56.nix { }; 5915 - boost157 = callPackage ../development/libraries/boost/1.57.nix { }; 5916 - boost158 = callPackage ../development/libraries/boost/1.58.nix { }; 5917 boost159 = callPackage ../development/libraries/boost/1.59.nix { }; 5918 boost = boost159; 5919 ··· 6193 6194 fontconfig-ultimate = callPackage ../development/libraries/fontconfig-ultimate {}; 6195 6196 - folly = callPackage ../development/libraries/folly { 6197 - boost = boost157; 6198 - }; 6199 6200 makeFontsConf = let fontconfig_ = fontconfig; in {fontconfig ? fontconfig_, fontDirectories}: 6201 callPackage ../development/libraries/fontconfig/make-fonts-conf.nix { ··· 6397 6398 qt_gstreamer = callPackage ../development/libraries/gstreamer/legacy/qt-gstreamer {}; 6399 6400 - qt_gstreamer1 = callPackage ../development/libraries/gstreamer/qt-gstreamer { boost = boost156;}; 6401 6402 gnet = callPackage ../development/libraries/gnet { }; 6403 ··· 8529 lucene = callPackage ../development/libraries/java/lucene { }; 8530 8531 lucenepp = callPackage ../development/libraries/lucene++ { 8532 - boost = boost157; 8533 }; 8534 8535 mockobjects = callPackage ../development/libraries/java/mockobjects { }; ··· 9141 rethinkdb = callPackage ../servers/nosql/rethinkdb { }; 9142 9143 rippled = callPackage ../servers/rippled { 9144 - boost = boost157; 9145 }; 9146 9147 ripple-rest = callPackage ../servers/rippled/ripple-rest.nix { }; ··· 9255 quartz-wm = callPackage ../servers/x11/quartz-wm { stdenv = clangStdenv; }; 9256 9257 xorg = recurseIntoAttrs (lib.callPackagesWith pkgs ../servers/x11/xorg/default.nix { 9258 bootstrap_cmds = if stdenv.isDarwin then darwin.bootstrap_cmds else null; 9259 mesa = mesa_noglu; 9260 udev = if stdenv.isLinux then udev else null; ··· 10653 schismtracker = callPackage ../applications/audio/schismtracker { }; 10654 10655 altcoins = recurseIntoAttrs ( callPackage ../applications/altcoins { 10656 - callPackage = newScope { boost = boost157; }; 10657 } ); 10658 bitcoin = altcoins.bitcoin; 10659 bitcoin-xt = altcoins.bitcoin-xt; ··· 11009 imagemagick = null; 11010 acl = null; 11011 gpm = null; 11012 }; 11013 11014 emacs24-nox = lowPrio (appendToName "nox" (emacs24.override { ··· 11375 fomp = callPackage ../applications/audio/fomp { }; 11376 11377 freecad = callPackage ../applications/graphics/freecad { 11378 - boost = boost156; 11379 opencascade = opencascade_6_5; 11380 inherit (pythonPackages) matplotlib pycollada; 11381 }; ··· 11398 }; 11399 11400 freicoin = callPackage ../applications/misc/freicoin { 11401 - boost = boost157; 11402 }; 11403 11404 fuze = callPackage ../applications/networking/instant-messengers/fuze {}; ··· 11848 11849 ledger2 = callPackage ../applications/office/ledger/2.6.3.nix { }; 11850 ledger3 = callPackage ../applications/office/ledger { 11851 - boost = boost157; 11852 }; 11853 ledger = ledger3; 11854 ··· 13864 { 13865 libusb = libusb1; 13866 libcanberra = libcanberra_kde; 13867 - boost = boost156; 13868 kdelibs = kdeApps_stable.kdelibs; 13869 } 13870 ../desktops/kde-4.14; ··· 13918 kdevelop = callPackage ../applications/editors/kdevelop { }; 13919 13920 kdevplatform = callPackage ../development/libraries/kdevplatform { 13921 - boost = boost156; 13922 }; 13923 13924 kdiff3 = callPackage ../tools/text/kdiff3 { }; ··· 13950 libalkimia = callPackage ../development/libraries/libalkimia { }; 13951 13952 libktorrent = callPackage ../development/libraries/libktorrent { 13953 - boost = boost156; 13954 }; 13955 13956 libkvkontakte = callPackage ../development/libraries/libkvkontakte { };
··· 258 autonix = import ../build-support/autonix { inherit pkgs; }; 259 260 autoreconfHook = makeSetupHook 261 + { substitutions = { inherit autoconf automake gettext; libtool = realLibtool; }; } 262 ../build-support/setup-hooks/autoreconf.sh; 263 264 buildEnv = callPackage ../build-support/buildenv {}; ··· 1044 cksfv = callPackage ../tools/networking/cksfv { }; 1045 1046 clementine = callPackage ../applications/audio/clementine { 1047 + boost = boost155; 1048 gst_plugins = [ gst_plugins_base gst_plugins_good gst_plugins_ugly gst_ffmpeg ]; 1049 }; 1050 ··· 1695 1696 calamares = callPackage ../tools/misc/calamares rec { 1697 python = python3; 1698 + boost = pkgs.boost.override { python=python3; }; 1699 libyamlcpp = callPackage ../development/libraries/libyaml-cpp { makePIC=true; boost=boost; }; 1700 inherit (kf5_stable) extra-cmake-modules kconfig ki18n kcoreaddons solid; 1701 }; ··· 2008 2009 nodejs-0_12 = callPackage ../development/web/nodejs { 2010 libuv = libuvVersions.v1_6_1; 2011 }; 2012 + 2013 nodejs-0_10 = callPackage ../development/web/nodejs/v0_10.nix { 2014 inherit (darwin.apple_sdk.frameworks) CoreServices ApplicationServices Carbon Foundation; 2015 }; 2016 ··· 5575 5576 lemon = callPackage ../development/tools/parsing/lemon { }; 5577 5578 + libtool = if stdenv.isDarwin 5579 + then darwin.cctools 5580 + else realLibtool; 5581 + 5582 + realLibtool = libtool_2; 5583 5584 libtool_1_5 = callPackage ../development/tools/misc/libtool { }; 5585 ··· 5784 texi2html = callPackage ../development/tools/misc/texi2html { }; 5785 5786 uhd = callPackage ../development/tools/misc/uhd { 5787 + boost = boost155; 5788 }; 5789 5790 uisp = callPackage ../development/tools/misc/uisp { }; ··· 5914 boolstuff = callPackage ../development/libraries/boolstuff { }; 5915 5916 boost155 = callPackage ../development/libraries/boost/1.55.nix { }; 5917 boost159 = callPackage ../development/libraries/boost/1.59.nix { }; 5918 boost = boost159; 5919 ··· 6193 6194 fontconfig-ultimate = callPackage ../development/libraries/fontconfig-ultimate {}; 6195 6196 + folly = callPackage ../development/libraries/folly { }; 6197 6198 makeFontsConf = let fontconfig_ = fontconfig; in {fontconfig ? fontconfig_, fontDirectories}: 6199 callPackage ../development/libraries/fontconfig/make-fonts-conf.nix { ··· 6395 6396 qt_gstreamer = callPackage ../development/libraries/gstreamer/legacy/qt-gstreamer {}; 6397 6398 + qt_gstreamer1 = callPackage ../development/libraries/gstreamer/qt-gstreamer { boost = boost155;}; 6399 6400 gnet = callPackage ../development/libraries/gnet { }; 6401 ··· 8527 lucene = callPackage ../development/libraries/java/lucene { }; 8528 8529 lucenepp = callPackage ../development/libraries/lucene++ { 8530 + boost = boost155; 8531 }; 8532 8533 mockobjects = callPackage ../development/libraries/java/mockobjects { }; ··· 9139 rethinkdb = callPackage ../servers/nosql/rethinkdb { }; 9140 9141 rippled = callPackage ../servers/rippled { 9142 + boost = boost155; 9143 }; 9144 9145 ripple-rest = callPackage ../servers/rippled/ripple-rest.nix { }; ··· 9253 quartz-wm = callPackage ../servers/x11/quartz-wm { stdenv = clangStdenv; }; 9254 9255 xorg = recurseIntoAttrs (lib.callPackagesWith pkgs ../servers/x11/xorg/default.nix { 9256 + inherit clangStdenv fetchurl fetchgit fetchpatch stdenv pkgconfig intltool freetype fontconfig 9257 + libxslt expat libpng zlib perl mesa_drivers spice_protocol 9258 + dbus libuuid openssl gperf m4 libevdev tradcpp libinput mcpp makeWrapper autoreconfHook 9259 + autoconf automake libtool xmlto asciidoc flex bison python mtdev pixman; 9260 + inherit (darwin) apple_sdk; 9261 bootstrap_cmds = if stdenv.isDarwin then darwin.bootstrap_cmds else null; 9262 mesa = mesa_noglu; 9263 udev = if stdenv.isLinux then udev else null; ··· 10656 schismtracker = callPackage ../applications/audio/schismtracker { }; 10657 10658 altcoins = recurseIntoAttrs ( callPackage ../applications/altcoins { 10659 + callPackage = newScope { boost = boost155; }; 10660 } ); 10661 bitcoin = altcoins.bitcoin; 10662 bitcoin-xt = altcoins.bitcoin-xt; ··· 11012 imagemagick = null; 11013 acl = null; 11014 gpm = null; 11015 + inherit (darwin.apple_sdk.frameworks) AppKit Foundation; 11016 + inherit (darwin) libobjc; 11017 }; 11018 11019 emacs24-nox = lowPrio (appendToName "nox" (emacs24.override { ··· 11380 fomp = callPackage ../applications/audio/fomp { }; 11381 11382 freecad = callPackage ../applications/graphics/freecad { 11383 + boost = boost155; 11384 opencascade = opencascade_6_5; 11385 inherit (pythonPackages) matplotlib pycollada; 11386 }; ··· 11403 }; 11404 11405 freicoin = callPackage ../applications/misc/freicoin { 11406 + boost = boost155; 11407 }; 11408 11409 fuze = callPackage ../applications/networking/instant-messengers/fuze {}; ··· 11853 11854 ledger2 = callPackage ../applications/office/ledger/2.6.3.nix { }; 11855 ledger3 = callPackage ../applications/office/ledger { 11856 + boost = boost155; 11857 }; 11858 ledger = ledger3; 11859 ··· 13869 { 13870 libusb = libusb1; 13871 libcanberra = libcanberra_kde; 13872 + boost = boost155; 13873 kdelibs = kdeApps_stable.kdelibs; 13874 } 13875 ../desktops/kde-4.14; ··· 13923 kdevelop = callPackage ../applications/editors/kdevelop { }; 13924 13925 kdevplatform = callPackage ../development/libraries/kdevplatform { 13926 + boost = boost155; 13927 }; 13928 13929 kdiff3 = callPackage ../tools/text/kdiff3 { }; ··· 13955 libalkimia = callPackage ../development/libraries/libalkimia { }; 13956 13957 libktorrent = callPackage ../development/libraries/libktorrent { 13958 + boost = boost155; 13959 }; 13960 13961 libkvkontakte = callPackage ../development/libraries/libkvkontakte { };