summaryrefslogtreecommitdiff
path: root/newmoon
diff options
context:
space:
mode:
authorB. Stack <bgstack15@gmail.com>2022-01-20 18:57:53 +0000
committerB. Stack <bgstack15@gmail.com>2022-01-20 18:57:53 +0000
commit7f9d6c9f9a6c40582470f123a5466c984bae55be (patch)
tree5e397d6dbbebca4b4122e4211a2d52eaeb34c3e0 /newmoon
parentMerge branch 'scite-bump' into 'master' (diff)
parentcheck gcc ver instead of fedora ver (diff)
downloadstackrpms-7f9d6c9f9a6c40582470f123a5466c984bae55be.tar.gz
stackrpms-7f9d6c9f9a6c40582470f123a5466c984bae55be.tar.bz2
stackrpms-7f9d6c9f9a6c40582470f123a5466c984bae55be.zip
Merge branch 'newmoon-bump' into 'master'
newmoon 29.4.3 with gcc11 support See merge request bgstack15/stackrpms!280
Diffstat (limited to 'newmoon')
-rw-r--r--newmoon/README.md4
-rw-r--r--newmoon/_service29
-rw-r--r--newmoon/debian/changelog13
-rw-r--r--newmoon/debian/control1
-rw-r--r--newmoon/debian/newmoon+devuan.dsc4
-rw-r--r--newmoon/debian/patches/revert-mach-file.patch71
-rw-r--r--newmoon/debian/patches/series3
-rwxr-xr-xnewmoon/debian/rules6
-rw-r--r--newmoon/newmoon.spec21
-rw-r--r--newmoon/nm-gcc-11.patch1051
-rw-r--r--newmoon/revert-mach-file.patch71
11 files changed, 1265 insertions, 9 deletions
diff --git a/newmoon/README.md b/newmoon/README.md
index 5553a8b..c011701 100644
--- a/newmoon/README.md
+++ b/newmoon/README.md
@@ -21,5 +21,9 @@ Credit goes to so many sources and inspirations:
* https://build.opensuse.org/package/view_file/network/palemoon/palemoon.spec?expand=1
* instructions for compiling on centos 6 and 7 http://developer.palemoon.org/Developer_Guide:Build_Instructions/Pale_Moon/Linux#head:CentOS_6
+Fold the debian changelog notes with:
+
+ :'<,'>!sed -r -e 's/^ */* /;' | fold -w 72 -s | sed -r -e 's/^([^\*])/ \1/;' -e 's/^\*/ */;'
+
# Differences from upstream
diff -aur palemoon newmoon | vi -
diff --git a/newmoon/_service b/newmoon/_service
new file mode 100644
index 0000000..7817a67
--- /dev/null
+++ b/newmoon/_service
@@ -0,0 +1,29 @@
+<services>
+ <service name="tar_scm">
+ <param name="scm">git</param>
+ <param name="url">https://gitlab.com/bgstack15/stackrpms.git</param>
+ <param name="subdir">newmoon/debian</param>
+ <param name="filename">debian</param>
+ <param name="revision">newmoon-bump</param>
+ <param name="version">_none_</param>
+ </service>
+ <service name="recompress">
+ <param name="file">*.tar</param>
+ <param name="compression">xz</param>
+ </service>
+ <service name="tar_scm">
+ <param name="scm">git</param>
+ <param name="url">https://gitlab.com/opensource-tracking/palemoon.git</param>
+ <param name="revision">db5ee3c1968212742b4ed8b9883069ea7b03f0e1</param>
+ <param name="version">_none_</param>
+ <param name="submodules">enable</param>
+ </service>
+ <service name="recompress">
+ <param name="file">*.tar</param>
+ <param name="compression">gz</param>
+ </service>
+ <service name="extract_file">
+ <param name="archive">*.tar.xz</param>
+ <param name="files">*/*.dsc</param>
+ </service>
+</services>
diff --git a/newmoon/debian/changelog b/newmoon/debian/changelog
index 725d65a..b67b300 100644
--- a/newmoon/debian/changelog
+++ b/newmoon/debian/changelog
@@ -1,3 +1,16 @@
+newmoon (29.4.3-1+devuan) obs; urgency=medium
+
+ - This is a security update with a few extras.
+ * Restored the FUEL abstraction library again.
+ * Added some extra sanity checks to timers and text fragments. DiD
+ * Added a potential crash safeguard in program threading logic. DiD
+ * Fixed the following security issues: CVE-2021-43537, CVE-2021-43541,
+ CVE-2021-43536, CVE-2021-43545 and CVE-2021-43542.
+ * Unified XUL Platform Mozilla Security Patch Summary: 5 fixed, 3 DiD,
+ 10 not applicable.
+
+ -- B. Stack <bgstack15@gmail.com> Tue, 04 Jan 2022 12:54:49 -0500
+
newmoon (29.4.2-1+devuan) obs; urgency=medium
- This is a security update.
diff --git a/newmoon/debian/control b/newmoon/debian/control
index 7d167fd..29a09a3 100644
--- a/newmoon/debian/control
+++ b/newmoon/debian/control
@@ -14,7 +14,6 @@ Build-Depends: debhelper (>= 12),
libssl-dev,
libx11-xcb-dev,
libxt-dev,
- lsb-release,
mesa-common-dev,
pkg-config,
python2 (>= 2.7.18-2~) | python (>= 2.7),
diff --git a/newmoon/debian/newmoon+devuan.dsc b/newmoon/debian/newmoon+devuan.dsc
index 2a1ef76..53f3d03 100644
--- a/newmoon/debian/newmoon+devuan.dsc
+++ b/newmoon/debian/newmoon+devuan.dsc
@@ -2,11 +2,11 @@ Format: 3.0 (quilt)
Source: newmoon
Binary: newmoon
Architecture: any
-Version: 29.4.2-1+devuan
+Version: 29.4.3-1+devuan
Maintainer: B. Stack <bgstack15@gmail.com>
Homepage: http://www.palemoon.org/
Standards-Version: 4.1.4
-Build-Depends: debhelper (>= 12), gcc (<< 11) | gcc-10, g++ (<< 11) | g++-10, autoconf2.13, libasound2-dev, libdbus-glib-1-dev (>= 0.60), libgconf2-dev (>= 1.2.1), libgtk2.0-dev (>= 2.14), libssl-dev, libx11-xcb-dev, libxt-dev, mesa-common-dev, pkg-config, python2 (>= 2.7.18-2~) | python (>= 2.7), unzip, yasm (>= 1.1), zip, lsb-release
+Build-Depends: debhelper (>= 12), gcc (<< 11) | gcc-10, g++ (<< 11) | g++-10, autoconf2.13, libasound2-dev, libdbus-glib-1-dev (>= 0.60), libgconf2-dev (>= 1.2.1), libgtk2.0-dev (>= 2.14), libssl-dev, libx11-xcb-dev, libxt-dev, mesa-common-dev, pkg-config, python2 (>= 2.7.18-2~) | python (>= 2.7), unzip, yasm (>= 1.1), zip
Package-List:
newmoon deb web optional arch=any
Files:
diff --git a/newmoon/debian/patches/revert-mach-file.patch b/newmoon/debian/patches/revert-mach-file.patch
new file mode 100644
index 0000000..cda3786
--- /dev/null
+++ b/newmoon/debian/patches/revert-mach-file.patch
@@ -0,0 +1,71 @@
+Description: revert mach file to 29.4.2's to fix FTBFS
+Last-Update: 2021-11-12
+
+--- palemoon-29.4.2.1.orig/mach
++++ palemoon-29.4.2.1/mach
+@@ -1,63 +1,4 @@
+ #!/bin/sh
+
+-MCP_MACH=./platform/mach
+-MCP_GIT=`which git 2>/dev/null`
+-
+-if [ ! -f "$MCP_MACH" ]; then
+- printf "Error: There is no platform codebase.\n"
+- exit 1
+-fi
+-
+-MCP_APP=palemoon
+-MCP_VERSION=`cat ./$MCP_APP/config/version.txt`
+-
+-MCP_XZ=`which xz 2>/dev/null`
+-MCP_TAR_BASEDIR="s/^./$MCP_APP-source/"
+-MCP_TAR_FILENAME="$MCP_APP-$MCP_VERSION.source.tar.xz"
+-MCP_TAR_COMMAND="tar cfJv ../$MCP_TAR_FILENAME . --transform $MCP_TAR_BASEDIR --exclude-vcs --warning=no-file-changed"
+-MCP_TAR_EXCLUDES=(
+- "$MCP_APP/branding/beta"
+- "$MCP_APP/branding/unstable"
+- "platform/db/mork"
+- "platform/docs"
+- "platform/ldap"
+- "platform/libs/gmp-clearkey"
+- "platform/mailnews"
+- "platform/python/psutil/*.so"
+- "platform/python/psutil/*.pyd"
+- "platform/python/psutil/build"
+- "platform/xulrunner"
+- ".mozconfig"
+- ".gitattributes"
+- ".gitignore"
+- ".gitmodules"
+- "*.pyc"
+- "*.pyo"
+- "*.rej"
+- "*.orig"
+- "*.source.tar.xz"
+-)
+-
+-if [ "$1" == "source" ]; then
+- if [ -z "$MCP_XZ" ]; then
+- printf "Error: XZ was not found on the system. NOTE: This won't work on Windows.\n"
+- exit 1
+- fi
+-
+- for _value in "${MCP_TAR_EXCLUDES[@]}"; do
+- MCP_TAR_COMMAND+=" --exclude=${_value}"
+- done
+-
+- if [[ -n "$MCP_GIT" && -d "./.git" && -d "./platform/.git" ]]; then
+- printf "COMM SHA1: `"${MCP_GIT}" rev-parse --short HEAD 2>/dev/null`\n"
+- printf "GRE SHA1: `cd ./platform && "${MCP_GIT}" rev-parse --short HEAD 2>/dev/null`\n"
+- fi
+-
+- printf "Source Filename: $MCP_TAR_FILENAME\n\n"
+- read -r -s -p $'Press enter to continue...\n'
+- env XZ_OPTS=-9e ${MCP_TAR_COMMAND}
+-else
+- # We don't know what the command is but real-mach might so just pass
+- # all the args to it
+- $MCP_MACH $@
+-fi
++MACH_CMD=./platform/mach
++$MACH_CMD $@
diff --git a/newmoon/debian/patches/series b/newmoon/debian/patches/series
index baa043e..fd4cf3c 100644
--- a/newmoon/debian/patches/series
+++ b/newmoon/debian/patches/series
@@ -1,3 +1,6 @@
+# from stevepusser for 29.4.3:
+revert-mach-file.patch
+# stackrpms
small-icons.patch
pm-devuan.patch
pm-to-nm.patch
diff --git a/newmoon/debian/rules b/newmoon/debian/rules
index d93a6a0..89ddd3f 100755
--- a/newmoon/debian/rules
+++ b/newmoon/debian/rules
@@ -5,13 +5,13 @@ export SHELL=/bin/bash
## borrowed from stevepusser's logic
## Build with gcc-10 on releases where default gcc is 11
## If you enable this, then d/control needs lsb-release as a build dependency.
-distrelease := $(shell lsb_release -cs)
-ifeq ($(distrelease),$(filter $(distrelease),sid beowulf/ceres))
+#distrelease := $(shell lsb_release -cs)
+#ifeq ($(distrelease),$(filter $(distrelease),sid beowulf/ceres))
export CC=gcc-10
export CXX=g++-10
export CPP=cpp-10
export LD=gcc-10
-endif
+#endif
export MCFILE=debian/mozconfig
diff --git a/newmoon/newmoon.spec b/newmoon/newmoon.spec
index 9cf74a9..2b857e4 100644
--- a/newmoon/newmoon.spec
+++ b/newmoon/newmoon.spec
@@ -6,7 +6,7 @@
# git submodule | awk -v "name=platform" '$2 == name {gsub("-","",$1); print $1}'
#%%global submodule_platform_tag RELBASE_20210817
%global badname palemoon
-%global git_commit fd92034fe425320e6ee13e43b676c91a68969029
+%global git_commit db5ee3c1968212742b4ed8b9883069ea7b03f0e1
%global tarballdir %{badname}-%{git_commit}
# additional repos to get python27 and devtoolset-7
@@ -44,7 +44,7 @@ Name: newmoon
Name: newmoon
%endif
Summary: Newmoon web browser
-Version: 29.4.2
+Version: 29.4.3
Release: 1
Group: Networking/Web
@@ -59,9 +59,11 @@ Source4: newmoon-mimeinfo.xml
%if 0%{stackrpms_custom}
Source5: bgstack15-newmoon-prefs.js
Source6: bluemoon-icons.tgz
+Source7: nm-gcc-11.patch
Patch0: small-icons.patch
Patch1: pm-fedora.patch
Patch2: pm-to-nm.patch
+Patch3: revert-mach-file.patch
%endif
Packager: B. Stack <bgstack15@gmail.com>
@@ -123,6 +125,14 @@ sed -i -r -e '/enable-optimize/s/"\s*$/ -Wno-format-overflow"/' ./.mozconfig
%patch0 -p1
%patch1 -p1
%patch2 -p1
+%patch3 -p1
+__gccver="$( gcc --version 2>&1 | grep -oE '[0-9]*\.[0-9]\.[0-9]'| head -n1 | grep -oE '^[0-9]+' )"
+if test "${__gccver}" == "11" ; then
+ # For gcc 11
+ cd platform
+ patch -p1 < %{SOURCE7}
+ cd ..
+fi
! test -d %{badname}/branding/unofficial.unbuilt && {
cp -pr %{badname}/branding/unofficial %{badname}/branding/unofficial.unbuilt && \
@@ -300,7 +310,12 @@ update-mime-database -n ${_datadir}/mime 1>/dev/null 2>&1 & :
%doc AUTHORS LICENSE
%changelog
-* Tue Nov 11 2021 B. Stack <bgstack15@gmail.com> - 29.4.2-1
+* Tue Jan 04 2022 B. Stack <bgstack15@gmail.com> - 29.4.3-1
+- update version
+- add revert-mach-file patch from stevepusser
+- add nm-gcc-11 patch from gentooman
+
+* Thu Nov 11 2021 B. Stack <bgstack15@gmail.com> - 29.4.2-1
- update version
* Wed Sep 15 2021 B. Stack <bgstack15@gmail.com> - 29.4.1-1
diff --git a/newmoon/nm-gcc-11.patch b/newmoon/nm-gcc-11.patch
new file mode 100644
index 0000000..9ab7f75
--- /dev/null
+++ b/newmoon/nm-gcc-11.patch
@@ -0,0 +1,1051 @@
+Summary: Make Palemoon compile with gcc 11
+Author: gentooman
+Linked from: https://repo.palemoon.org/mcp-graveyard/UXP/issues/1804
+Source: https://dpaste.com/AF96RDF74
+Date: 2021-08-10
+Message:
+ By adding the <limits> to all these files, we can avoid compilation errors on
+ the latest and greatest gcc.
+
+--- a/accessible/generic/HyperTextAccessible.cpp
++++ b/accessible/generic/HyperTextAccessible.cpp
+@@ -38,6 +38,8 @@
+ #include "mozilla/dom/Selection.h"
+ #include "mozilla/MathAlgorithms.h"
+ #include "gfxSkipChars.h"
++
++#include <limits>
+ #include <algorithm>
+
+ using namespace mozilla;
+
+--- a/dom/crypto/WebCryptoTask.cpp
++++ b/dom/crypto/WebCryptoTask.cpp
+@@ -3,6 +3,8 @@
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
++#include <limits>
++
+ #include "pk11pub.h"
+ #include "cryptohi.h"
+ #include "secerr.h"
+
+--- a/dom/media/gtest/TestIntervalSet.cpp
++++ b/dom/media/gtest/TestIntervalSet.cpp
+@@ -7,6 +7,8 @@
+ #include "mozilla/dom/TimeRanges.h"
+ #include "TimeUnits.h"
+ #include "Intervals.h"
++
++#include <limits>
+ #include <algorithm>
+ #include <vector>
+
+--- a/dom/media/webaudio/BiquadFilterNode.cpp
++++ b/dom/media/webaudio/BiquadFilterNode.cpp
+@@ -4,6 +4,8 @@
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
++#include <limits>
++
+ #include "BiquadFilterNode.h"
+ #include "AlignmentUtils.h"
+ #include "AudioNodeEngine.h"
+
+--- a/dom/media/webaudio/DelayBuffer.h
++++ b/dom/media/webaudio/DelayBuffer.h
+@@ -7,6 +7,8 @@
+ #ifndef DelayBuffer_h_
+ #define DelayBuffer_h_
+
++#include <limits>
++
+ #include "nsTArray.h"
+ #include "AudioBlock.h"
+ #include "AudioSegment.h"
+
+--- a/dom/media/webaudio/IIRFilterNode.cpp
++++ b/dom/media/webaudio/IIRFilterNode.cpp
+@@ -4,6 +4,8 @@
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
++#include <limits>
++
+ #include "IIRFilterNode.h"
+ #include "AlignmentUtils.h"
+ #include "AudioBlock.h"
+
+--- a/dom/media/webm/WebMDemuxer.cpp
++++ b/dom/media/webm/WebMDemuxer.cpp
+@@ -27,6 +27,7 @@
+ #include "prprf.h" // leaving it for PR_vsnprintf()
+ #include "mozilla/Sprintf.h"
+
++#include <limits>
+ #include <algorithm>
+ #include <numeric>
+ #include <stdint.h>
+
+--- a/dom/svg/SVGContentUtils.cpp
++++ b/dom/svg/SVGContentUtils.cpp
+@@ -31,6 +31,8 @@
+ #include "SVGPathData.h"
+ #include "SVGPathElement.h"
+
++#include <limits>
++
+ using namespace mozilla;
+ using namespace mozilla::dom;
+ using namespace mozilla::gfx;
+
+--- a/gfx/2d/BaseRect.h
++++ b/gfx/2d/BaseRect.h
+@@ -9,6 +9,7 @@
+ #include <algorithm>
+ #include <cmath>
+ #include <ostream>
++#include <limits>
+
+ #include "mozilla/Assertions.h"
+ #include "mozilla/FloatingPoint.h"
+
+--- a/gfx/2d/Matrix.h
++++ b/gfx/2d/Matrix.h
+@@ -13,6 +13,7 @@
+ #include "Quaternion.h"
+ #include <iosfwd>
+ #include <math.h>
++#include <limits>
+ #include "mozilla/Attributes.h"
+ #include "mozilla/DebugOnly.h"
+ #include "mozilla/FloatingPoint.h"
+
+--- a/gfx/2d/image_operations.h
++++ b/gfx/2d/image_operations.h
+@@ -29,6 +29,8 @@
+ #ifndef SKIA_EXT_IMAGE_OPERATIONS_H_
+ #define SKIA_EXT_IMAGE_OPERATIONS_H_
+
++#include <limits>
++
+ #include "skia/include/core/SkTypes.h"
+ #include "Types.h"
+ #include "convolver.h"
+
+--- a/gfx/angle/src/common/BitSetIterator.h
++++ b/gfx/angle/src/common/BitSetIterator.h
+@@ -10,8 +10,8 @@
+ #ifndef COMMON_BITSETITERATOR_H_
+ #define COMMON_BITSETITERATOR_H_
+
++#include <limits>
+ #include <stdint.h>
+-
+ #include <bitset>
+
+ #include "common/angleutils.h"
+
+--- a/gfx/angle/src/common/mathutil_unittest.cpp
++++ b/gfx/angle/src/common/mathutil_unittest.cpp
+@@ -9,6 +9,7 @@
+
+ #include "mathutil.h"
+
++#include <limits>
+ #include <gtest/gtest.h>
+
+ using namespace gl;
+
+--- a/gfx/angle/src/common/utilities.cpp
++++ b/gfx/angle/src/common/utilities.cpp
+@@ -10,6 +10,7 @@
+ #include "common/mathutil.h"
+ #include "common/platform.h"
+
++#include <limits>
+ #include <set>
+
+ #if defined(ANGLE_ENABLE_WINDOWS_STORE)
+
+--- a/gfx/angle/src/compiler/translator/CallDAG.cpp
++++ b/gfx/angle/src/compiler/translator/CallDAG.cpp
+@@ -8,6 +8,8 @@
+ // analyses, allows to efficiently traverse the functions in topological
+ // order.
+
++#include <limits>
++
+ #include "compiler/translator/CallDAG.h"
+ #include "compiler/translator/InfoSink.h"
+
+--- a/gfx/angle/src/libANGLE/BinaryStream_unittest.cpp
++++ b/gfx/angle/src/libANGLE/BinaryStream_unittest.cpp
+@@ -6,6 +6,7 @@
+
+ // BinaryStream_unittest.cpp: Unit tests of the binary stream classes.
+
++#include <limits>
+ #include <gtest/gtest.h>
+
+ #include "libANGLE/BinaryStream.h"
+
+--- a/gfx/angle/src/libANGLE/HandleAllocator.cpp
++++ b/gfx/angle/src/libANGLE/HandleAllocator.cpp
+@@ -9,6 +9,7 @@
+
+ #include "libANGLE/HandleAllocator.h"
+
++#include <limits>
+ #include <algorithm>
+
+ #include "common/debug.h"
+
+--- a/gfx/angle/src/libANGLE/HandleAllocator_unittest.cpp
++++ b/gfx/angle/src/libANGLE/HandleAllocator_unittest.cpp
+@@ -6,6 +6,8 @@
+ // Unit tests for HandleAllocator.
+ //
+
++#include <limits>
++
+ #include "gmock/gmock.h"
+ #include "gtest/gtest.h"
+
+--- a/gfx/angle/src/libANGLE/HandleRangeAllocator_unittest.cpp
++++ b/gfx/angle/src/libANGLE/HandleRangeAllocator_unittest.cpp
+@@ -6,9 +6,10 @@
+ // Unit tests for HandleRangeAllocator.
+ //
+
++#include <limits>
++
+ #include "gmock/gmock.h"
+ #include "gtest/gtest.h"
+-
+ #include "libANGLE/HandleRangeAllocator.h"
+
+ namespace
+
+--- a/gfx/angle/src/libANGLE/Program.cpp
++++ b/gfx/angle/src/libANGLE/Program.cpp
+@@ -9,6 +9,7 @@
+
+ #include "libANGLE/Program.h"
+
++#include <limits>
+ #include <algorithm>
+
+ #include "common/BitSetIterator.h"
+
+--- a/gfx/angle/src/libANGLE/queryconversions.cpp
++++ b/gfx/angle/src/libANGLE/queryconversions.cpp
+@@ -8,6 +8,7 @@
+
+ #include "libANGLE/queryconversions.h"
+
++#include <limits>
+ #include <vector>
+
+ #include "libANGLE/Context.h"
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/BufferD3D.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/BufferD3D.cpp
+@@ -6,6 +6,8 @@
+
+ // BufferD3D.cpp Defines common functionality between the Buffer9 and Buffer11 classes.
+
++#include <limits>
++
+ #include "libANGLE/renderer/d3d/BufferD3D.h"
+
+ #include "common/mathutil.h"
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/IndexDataManager.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/IndexDataManager.cpp
+@@ -7,6 +7,8 @@
+ // IndexDataManager.cpp: Defines the IndexDataManager, a class that
+ // runs the Buffer translation process for index buffers.
+
++#include <limits>
++
+ #include "libANGLE/renderer/d3d/IndexDataManager.h"
+
+ #include "common/utilities.h"
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/RendererD3D.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/RendererD3D.cpp
+@@ -6,6 +6,8 @@
+
+ // RendererD3D.cpp: Implementation of the base D3D Renderer.
+
++#include <limits>
++
+ #include "libANGLE/renderer/d3d/RendererD3D.h"
+
+ #include "common/debug.h"
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/VertexDataManager.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/VertexDataManager.cpp
+@@ -7,6 +7,8 @@
+ // VertexDataManager.h: Defines the VertexDataManager, a class that
+ // runs the Buffer translation process.
+
++#include <limits>
++
+ #include "libANGLE/renderer/d3d/VertexDataManager.h"
+
+ #include "common/BitSetIterator.h"
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/d3d11/Buffer11.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/d3d11/Buffer11.cpp
+@@ -8,6 +8,7 @@
+
+ #include "libANGLE/renderer/d3d/d3d11/Buffer11.h"
+
++#include <limits>
+ #include <memory>
+
+ #include "common/MemoryBuffer.h"
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/d3d11/InputLayoutCache.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/d3d11/InputLayoutCache.cpp
+@@ -7,6 +7,8 @@
+ // InputLayoutCache.cpp: Defines InputLayoutCache, a class that builds and caches
+ // D3D11 input layouts.
+
++#include <limits>
++
+ #include "libANGLE/renderer/d3d/d3d11/InputLayoutCache.h"
+
+ #include "common/BitSetIterator.h"
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/d3d11/Query11.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/d3d11/Query11.cpp
+@@ -8,6 +8,7 @@
+
+ #include "libANGLE/renderer/d3d/d3d11/Query11.h"
+
++#include <limits>
+ #include <GLES2/gl2ext.h>
+
+ #include "common/utilities.h"
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/d3d11/Renderer11.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/d3d11/Renderer11.cpp
+@@ -8,6 +8,7 @@
+
+ #include "libANGLE/renderer/d3d/d3d11/Renderer11.h"
+
++#include <limits>
+ #include <EGL/eglext.h>
+ #include <iomanip>
+ #include <sstream>
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/d3d11/StateManager11.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/d3d11/StateManager11.cpp
+@@ -6,6 +6,8 @@
+
+ // StateManager11.cpp: Defines a class for caching D3D11 state
+
++#include <limits>
++
+ #include "libANGLE/renderer/d3d/d3d11/StateManager11.h"
+
+ #include "common/BitSetIterator.h"
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/d3d11/TextureStorage11.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/d3d11/TextureStorage11.cpp
+@@ -10,6 +10,7 @@
+
+ #include "libANGLE/renderer/d3d/d3d11/TextureStorage11.h"
+
++#include <limits>
+ #include <tuple>
+
+ #include "common/MemoryBuffer.h"
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/d3d11/copyvertex.inl
++++ b/gfx/angle/src/libANGLE/renderer/d3d/d3d11/copyvertex.inl
+@@ -4,6 +4,8 @@
+ // found in the LICENSE file.
+ //
+
++#include <limits>
++
+ namespace rx
+ {
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/d3d11/renderer11_utils.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/d3d11/renderer11_utils.cpp
+@@ -9,6 +9,7 @@
+
+ #include "libANGLE/renderer/d3d/d3d11/renderer11_utils.h"
+
++#include <limits>
+ #include <algorithm>
+
+ #include "common/debug.h"
+--- a/gfx/angle/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp
+@@ -8,6 +8,7 @@
+
+ #include "libANGLE/renderer/d3d/d3d9/Renderer9.h"
+
++#include <limits>
+ #include <sstream>
+ #include <EGL/eglext.h>
+
+--- a/gfx/angle/src/libANGLE/renderer/d3d/d3d9/renderer9_utils.cpp
++++ b/gfx/angle/src/libANGLE/renderer/d3d/d3d9/renderer9_utils.cpp
+@@ -7,6 +7,8 @@
+ // renderer9_utils.cpp: Conversion functions and other utility routines
+ // specific to the D3D9 renderer.
+
++#include <limits>
++
+ #include "libANGLE/renderer/d3d/d3d9/renderer9_utils.h"
+
+ #include "common/mathutil.h"
+
+--- a/gfx/angle/src/libANGLE/validationES.cpp
++++ b/gfx/angle/src/libANGLE/validationES.cpp
+@@ -6,8 +6,9 @@
+
+ // validationES.h: Validation functions for generic OpenGL ES entry point parameters
+
+-#include "libANGLE/validationES.h"
++#include <limits>
+
++#include "libANGLE/validationES.h"
+ #include "libANGLE/validationES2.h"
+ #include "libANGLE/validationES3.h"
+ #include "libANGLE/Context.h"
+
+--- a/gfx/angle/src/libANGLE/validationES2.cpp
++++ b/gfx/angle/src/libANGLE/validationES2.cpp
+@@ -8,6 +8,7 @@
+
+ #include "libANGLE/validationES2.h"
+
++#include <limits>
+ #include <cstdint>
+
+ #include "libANGLE/validationES.h"
+
+--- a/gfx/angle/src/libANGLE/validationES3.cpp
++++ b/gfx/angle/src/libANGLE/validationES3.cpp
+@@ -6,8 +6,9 @@
+
+ // validationES3.cpp: Validation functions for OpenGL ES 3.0 entry point parameters
+
+-#include "libANGLE/validationES3.h"
++#include <limits>
+
++#include "libANGLE/validationES3.h"
+ #include "libANGLE/validationES.h"
+ #include "libANGLE/Context.h"
+ #include "libANGLE/Texture.h"
+
+--- a/gfx/angle/src/tests/compiler_tests/ConstantFolding_test.cpp
++++ b/gfx/angle/src/tests/compiler_tests/ConstantFolding_test.cpp
+@@ -7,6 +7,7 @@
+ // Tests for constant folding
+ //
+
++#include <limits>
+ #include <vector>
+
+ #include "angle_gl.h"
+
+--- a/gfx/angle/src/tests/gl_tests/BlendMinMaxTest.cpp
++++ b/gfx/angle/src/tests/gl_tests/BlendMinMaxTest.cpp
+@@ -4,6 +4,7 @@
+ // found in the LICENSE file.
+ //
+
++#include <limits>
+ #include "test_utils/ANGLETest.h"
+
+ using namespace angle;
+
+--- a/gfx/angle/src/tests/gl_tests/BufferDataTest.cpp
++++ b/gfx/angle/src/tests/gl_tests/BufferDataTest.cpp
+@@ -6,6 +6,7 @@
+
+ #include "test_utils/ANGLETest.h"
+
++#include <limits>
+ #include <stdint.h>
+
+ using namespace angle;
+
+--- a/gfx/angle/src/tests/gl_tests/DepthStencilFormatsTest.cpp
++++ b/gfx/angle/src/tests/gl_tests/DepthStencilFormatsTest.cpp
+@@ -4,6 +4,7 @@
+ // found in the LICENSE file.
+ //
+
++#include <limits>
+ #include "test_utils/ANGLETest.h"
+
+ using namespace angle;
+
+--- a/gfx/angle/src/tests/gl_tests/PathRenderingTest.cpp
++++ b/gfx/angle/src/tests/gl_tests/PathRenderingTest.cpp
+@@ -12,6 +12,7 @@
+
+ #include "common/angleutils.h"
+
++#include <limits>
+ #include <cmath>
+ #include <cstring>
+ #include <cstddef>
+
+--- a/gfx/angle/src/tests/gl_tests/UniformTest.cpp
++++ b/gfx/angle/src/tests/gl_tests/UniformTest.cpp
+@@ -6,6 +6,7 @@
+
+ #include "test_utils/ANGLETest.h"
+
++#include <limits>
+ #include <array>
+ #include <cmath>
+
+--- a/gfx/angle/src/tests/gl_tests/VertexAttributeTest.cpp
++++ b/gfx/angle/src/tests/gl_tests/VertexAttributeTest.cpp
+@@ -4,6 +4,7 @@
+ // found in the LICENSE file.
+ //
+
++#include <limits>
+ #include "test_utils/ANGLETest.h"
+
+ using namespace angle;
+
+--- a/gfx/angle/src/tests/perf_tests/BufferSubData.cpp
++++ b/gfx/angle/src/tests/perf_tests/BufferSubData.cpp
+@@ -7,6 +7,7 @@
+ // Performance test for ANGLE buffer updates.
+ //
+
++#include <limits>
+ #include <sstream>
+
+ #include "ANGLEPerfTest.h"
+
+--- a/gfx/angle/src/tests/perf_tests/DynamicPromotionPerfTest.cpp
++++ b/gfx/angle/src/tests/perf_tests/DynamicPromotionPerfTest.cpp
+@@ -9,6 +9,8 @@
+ // dynamic and static buffers quite differently.
+ //
+
++#include <limits>
++
+ #include "ANGLEPerfTest.h"
+ #include "random_utils.h"
+ #include "shader_utils.h"
+
+--- a/gfx/angle/src/tests/perf_tests/IndexConversionPerf.cpp
++++ b/gfx/angle/src/tests/perf_tests/IndexConversionPerf.cpp
+@@ -7,6 +7,7 @@
+ // Performance tests for ANGLE index conversion in D3D11.
+ //
+
++#include <limits>
+ #include <sstream>
+
+ #include "ANGLEPerfTest.h"
+
+--- a/gfx/layers/client/TiledContentClient.cpp
++++ b/gfx/layers/client/TiledContentClient.cpp
+@@ -3,6 +3,7 @@
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
++#include <limits>
+ #include "mozilla/layers/TiledContentClient.h"
+ #include <math.h> // for ceil, ceilf, floor
+ #include <algorithm>
+
+--- a/gfx/ots/src/hdmx.cc
++++ b/gfx/ots/src/hdmx.cc
+@@ -2,6 +2,8 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+
++#include <limits>
++
+ #include "hdmx.h"
+ #include "head.h"
+ #include "maxp.h"
+
+--- a/gfx/ots/src/kern.cc
++++ b/gfx/ots/src/kern.cc
+@@ -2,6 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+
++#include <limits>
+ #include "kern.h"
+
+ // kern - Kerning
+
+--- a/gfx/ots/src/name.cc
++++ b/gfx/ots/src/name.cc
+@@ -4,6 +4,7 @@
+
+ #include "name.h"
+
++#include <limits>
+ #include <algorithm>
+ #include <cstring>
+
+--- a/gfx/skia/skia/include/core/SkPathRef.h
++++ b/gfx/skia/skia/include/core/SkPathRef.h
+@@ -18,6 +18,8 @@
+ #include "SkRefCnt.h"
+ #include "../private/SkTemplates.h"
+
++#include <limits>
++
+ class SkRBuffer;
+ class SkWBuffer;
+
+--- a/gfx/skia/skia/include/private/SkTDArray.h
++++ b/gfx/skia/skia/include/private/SkTDArray.h
+@@ -10,6 +10,8 @@
+ #ifndef SkTDArray_DEFINED
+ #define SkTDArray_DEFINED
+
++#include <limits>
++
+ #include "SkTypes.h"
+
+ template <typename T> class SkTDArray {
+
+--- a/gfx/skia/skia/src/core/SkColorSpace_ICC.cpp
++++ b/gfx/skia/skia/src/core/SkColorSpace_ICC.cpp
+@@ -5,6 +5,8 @@
+ * found in the LICENSE file.
+ */
+
++#include <limits>
++
+ #include "SkColorSpace.h"
+ #include "SkColorSpace_Base.h"
+ #include "SkColorSpacePriv.h"
+
+--- a/gfx/skia/skia/src/core/SkEdgeBuilder.cpp
++++ b/gfx/skia/skia/src/core/SkEdgeBuilder.cpp
+@@ -4,6 +4,9 @@
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
++
++#include <limits>
++
+ #include "SkEdgeBuilder.h"
+ #include "SkPath.h"
+ #include "SkEdge.h"
+
+--- a/gfx/skia/skia/src/core/SkMask.cpp
++++ b/gfx/skia/skia/src/core/SkMask.cpp
+@@ -5,6 +5,7 @@
+ * found in the LICENSE file.
+ */
+
++#include <limits>
+ #include "SkMask.h"
+
+ //#define TRACK_SKMASK_LIFETIME
+
+--- a/gfx/skia/skia/src/sksl/SkSLUtil.h
++++ b/gfx/skia/skia/src/sksl/SkSLUtil.h
+@@ -8,6 +8,7 @@
+ #ifndef SKSL_UTIL
+ #define SKSL_UTIL
+
++#include <limits>
+ #include <iomanip>
+ #include <string>
+ #include <sstream>
+
+--- a/gfx/thebes/gfxUserFontSet.cpp
++++ b/gfx/thebes/gfxUserFontSet.cpp
+@@ -24,6 +24,8 @@
+ #include "opentype-sanitiser.h"
+ #include "ots-memory-stream.h"
+
++#include <limits>
++
+ using namespace mozilla;
+
+ mozilla::LogModule*
+
+--- a/intl/unicharutil/util/ICUUtils.cpp
++++ b/intl/unicharutil/util/ICUUtils.cpp
+@@ -4,6 +4,8 @@
+
+ #ifdef MOZILLA_INTERNAL_API
+
++#include <limits>
++
+ #include "ICUUtils.h"
+ #include "mozilla/Preferences.h"
+ #include "nsIContent.h"
+
+--- a/ipc/chromium/src/chrome/common/ipc_channel_win.cc
++++ b/ipc/chromium/src/chrome/common/ipc_channel_win.cc
+@@ -5,6 +5,7 @@
+
+ #include "chrome/common/ipc_channel_win.h"
+
++#include <limits>
+ #include <windows.h>
+ #include <sstream>
+
+--- a/ipc/glue/Faulty.cpp
++++ b/ipc/glue/Faulty.cpp
+@@ -12,6 +12,7 @@
+ #include "prenv.h"
+ #include "mozilla/TypeTraits.h"
+ #include <cmath>
++#include <limits>
+ #include <climits>
+
+ namespace mozilla {
+
+--- a/ipc/glue/GeckoChildProcessHost.cpp
++++ b/ipc/glue/GeckoChildProcessHost.cpp
+@@ -43,6 +43,8 @@
+ #include "nsNativeCharsetUtils.h"
+ #include "nscore.h" // for NS_FREE_PERMANENT_DATA
+
++#include <limits>
++
+ using mozilla::MonitorAutoLock;
+ using mozilla::ipc::GeckoChildProcessHost;
+
+
+--- a/js/src/jit/ExecutableAllocator.cpp
++++ b/js/src/jit/ExecutableAllocator.cpp
+@@ -24,8 +24,9 @@
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+-#include "jit/ExecutableAllocator.h"
++#include <limits>
+
++#include "jit/ExecutableAllocator.h"
+ #include "jit/JitCompartment.h"
+ #include "js/MemoryMetrics.h"
+
+--- a/js/src/new-regexp/regexp-bytecode-peephole.cc
++++ b/js/src/new-regexp/regexp-bytecode-peephole.cc
+@@ -2,8 +2,9 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+
+-#include "new-regexp/regexp-bytecode-peephole.h"
++#include <limits>
+
++#include "new-regexp/regexp-bytecode-peephole.h"
+ #include "new-regexp/regexp-bytecodes.h"
+
+ namespace v8 {
+
+--- a/js/src/new-regexp/util/vector.h
++++ b/js/src/new-regexp/util/vector.h
+@@ -5,6 +5,7 @@
+ #ifndef V8_UTIL_VECTOR_H_
+ #define V8_UTIL_VECTOR_H_
+
++#include <limits>
+ #include <algorithm>
+ #include <cstring>
+ #include <iterator>
+
+--- a/js/src/vm/ArrayBufferObject.h
++++ b/js/src/vm/ArrayBufferObject.h
+@@ -6,6 +6,8 @@
+ #ifndef vm_ArrayBufferObject_h
+ #define vm_ArrayBufferObject_h
+
++#include <limits>
++
+ #include "mozilla/Maybe.h"
+
+ #include "jsobj.h"
+
+--- a/layout/generic/nsViewportFrame.cpp
++++ b/layout/generic/nsViewportFrame.cpp
+@@ -18,6 +18,8 @@
+ #include "nsIMozBrowserFrame.h"
+ #include "nsPlaceholderFrame.h"
+
++#include <limits>
++
+ using namespace mozilla;
+ typedef nsAbsoluteContainingBlock::AbsPosReflowFlags AbsPosReflowFlags;
+
+--- a/layout/style/CounterStyleManager.cpp
++++ b/layout/style/CounterStyleManager.cpp
+@@ -20,6 +20,8 @@
+ #include "mozilla/StyleSetHandle.h"
+ #include "mozilla/StyleSetHandleInlines.h"
+
++#include <limits>
++
+ namespace mozilla {
+
+ struct AdditiveSymbol
+
+--- a/layout/style/StyleAnimationValue.cpp
++++ b/layout/style/StyleAnimationValue.cpp
+@@ -33,6 +33,8 @@
+ #include "nsIFrame.h"
+ #include "gfx2DGlue.h"
+
++#include <limits>
++
+ using namespace mozilla;
+ using namespace mozilla::css;
+ using namespace mozilla::gfx;
+
+--- a/layout/style/nsStyleContext.cpp
++++ b/layout/style/nsStyleContext.cpp
+@@ -43,6 +43,8 @@
+ // those in ServoBindings.h.
+ #include "mozilla/ServoBindings.h"
+
++#include <limits>
++
+ using namespace mozilla;
+
+ //----------------------------------------------------------------------
+
+--- a/layout/svg/SVGTextFrame.h
++++ b/layout/svg/SVGTextFrame.h
+@@ -17,6 +17,8 @@
+ #include "nsStubMutationObserver.h"
+ #include "nsSVGContainerFrame.h"
+
++#include <limits>
++
+ class gfxContext;
+ class nsDisplaySVGText;
+ class SVGTextFrame;
+
+--- a/mailnews/import/becky/src/nsBeckyAddressBooks.cpp
++++ b/mailnews/import/becky/src/nsBeckyAddressBooks.cpp
+@@ -2,6 +2,8 @@
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
++#include <limits>
++
+ #include "nsCOMPtr.h"
+ #include "nsComponentManagerUtils.h"
+ #include "nsServiceManagerUtils.h"
+
+--- a/media/webrtc/trunk/testing/gtest/src/gtest.cc
++++ b/media/webrtc/trunk/testing/gtest/src/gtest.cc
+@@ -43,6 +43,7 @@
+ #include <wchar.h>
+ #include <wctype.h>
+
++#include <limits>
+ #include <algorithm>
+ #include <ostream> // NOLINT
+ #include <sstream>
+
+--- a/media/webrtc/trunk/webrtc/base/bitbuffer_unittest.cc
++++ b/media/webrtc/trunk/webrtc/base/bitbuffer_unittest.cc
+@@ -8,6 +8,8 @@
+ * be found in the AUTHORS file in the root of the source tree.
+ */
+
++#include <limits>
++
+ #include "webrtc/base/arraysize.h"
+ #include "webrtc/base/bitbuffer.h"
+ #include "webrtc/base/bytebuffer.h"
+
+--- a/media/webrtc/trunk/webrtc/modules/audio_coding/codecs/opus/audio_encoder_opus.cc
++++ b/media/webrtc/trunk/webrtc/modules/audio_coding/codecs/opus/audio_encoder_opus.cc
+@@ -8,6 +8,8 @@
+ * be found in the AUTHORS file in the root of the source tree.
+ */
+
++#include <limits>
++
+ #include "webrtc/modules/audio_coding/codecs/opus/interface/audio_encoder_opus.h"
+
+ #include "webrtc/base/checks.h"
+
+--- a/media/webrtc/trunk/webrtc/modules/audio_device/android/audio_device_unittest.cc
++++ b/media/webrtc/trunk/webrtc/modules/audio_device/android/audio_device_unittest.cc
+@@ -8,6 +8,7 @@
+ * be found in the AUTHORS file in the root of the source tree.
+ */
+
++#include <limits>
+ #include <list>
+ #include <numeric>
+
+--- a/media/webrtc/trunk/webrtc/modules/audio_processing/transient/transient_suppressor.cc
++++ b/media/webrtc/trunk/webrtc/modules/audio_processing/transient/transient_suppressor.cc
+@@ -10,6 +10,7 @@
+
+ #include "webrtc/modules/audio_processing/transient/transient_suppressor.h"
+
++#include <limits>
+ #include <math.h>
+ #include <string.h>
+ #include <cmath>
+
+--- a/media/webrtc/trunk/webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.cc
++++ b/media/webrtc/trunk/webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.cc
+@@ -9,6 +9,7 @@
+ */
+ #include "webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.h"
+
++#include <limits>
+ #include <algorithm>
+ #include <utility>
+
+--- a/media/webrtc/trunk/webrtc/video_engine/test/auto_test/source/vie_autotest_custom_call.cc
++++ b/media/webrtc/trunk/webrtc/video_engine/test/auto_test/source/vie_autotest_custom_call.cc
+@@ -9,6 +9,7 @@
+ */
+
+ #include <limits.h>
++#include <limits>
+ #include <stdarg.h>
+ #include <stdio.h>
+
+--- a/mfbt/IntegerTypeTraits.h
++++ b/mfbt/IntegerTypeTraits.h
+@@ -8,6 +8,8 @@
+ #ifndef mozilla_IntegerTypeTraits_h
+ #define mozilla_IntegerTypeTraits_h
+
++#include <limits>
++
+ #include "mozilla/TypeTraits.h"
+ #include <stdint.h>
+
+--- a/mfbt/decimal/Decimal.cpp
++++ b/mfbt/decimal/Decimal.cpp
+@@ -28,6 +28,8 @@
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
++#include <limits>
++
+ #include "Decimal.h"
+ #include "moz-decimal-utils.h"
+
+--- a/modules/woff2/src/normalize.cc
++++ b/modules/woff2/src/normalize.cc
+@@ -8,6 +8,7 @@
+
+ #include "./normalize.h"
+
++#include <limits>
+ #include <inttypes.h>
+ #include <stddef.h>
+
+--- a/netwerk/base/nsIOService.cpp
++++ b/netwerk/base/nsIOService.cpp
+@@ -4,6 +4,8 @@
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
++#include <limits>
++
+ #include "mozilla/ArrayUtils.h"
+ #include "mozilla/DebugOnly.h"
+
+--- a/netwerk/base/nsStandardURL.cpp
++++ b/netwerk/base/nsStandardURL.cpp
+@@ -4,6 +4,8 @@
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
++#include <limits>
++
+ #include "IPCMessageUtils.h"
+
+ #include "nsStandardURL.h"
+
+--- a/netwerk/base/nsURLParsers.cpp
++++ b/netwerk/base/nsURLParsers.cpp
+@@ -4,6 +4,7 @@
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
+ #include <string.h>
++#include <limits>
+
+ #include "mozilla/RangedPtr.h"
+
+--- a/security/manager/ssl/TransportSecurityInfo.cpp
++++ b/security/manager/ssl/TransportSecurityInfo.cpp
+@@ -4,6 +4,7 @@
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
++#include <limits>
+ #include "TransportSecurityInfo.h"
+
+ #include "PSMRunnable.h"
+
+--- a/security/nss/gtests/google_test/gtest/test/googletest-death-test-test.cc
++++ b/security/nss/gtests/google_test/gtest/test/googletest-death-test-test.cc
+@@ -30,6 +30,8 @@
+ //
+ // Tests for death tests.
+
++#include <limits>
++
+ #include "gtest/gtest-death-test.h"
+ #include "gtest/gtest.h"
+ #include "gtest/internal/gtest-filepath.h"
+
+--- a/testing/gtest/gtest/src/gtest.cc
++++ b/testing/gtest/gtest/src/gtest.cc
+@@ -42,6 +42,7 @@
+ #include <wchar.h>
+ #include <wctype.h>
+
++#include <limits>
+ #include <algorithm>
+ #include <ostream> // NOLINT
+ #include <sstream>
+
+--- a/toolkit/components/telemetry/Telemetry.cpp
++++ b/toolkit/components/telemetry/Telemetry.cpp
+@@ -3,8 +3,8 @@
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
++#include <limits>
+ #include <algorithm>
+-
+ #include <fstream>
+
+ #include <prio.h>
+
+--- a/toolkit/components/url-classifier/RiceDeltaDecoder.cpp
++++ b/toolkit/components/url-classifier/RiceDeltaDecoder.cpp
+@@ -2,6 +2,7 @@
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
++#include <limits>
+ #include "RiceDeltaDecoder.h"
+
+ namespace {
diff --git a/newmoon/revert-mach-file.patch b/newmoon/revert-mach-file.patch
new file mode 100644
index 0000000..cda3786
--- /dev/null
+++ b/newmoon/revert-mach-file.patch
@@ -0,0 +1,71 @@
+Description: revert mach file to 29.4.2's to fix FTBFS
+Last-Update: 2021-11-12
+
+--- palemoon-29.4.2.1.orig/mach
++++ palemoon-29.4.2.1/mach
+@@ -1,63 +1,4 @@
+ #!/bin/sh
+
+-MCP_MACH=./platform/mach
+-MCP_GIT=`which git 2>/dev/null`
+-
+-if [ ! -f "$MCP_MACH" ]; then
+- printf "Error: There is no platform codebase.\n"
+- exit 1
+-fi
+-
+-MCP_APP=palemoon
+-MCP_VERSION=`cat ./$MCP_APP/config/version.txt`
+-
+-MCP_XZ=`which xz 2>/dev/null`
+-MCP_TAR_BASEDIR="s/^./$MCP_APP-source/"
+-MCP_TAR_FILENAME="$MCP_APP-$MCP_VERSION.source.tar.xz"
+-MCP_TAR_COMMAND="tar cfJv ../$MCP_TAR_FILENAME . --transform $MCP_TAR_BASEDIR --exclude-vcs --warning=no-file-changed"
+-MCP_TAR_EXCLUDES=(
+- "$MCP_APP/branding/beta"
+- "$MCP_APP/branding/unstable"
+- "platform/db/mork"
+- "platform/docs"
+- "platform/ldap"
+- "platform/libs/gmp-clearkey"
+- "platform/mailnews"
+- "platform/python/psutil/*.so"
+- "platform/python/psutil/*.pyd"
+- "platform/python/psutil/build"
+- "platform/xulrunner"
+- ".mozconfig"
+- ".gitattributes"
+- ".gitignore"
+- ".gitmodules"
+- "*.pyc"
+- "*.pyo"
+- "*.rej"
+- "*.orig"
+- "*.source.tar.xz"
+-)
+-
+-if [ "$1" == "source" ]; then
+- if [ -z "$MCP_XZ" ]; then
+- printf "Error: XZ was not found on the system. NOTE: This won't work on Windows.\n"
+- exit 1
+- fi
+-
+- for _value in "${MCP_TAR_EXCLUDES[@]}"; do
+- MCP_TAR_COMMAND+=" --exclude=${_value}"
+- done
+-
+- if [[ -n "$MCP_GIT" && -d "./.git" && -d "./platform/.git" ]]; then
+- printf "COMM SHA1: `"${MCP_GIT}" rev-parse --short HEAD 2>/dev/null`\n"
+- printf "GRE SHA1: `cd ./platform && "${MCP_GIT}" rev-parse --short HEAD 2>/dev/null`\n"
+- fi
+-
+- printf "Source Filename: $MCP_TAR_FILENAME\n\n"
+- read -r -s -p $'Press enter to continue...\n'
+- env XZ_OPTS=-9e ${MCP_TAR_COMMAND}
+-else
+- # We don't know what the command is but real-mach might so just pass
+- # all the args to it
+- $MCP_MACH $@
+-fi
++MACH_CMD=./platform/mach
++$MACH_CMD $@
bgstack15