commit: 2ea22f9e6cec238b784825e331b2d921b0f1f4d2
Author: Felix Janda <felix.janda <AT> posteo <DOT> de>
AuthorDate: Sun Mar 22 08:54:56 2015 +0000
Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
CommitDate: Mon Apr 6 21:04:20 2015 +0000
URL: https://gitweb.gentoo.org/proj/hardened-dev.git/commit/?id=2ea22f9e
www-client/firefox: Update to 37.0.1
www-client/firefox/files/1130164.patch | 68 +++
www-client/firefox/files/1130175.patch | 33 ++
www-client/firefox/files/1130710.patch | 57 +++
www-client/firefox/files/avoid-basename-musl.patch | 30 --
.../firefox/files/avoid-fts-on-nonglibc-musl.patch | 55 ---
.../firefox/files/avoid-getcontext-musl.patch | 15 -
www-client/firefox/files/basename.patch | 25 ++
www-client/firefox/files/crashreporter.patch | 358 +++++++++++++++
.../files/define-gettid-unconditonally-musl.patch | 11 -
.../firefox/files/dont-include-aouth-musl.patch | 14 -
.../dont-include-cdefsh-stagefright-musl.patch | 10 -
...refox-31.0-webm-disallow-negative-samples.patch | 29 --
.../files/firefox-32.0-hppa-js-configure.patch | 21 -
.../files/firefox-33.0-jemalloc-configure.patch | 29 --
.../files/firefox-35.0-gmp-clearkey-sprintf.patch | 10 +
.../firefox/files/fix-amd64-build-musl.patch | 39 --
.../firefox/files/fix-android-check-musl.patch | 11 -
.../firefox/files/fix-jemalloc-includes-musl.patch | 10 -
.../files/fix-mtransport-includes-musl.patch | 20 -
www-client/firefox/files/fts.patch | 480 +++++++++++++++++++++
.../firefox/files/include-systypesh-musl.patch | 21 -
.../firefox/files/libstagefright-cdefs.patch | 21 +
.../files/make-handleInt-unsigned-long-musl.patch | 11 -
www-client/firefox/files/profiler-gettid.patch | 51 +++
www-client/firefox/files/sandbox-cdefs.patch | 21 +
...{fix-sctp-includes-musl.patch => sctp-36.patch} | 25 +-
www-client/firefox/files/sctp.patch | 58 +++
www-client/firefox/files/sipcc.patch | 159 +++++++
www-client/firefox/files/stab.h | 72 ----
www-client/firefox/files/updater.patch | 42 ++
www-client/firefox/files/xpcom-blocksize.patch | 22 +
...34.0.5-r99.ebuild => firefox-37.0.1-r99.ebuild} | 111 +++--
32 files changed, 1472 insertions(+), 467 deletions(-)
diff --git a/www-client/firefox/files/1130164.patch
b/www-client/firefox/files/1130164.patch
new file mode 100644
index 0000000..2b292f8
--- /dev/null
+++ b/www-client/firefox/files/1130164.patch
@@ -0,0 +1,68 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1423173074 -3600
+# Thu Feb 05 22:51:14 2015 +0100
+# Node ID a446b4e607445d1c6faec25b43a5d9b5d45bcacf
+# Parent 89120ad0518fb4932de5b5f466debed68ee787ce
+Bug 1130164 - tools/profiler: Use <stdint.h> types. r=jseward
+
+diff -r 89120ad0518f -r a446b4e60744 tools/profiler/UnwinderThread2.cpp
+--- a/tools/profiler/UnwinderThread2.cpp Thu Mar 05 06:04:03 2015 -0500
++++ b/tools/profiler/UnwinderThread2.cpp Thu Feb 05 22:51:14 2015 +0100
+@@ -470,7 +470,7 @@
+ //////////////////////////////////////////////////////////
+
+ // This is the interface to LUL.
+-typedef struct { u_int64_t pc; u_int64_t sp; } PCandSP;
++typedef struct { uint64_t pc; uint64_t sp; } PCandSP;
+
+ // Forward declaration. Implementation is below.
+ static
+@@ -1338,7 +1338,7 @@
+ else {
+ // We have at least one N and one P entry available.
+ // Scan forwards to find the SP of the current P entry
+- u_int64_t sp_cur_P = 0;
++ uint64_t sp_cur_P = 0;
+ unsigned int m = next_P + 1;
+ while (1) {
+ /* This assertion should hold because in a well formed
+@@ -1349,7 +1349,7 @@
+ if (ent.is_ent_hint('Q'))
+ break;
+ if (ent.is_ent('S')) {
+- sp_cur_P = reinterpret_cast<u_int64_t>(ent.get_tagPtr());
++ sp_cur_P = reinterpret_cast<uint64_t>(ent.get_tagPtr());
+ break;
+ }
+ m++;
+@@ -1358,7 +1358,7 @@
+ if (0) LOG(" P <= last_was_P && sp_cur_P == 0");
+ use_P = true;
+ } else {
+- u_int64_t sp_cur_N = pairs[next_N].sp;
++ uint64_t sp_cur_N = pairs[next_N].sp;
+ use_P = (sp_cur_P > sp_cur_N);
+ if (0) LOGF(" %s <= sps P %p N %p",
+ use_P ? "P" : "N", (void*)(intptr_t)sp_cur_P,
+diff -r 89120ad0518f -r a446b4e60744
tools/profiler/local_debug_info_symbolizer.cc
+--- a/tools/profiler/local_debug_info_symbolizer.cc Thu Mar 05 06:04:03
2015 -0500
++++ b/tools/profiler/local_debug_info_symbolizer.cc Thu Feb 05 22:51:14
2015 +0100
+@@ -222,7 +222,7 @@
+ debug_info_module = it->second;
+ }
+
+- u_int64_t address = frame->instruction - frame->module->base_address();
++ uint64_t address = frame->instruction - frame->module->base_address();
+ Module::Function* function =
+ debug_info_module->FindFunctionByAddress(address);
+ if (function) {
+@@ -282,7 +282,7 @@
+ if (it == symbols_.end()) return NULL;
+
+ Module* module = it->second;
+- u_int64_t address = frame->instruction - frame->module->base_address();
++ uint64_t address = frame->instruction - frame->module->base_address();
+ Module::StackFrameEntry* entry =
+ module->FindStackFrameEntryByAddress(address);
+ if (!entry)
diff --git a/www-client/firefox/files/1130175.patch
b/www-client/firefox/files/1130175.patch
new file mode 100644
index 0000000..8946a56
--- /dev/null
+++ b/www-client/firefox/files/1130175.patch
@@ -0,0 +1,33 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1423171460 -3600
+# Thu Feb 05 22:24:20 2015 +0100
+# Node ID af818fbea923d7c026bc8e22a6512f14f788ba56
+# Parent 9c40ffbcf6b32d688abf089f2cce3c85dd8bdb29
+Bug 1130175 - nICEr: avoid sysctl.h include. r=bwc
+
+diff -r 9c40ffbcf6b3 -r af818fbea923
media/mtransport/third_party/nICEr/src/stun/addrs.c
+--- a/media/mtransport/third_party/nICEr/src/stun/addrs.c Mon Feb 23
07:39:00 2015 -0500
++++ b/media/mtransport/third_party/nICEr/src/stun/addrs.c Thu Feb 05
22:24:20 2015 +0100
+@@ -45,13 +45,11 @@
+ #include <sys/param.h>
+ #include <sys/socket.h>
+ #ifndef ANDROID
+-#include <sys/sysctl.h>
+ #include <sys/syslog.h>
+ #else
+ #include <syslog.h>
+ /* Work around an Android NDK < r8c bug */
+ #undef __unused
+-#include <linux/sysctl.h>
+ #endif
+ #ifndef LINUX
+ #include <net/if.h>
+@@ -122,6 +120,7 @@
+ */
+
+ #include <err.h>
++#include <sys/sysctl.h>
+
+ static void stun_rt_xaddrs(caddr_t, caddr_t, struct rt_addrinfo *);
+ static int stun_grab_addrs(char *name, int addrcount,
diff --git a/www-client/firefox/files/1130710.patch
b/www-client/firefox/files/1130710.patch
new file mode 100644
index 0000000..02c2877
--- /dev/null
+++ b/www-client/firefox/files/1130710.patch
@@ -0,0 +1,57 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1423172841 -3600
+# Node ID 48efa200aae98f4b5fced4f1afa4f1b8c8cde9e1
+# Parent 3693f117ad5018927922c92cf5bd9739bc25f394
+Bug 1130710 - xre: Use stdint uint*_t instead of nonstandard __uint*_t.
r=bsmedberg
+
+diff --git a/toolkit/xre/nsSigHandlers.cpp b/toolkit/xre/nsSigHandlers.cpp
+--- a/toolkit/xre/nsSigHandlers.cpp
++++ b/toolkit/xre/nsSigHandlers.cpp
+@@ -160,17 +160,17 @@ static void fpehandler(int signum, sigin
+ #if defined(__i386__) || defined(__amd64__)
+ _STRUCT_FP_CONTROL *ctrl = &uc->uc_mcontext->__fs.__fpu_fcw;
+ ctrl->__invalid = ctrl->__denorm = ctrl->__zdiv = ctrl->__ovrfl =
ctrl->__undfl = ctrl->__precis = 1;
+
+ _STRUCT_FP_STATUS *status = &uc->uc_mcontext->__fs.__fpu_fsw;
+ status->__invalid = status->__denorm = status->__zdiv = status->__ovrfl =
status->__undfl =
+ status->__precis = status->__stkflt = status->__errsumm = 0;
+
+- __uint32_t *mxcsr = &uc->uc_mcontext->__fs.__fpu_mxcsr;
++ uint32_t *mxcsr = &uc->uc_mcontext->__fs.__fpu_mxcsr;
+ *mxcsr |= SSE_EXCEPTION_MASK; /* disable all SSE exceptions */
+ *mxcsr &= ~SSE_STATUS_FLAGS; /* clear all pending SSE exceptions */
+ #endif
+ #endif
+ #if defined(LINUX) && !defined(ANDROID)
+ ucontext_t *uc = (ucontext_t *)context;
+
+ #if defined(__i386__)
+@@ -180,23 +180,23 @@ static void fpehandler(int signum, sigin
+ */
+ unsigned long int *cw = &uc->uc_mcontext.fpregs->cw;
+ *cw |= FPU_EXCEPTION_MASK;
+
+ unsigned long int *sw = &uc->uc_mcontext.fpregs->sw;
+ *sw &= ~FPU_STATUS_FLAGS;
+ #endif
+ #if defined(__amd64__)
+- __uint16_t *cw = &uc->uc_mcontext.fpregs->cwd;
++ uint16_t *cw = &uc->uc_mcontext.fpregs->cwd;
+ *cw |= FPU_EXCEPTION_MASK;
+
+- __uint16_t *sw = &uc->uc_mcontext.fpregs->swd;
++ uint16_t *sw = &uc->uc_mcontext.fpregs->swd;
+ *sw &= ~FPU_STATUS_FLAGS;
+
+- __uint32_t *mxcsr = &uc->uc_mcontext.fpregs->mxcsr;
++ uint32_t *mxcsr = &uc->uc_mcontext.fpregs->mxcsr;
+ *mxcsr |= SSE_EXCEPTION_MASK; /* disable all SSE exceptions */
+ *mxcsr &= ~SSE_STATUS_FLAGS; /* clear all pending SSE exceptions */
+ #endif
+ #endif
+ #ifdef SOLARIS
+ ucontext_t *uc = (ucontext_t *)context;
+
+ #if defined(__i386)
+
diff --git a/www-client/firefox/files/avoid-basename-musl.patch
b/www-client/firefox/files/avoid-basename-musl.patch
deleted file mode 100644
index 63ba50b..0000000
--- a/www-client/firefox/files/avoid-basename-musl.patch
+++ /dev/null
@@ -1,30 +0,0 @@
----
a/mozilla-release/toolkit/crashreporter/google-breakpad/src/common/linux/dump_symbols.cc
-+++
b/mozilla-release/toolkit/crashreporter/google-breakpad/src/common/linux/dump_symbols.cc
-@@ -834,9 +834,9 @@
- // last slash, or the whole filename if there are no slashes.
- string BaseFileName(const string &filename) {
- // Lots of copies! basename's behavior is less than ideal.
-- char *c_filename = strdup(filename.c_str());
-- string base = basename(c_filename);
-- free(c_filename);
-+ const char *c_filename = filename.c_str();
-+ const char *p = strrchr(c_filename, '/');
-+ string base = p ? p+1 : c_filename;
- return base;
- }
-
---- a/mozilla-release/tools/profiler/LulElf.cpp
-+++ b/mozilla-release/tools/profiler/LulElf.cpp
-@@ -580,9 +580,9 @@
- // last slash, or the whole filename if there are no slashes.
- string BaseFileName(const string &filename) {
- // Lots of copies! basename's behavior is less than ideal.
-- char *c_filename = strdup(filename.c_str());
-- string base = basename(c_filename);
-- free(c_filename);
-+ const char *c_filename = filename.c_str();
-+ const char *p = strrchr(c_filename, '/');
-+ string base = p ? p+1 : c_filename;
- return base;
- }
-
diff --git a/www-client/firefox/files/avoid-fts-on-nonglibc-musl.patch
b/www-client/firefox/files/avoid-fts-on-nonglibc-musl.patch
deleted file mode 100644
index fdabf90..0000000
--- a/www-client/firefox/files/avoid-fts-on-nonglibc-musl.patch
+++ /dev/null
@@ -1,55 +0,0 @@
---- a/mozilla-release/ipc/chromium/src/base/file_util.h
-+++ b/mozilla-release/ipc/chromium/src/base/file_util.h
-@@ -14,10 +14,15 @@
- #include <windows.h>
- #elif defined(ANDROID)
- #include <sys/stat.h>
-+#define NO_FTS
- #elif defined(OS_POSIX)
- #include <sys/types.h>
--#include <fts.h>
- #include <sys/stat.h>
-+#ifdef __GLIBC__
-+#include <fts.h>
-+#else
-+#define NO_FTS
-+#endif
- #endif
-
- #include <stdio.h>
---- a/mozilla-release/ipc/chromium/src/base/file_util_posix.cc
-+++ b/mozilla-release/ipc/chromium/src/base/file_util_posix.cc
-@@ -8,13 +8,13 @@
- #include <errno.h>
- #include <fcntl.h>
- #include <fnmatch.h>
--#ifndef ANDROID
-+#ifndef NO_FTS
- #include <fts.h>
- #endif
- #include <libgen.h>
- #include <stdio.h>
- #include <string.h>
--#include <sys/errno.h>
-+#include <errno.h>
- #include <sys/mman.h>
- #define _DARWIN_USE_64_BIT_INODE // Use 64-bit inode data structures
- #include <sys/stat.h>
-@@ -67,7 +67,7 @@
- if (!recursive)
- return (rmdir(path_str) == 0);
-
--#ifdef ANDROID
-+#ifdef NO_FTS
- // XXX Need ftsless impl for bionic
- return false;
- #else
-@@ -140,7 +140,7 @@
- return false;
- }
-
--#ifdef ANDROID
-+#ifdef NO_FTS
- // XXX Need ftsless impl for bionic
- return false;
- #else
diff --git a/www-client/firefox/files/avoid-getcontext-musl.patch
b/www-client/firefox/files/avoid-getcontext-musl.patch
deleted file mode 100644
index e8e2fc0..0000000
--- a/www-client/firefox/files/avoid-getcontext-musl.patch
+++ /dev/null
@@ -1,15 +0,0 @@
---- a/mozilla-release/tools/profiler/platform-linux.cc
-+++ b/mozilla-release/tools/profiler/platform-linux.cc
-@@ -625,10 +625,10 @@
- {
- MOZ_ASSERT(aContext);
- ucontext_t* pContext = reinterpret_cast<ucontext_t*>(aContext);
-- if (!getcontext(pContext)) {
-+ /*if (!getcontext(pContext)) {
- context = pContext;
- SetSampleContext(this, aContext);
-- }
-+ }*/
- }
-
- void OS::SleepMicro(int microseconds)
diff --git a/www-client/firefox/files/basename.patch
b/www-client/firefox/files/basename.patch
new file mode 100644
index 0000000..bfbfaea
--- /dev/null
+++ b/www-client/firefox/files/basename.patch
@@ -0,0 +1,25 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1423172942 -3600
+# Thu Feb 05 22:49:02 2015 +0100
+# Node ID 5f3abeb6ae6c0512901724428d908f601b9e49d4
+# Parent 2d344ef8da33717224d5a08570dc834ca2254f9f
+# https://bugzilla.mozilla.org/show_bug.cgi?id=1041962
+LulElf: Avoid basename
+
+diff -r 2d344ef8da33 -r 5f3abeb6ae6c tools/profiler/LulElf.cpp
+--- a/tools/profiler/LulElf.cpp Sun Feb 01 19:32:36 2015 +0100
++++ b/tools/profiler/LulElf.cpp Thu Feb 05 22:49:02 2015 +0100
+@@ -611,9 +611,9 @@
+ // last slash, or the whole filename if there are no slashes.
+ string BaseFileName(const string &filename) {
+ // Lots of copies! basename's behavior is less than ideal.
+- char *c_filename = strdup(filename.c_str());
+- string base = basename(c_filename);
+- free(c_filename);
++ const char *c_filename = filename.c_str();
++ const char *p = strrchr(c_filename, '/');
++ string base = p ? p+1 : c_filename;
+ return base;
+ }
+
diff --git a/www-client/firefox/files/crashreporter.patch
b/www-client/firefox/files/crashreporter.patch
new file mode 100644
index 0000000..719ed0d
--- /dev/null
+++ b/www-client/firefox/files/crashreporter.patch
@@ -0,0 +1,358 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1423172597 -3600
+# Thu Feb 05 22:43:17 2015 +0100
+# Node ID df5ec9e5685a52bcd19bbe566c0770daa40f14b1
+# Parent 2d344ef8da33717224d5a08570dc834ca2254f9f
+crashreporter: compile with musl
+
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/google-breakpad/src/client/linux/crash_generation/crash_generation_server.cc
+---
a/toolkit/crashreporter/google-breakpad/src/client/linux/crash_generation/crash_generation_server.cc
Sun Feb 01 19:32:36 2015 +0100
++++
b/toolkit/crashreporter/google-breakpad/src/client/linux/crash_generation/crash_generation_server.cc
Thu Feb 05 22:43:17 2015 +0100
+@@ -28,7 +28,6 @@
+ // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+ #include <assert.h>
+-#include <dirent.h>
+ #include <fcntl.h>
+ #include <limits.h>
+ #include <poll.h>
+@@ -49,6 +48,8 @@
+ #include "common/linux/guid_creator.h"
+ #include "common/linux/safe_readlink.h"
+
++#include <dirent.h>
++
+ static const char kCommandQuit = 'x';
+
+ namespace google_breakpad {
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/google-breakpad/src/client/linux/handler/exception_handler.cc
+---
a/toolkit/crashreporter/google-breakpad/src/client/linux/handler/exception_handler.cc
Sun Feb 01 19:32:36 2015 +0100
++++
b/toolkit/crashreporter/google-breakpad/src/client/linux/handler/exception_handler.cc
Thu Feb 05 22:43:17 2015 +0100
+@@ -77,7 +77,7 @@
+ #include <sys/wait.h>
+ #include <unistd.h>
+
+-#include <sys/signal.h>
++#include <signal.h>
+ #include <sys/ucontext.h>
+ #include <sys/user.h>
+ #include <ucontext.h>
+@@ -418,11 +418,11 @@
+ siginfo_t siginfo = {};
+ // Mimic a trusted signal to allow tracing the process (see
+ // ExceptionHandler::HandleSignal().
+- siginfo.si_code = SI_USER;
+- siginfo.si_pid = getpid();
+- struct ucontext context;
+- getcontext(&context);
+- return HandleSignal(sig, &siginfo, &context);
++// siginfo.si_code = SI_USER;
++// siginfo.si_pid = getpid();
++// struct ucontext context;
++// getcontext(&context);
++// return HandleSignal(sig, &siginfo, &context);
+ }
+
+ // This function may run in a compromised context: see the top of the file.
+@@ -567,7 +567,7 @@
+ sys_prctl(PR_SET_DUMPABLE, 1);
+
+ CrashContext context;
+- int getcontext_result = getcontext(&context.context);
++ int getcontext_result = 1;//getcontext(&context.context);
+ if (getcontext_result)
+ return false;
+ #if !defined(__ARM_EABI__)
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/google-breakpad/src/client/linux/handler/exception_handler.h
+---
a/toolkit/crashreporter/google-breakpad/src/client/linux/handler/exception_handler.h
Sun Feb 01 19:32:36 2015 +0100
++++
b/toolkit/crashreporter/google-breakpad/src/client/linux/handler/exception_handler.h
Thu Feb 05 22:43:17 2015 +0100
+@@ -192,7 +192,7 @@
+ struct ucontext context;
+ #if !defined(__ARM_EABI__)
+ // #ifdef this out because FP state is not part of user ABI for Linux ARM.
+- struct _libc_fpstate float_state;
++ struct _fpstate float_state;
+ #endif
+ };
+
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/google-breakpad/src/client/linux/minidump_writer/minidump_writer.cc
+---
a/toolkit/crashreporter/google-breakpad/src/client/linux/minidump_writer/minidump_writer.cc
Sun Feb 01 19:32:36 2015 +0100
++++
b/toolkit/crashreporter/google-breakpad/src/client/linux/minidump_writer/minidump_writer.cc
Thu Feb 05 22:43:17 2015 +0100
+@@ -174,7 +174,7 @@
+ // out: the minidump structure
+ // info: the collection of register structures.
+ void CPUFillFromUContext(MDRawContextX86 *out, const ucontext *uc,
+- const struct _libc_fpstate* fp) {
++ const struct _fpstate* fp) {
+ const greg_t* regs = uc->uc_mcontext.gregs;
+
+ out->context_flags = MD_CONTEXT_X86_FULL |
+@@ -274,7 +274,7 @@
+ }
+
+ void CPUFillFromUContext(MDRawContextAMD64 *out, const ucontext *uc,
+- const struct _libc_fpstate* fpregs) {
++ const struct _fpstate* fpregs) {
+ const greg_t* regs = uc->uc_mcontext.gregs;
+
+ out->context_flags = MD_CONTEXT_AMD64_FULL;
+@@ -341,7 +341,7 @@
+ }
+
+ void CPUFillFromUContext(MDRawContextARM* out, const ucontext* uc,
+- const struct _libc_fpstate* fpregs) {
++ const struct _fpstate* fpregs) {
+ out->context_flags = MD_CONTEXT_ARM_FULL;
+
+ out->iregs[0] = uc->uc_mcontext.arm_r0;
+@@ -1480,7 +1480,7 @@
+ const char* path_; // Path to the file where the minidum should be written.
+
+ const struct ucontext* const ucontext_; // also from the signal handler
+- const struct _libc_fpstate* const float_state_; // ditto
++ const struct _fpstate* const float_state_; // ditto
+ LinuxDumper* dumper_;
+ MinidumpFileWriter minidump_writer_;
+ off_t minidump_size_limit_;
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/google-breakpad/src/common/android/include/stab.h
+--- a/toolkit/crashreporter/google-breakpad/src/common/android/include/stab.h
Sun Feb 01 19:32:36 2015 +0100
++++ /dev/null Thu Jan 01 00:00:00 1970 +0000
+@@ -1,100 +0,0 @@
+-// Copyright (c) 2012, Google Inc.
+-// All rights reserved.
+-//
+-// Redistribution and use in source and binary forms, with or without
+-// modification, are permitted provided that the following conditions are
+-// met:
+-//
+-// * Redistributions of source code must retain the above copyright
+-// notice, this list of conditions and the following disclaimer.
+-// * Redistributions in binary form must reproduce the above
+-// copyright notice, this list of conditions and the following disclaimer
+-// in the documentation and/or other materials provided with the
+-// distribution.
+-// * Neither the name of Google Inc. nor the names of its
+-// contributors may be used to endorse or promote products derived from
+-// this software without specific prior written permission.
+-//
+-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+-
+-#ifndef GOOGLE_BREAKPAD_COMMON_ANDROID_INCLUDE_STAB_H
+-#define GOOGLE_BREAKPAD_COMMON_ANDROID_INCLUDE_STAB_H
+-
+-#include <sys/cdefs.h>
+-
+-#ifdef __BIONIC_HAVE_STAB_H
+-#include <stab.h>
+-#else
+-
+-#ifdef __cplusplus
+-extern "C" {
+-#endif // __cplusplus
+-
+-#define _STAB_CODE_LIST \
+- _STAB_CODE_DEF(UNDF,0x00) \
+- _STAB_CODE_DEF(GSYM,0x20) \
+- _STAB_CODE_DEF(FNAME,0x22) \
+- _STAB_CODE_DEF(FUN,0x24) \
+- _STAB_CODE_DEF(STSYM,0x26) \
+- _STAB_CODE_DEF(LCSYM,0x28) \
+- _STAB_CODE_DEF(MAIN,0x2a) \
+- _STAB_CODE_DEF(PC,0x30) \
+- _STAB_CODE_DEF(NSYMS,0x32) \
+- _STAB_CODE_DEF(NOMAP,0x34) \
+- _STAB_CODE_DEF(OBJ,0x38) \
+- _STAB_CODE_DEF(OPT,0x3c) \
+- _STAB_CODE_DEF(RSYM,0x40) \
+- _STAB_CODE_DEF(M2C,0x42) \
+- _STAB_CODE_DEF(SLINE,0x44) \
+- _STAB_CODE_DEF(DSLINE,0x46) \
+- _STAB_CODE_DEF(BSLINE,0x48) \
+- _STAB_CODE_DEF(BROWS,0x48) \
+- _STAB_CODE_DEF(DEFD,0x4a) \
+- _STAB_CODE_DEF(EHDECL,0x50) \
+- _STAB_CODE_DEF(MOD2,0x50) \
+- _STAB_CODE_DEF(CATCH,0x54) \
+- _STAB_CODE_DEF(SSYM,0x60) \
+- _STAB_CODE_DEF(SO,0x64) \
+- _STAB_CODE_DEF(LSYM,0x80) \
+- _STAB_CODE_DEF(BINCL,0x82) \
+- _STAB_CODE_DEF(SOL,0x84) \
+- _STAB_CODE_DEF(PSYM,0xa0) \
+- _STAB_CODE_DEF(EINCL,0xa2) \
+- _STAB_CODE_DEF(ENTRY,0xa4) \
+- _STAB_CODE_DEF(LBRAC,0xc0) \
+- _STAB_CODE_DEF(EXCL,0xc2) \
+- _STAB_CODE_DEF(SCOPE,0xc4) \
+- _STAB_CODE_DEF(RBRAC,0xe0) \
+- _STAB_CODE_DEF(BCOMM,0xe2) \
+- _STAB_CODE_DEF(ECOMM,0xe4) \
+- _STAB_CODE_DEF(ECOML,0xe8) \
+- _STAB_CODE_DEF(NBTEXT,0xf0) \
+- _STAB_CODE_DEF(NBDATA,0xf2) \
+- _STAB_CODE_DEF(NBBSS,0xf4) \
+- _STAB_CODE_DEF(NBSTS,0xf6) \
+- _STAB_CODE_DEF(NBLCS,0xf8) \
+- _STAB_CODE_DEF(LENG,0xfe)
+-
+-enum __stab_debug_code {
+-#define _STAB_CODE_DEF(x,y) N_##x = y,
+-_STAB_CODE_LIST
+-#undef _STAB_CODE_DEF
+-};
+-
+-#ifdef __cplusplus
+-} // extern "C"
+-#endif // __cplusplus
+-
+-#endif // __BIONIC_HAVE_STAB_H
+-
+-#endif // GOOGLE_BREAKPAD_COMMON_ANDROID_INCLUDE_STAB_H
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/google-breakpad/src/common/android/include/sys/signal.h
+---
a/toolkit/crashreporter/google-breakpad/src/common/android/include/sys/signal.h
Sun Feb 01 19:32:36 2015 +0100
++++ /dev/null Thu Jan 01 00:00:00 1970 +0000
+@@ -1,35 +0,0 @@
+-// Copyright (c) 2012, Google Inc.
+-// All rights reserved.
+-//
+-// Redistribution and use in source and binary forms, with or without
+-// modification, are permitted provided that the following conditions are
+-// met:
+-//
+-// * Redistributions of source code must retain the above copyright
+-// notice, this list of conditions and the following disclaimer.
+-// * Redistributions in binary form must reproduce the above
+-// copyright notice, this list of conditions and the following disclaimer
+-// in the documentation and/or other materials provided with the
+-// distribution.
+-// * Neither the name of Google Inc. nor the names of its
+-// contributors may be used to endorse or promote products derived from
+-// this software without specific prior written permission.
+-//
+-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+-// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+-// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+-// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+-// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+-// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+-// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+-// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+-// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+-// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+-
+-#ifndef GOOGLE_BREAKPAD_COMMON_ANDROID_INCLUDE_SYS_SIGNAL_H
+-#define GOOGLE_BREAKPAD_COMMON_ANDROID_INCLUDE_SYS_SIGNAL_H
+-
+-#include <signal.h>
+-
+-#endif // GOOGLE_BREAKPAD_COMMON_ANDROID_INCLUDE_SYS_SIGNAL_H
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/google-breakpad/src/common/linux/dump_symbols.cc
+--- a/toolkit/crashreporter/google-breakpad/src/common/linux/dump_symbols.cc
Sun Feb 01 19:32:36 2015 +0100
++++ b/toolkit/crashreporter/google-breakpad/src/common/linux/dump_symbols.cc
Thu Feb 05 22:43:17 2015 +0100
+@@ -829,9 +829,9 @@
+ // last slash, or the whole filename if there are no slashes.
+ string BaseFileName(const string &filename) {
+ // Lots of copies! basename's behavior is less than ideal.
+- char *c_filename = strdup(filename.c_str());
+- string base = basename(c_filename);
+- free(c_filename);
++ const char *c_filename = filename.c_str();
++ const char *p = strrchr(c_filename, '/');
++ string base = p ? p+1 : c_filename;
+ return base;
+ }
+
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/google-breakpad/src/common/linux/elf_core_dump.h
+--- a/toolkit/crashreporter/google-breakpad/src/common/linux/elf_core_dump.h
Sun Feb 01 19:32:36 2015 +0100
++++ b/toolkit/crashreporter/google-breakpad/src/common/linux/elf_core_dump.h
Thu Feb 05 22:43:17 2015 +0100
+@@ -36,6 +36,7 @@
+ #include <elf.h>
+ #include <link.h>
+ #include <stddef.h>
++#include <sys/reg.h>
+
+ #include "common/memory_range.h"
+
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/google-breakpad/src/common/stabs_reader.cc
+--- a/toolkit/crashreporter/google-breakpad/src/common/stabs_reader.cc Sun Feb
01 19:32:36 2015 +0100
++++ b/toolkit/crashreporter/google-breakpad/src/common/stabs_reader.cc Thu Feb
05 22:43:17 2015 +0100
+@@ -34,7 +34,6 @@
+ #include "common/stabs_reader.h"
+
+ #include <assert.h>
+-#include <stab.h>
+ #include <string.h>
+
+ #include <string>
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/google-breakpad/src/common/stabs_reader.h
+--- a/toolkit/crashreporter/google-breakpad/src/common/stabs_reader.h Sun Feb
01 19:32:36 2015 +0100
++++ b/toolkit/crashreporter/google-breakpad/src/common/stabs_reader.h Thu Feb
05 22:43:17 2015 +0100
+@@ -53,12 +53,19 @@
+ #include <config.h>
+ #endif
+
+-#ifdef HAVE_A_OUT_H
+-#include <a.out.h>
+-#endif
+ #ifdef HAVE_MACH_O_NLIST_H
+ #include <mach-o/nlist.h>
+ #endif
++// Definitions from <stab.h> and <a.out.h> for systems which
++// do not have them
++#undef N_UNDF
++#define N_UNDF 0x0
++#define N_FUN 0x24
++#define N_SLINE 0x44
++#define N_SO 0x64
++#define N_LSYM 0x80
++#define N_BINCL 0x82
++#define N_SOL 0x84
+
+ #include <string>
+ #include <vector>
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/google-breakpad/src/common/stabs_reader_unittest.cc
+---
a/toolkit/crashreporter/google-breakpad/src/common/stabs_reader_unittest.cc
Sun Feb 01 19:32:36 2015 +0100
++++
b/toolkit/crashreporter/google-breakpad/src/common/stabs_reader_unittest.cc
Thu Feb 05 22:43:17 2015 +0100
+@@ -33,7 +33,6 @@
+
+ #include <assert.h>
+ #include <errno.h>
+-#include <stab.h>
+ #include <stdarg.h>
+ #include <stdlib.h>
+ #include <string.h>
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/google-breakpad/src/third_party/lss/linux_syscall_support.h
+---
a/toolkit/crashreporter/google-breakpad/src/third_party/lss/linux_syscall_support.h
Sun Feb 01 19:32:36 2015 +0100
++++
b/toolkit/crashreporter/google-breakpad/src/third_party/lss/linux_syscall_support.h
Thu Feb 05 22:43:17 2015 +0100
+@@ -2814,7 +2814,7 @@
+ LSS_INLINE _syscall6(void*, mmap, void*, s,
+ size_t, l, int, p,
+ int, f, int, d,
+- __off64_t, o)
++ off64_t, o)
+
+ LSS_INLINE _syscall4(int, newfstatat, int, d,
+ const char *, p,
+diff -r 2d344ef8da33 -r df5ec9e5685a
toolkit/crashreporter/nsExceptionHandler.cpp
+--- a/toolkit/crashreporter/nsExceptionHandler.cpp Sun Feb 01 19:32:36
2015 +0100
++++ b/toolkit/crashreporter/nsExceptionHandler.cpp Thu Feb 05 22:43:17
2015 +0100
+@@ -49,6 +49,7 @@
+ #elif defined(XP_LINUX)
+ #include "nsIINIParser.h"
+ #include "common/linux/linux_libc_support.h"
++#undef getdents64
+ #include "third_party/lss/linux_syscall_support.h"
+ #include "client/linux/crash_generation/client_info.h"
+ #include "client/linux/crash_generation/crash_generation_server.h"
diff --git a/www-client/firefox/files/define-gettid-unconditonally-musl.patch
b/www-client/firefox/files/define-gettid-unconditonally-musl.patch
deleted file mode 100644
index 5e42b72..0000000
--- a/www-client/firefox/files/define-gettid-unconditonally-musl.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/mozilla-release/tools/profiler/platform-linux.cc
-+++ b/mozilla-release/tools/profiler/platform-linux.cc
-@@ -84,7 +84,7 @@
-
- #define SIGNAL_SAVE_PROFILE SIGUSR2
-
--#if defined(__GLIBC__)
-+#if defined(OS_LINUX) && !defined(ANDROID)
- // glibc doesn't implement gettid(2).
- #include <sys/syscall.h>
- pid_t gettid()
diff --git a/www-client/firefox/files/dont-include-aouth-musl.patch
b/www-client/firefox/files/dont-include-aouth-musl.patch
deleted file mode 100644
index eae5244..0000000
--- a/www-client/firefox/files/dont-include-aouth-musl.patch
+++ /dev/null
@@ -1,14 +0,0 @@
----
a/mozilla-release/toolkit/crashreporter/google-breakpad/src/common/stabs_reader.h
-+++
b/mozilla-release/toolkit/crashreporter/google-breakpad/src/common/stabs_reader.h
-@@ -53,9 +53,10 @@
- #include <config.h>
- #endif
-
--#ifdef HAVE_A_OUT_H
-+#if 0
- #include <a.out.h>
- #endif
-+
- #ifdef HAVE_MACH_O_NLIST_H
- #include <mach-o/nlist.h>
- #endif
diff --git
a/www-client/firefox/files/dont-include-cdefsh-stagefright-musl.patch
b/www-client/firefox/files/dont-include-cdefsh-stagefright-musl.patch
deleted file mode 100644
index 394820e..0000000
--- a/www-client/firefox/files/dont-include-cdefsh-stagefright-musl.patch
+++ /dev/null
@@ -1,10 +0,0 @@
----
a/mozilla-release/media/libstagefright/system/core/include/cutils/properties.h
-+++
b/mozilla-release/media/libstagefright/system/core/include/cutils/properties.h
-@@ -17,7 +17,6 @@
- #ifndef __CUTILS_PROPERTIES_H
- #define __CUTILS_PROPERTIES_H
-
--#include <sys/cdefs.h>
- #include <stddef.h>
-
- #ifdef __cplusplus
diff --git
a/www-client/firefox/files/firefox-31.0-webm-disallow-negative-samples.patch
b/www-client/firefox/files/firefox-31.0-webm-disallow-negative-samples.patch
deleted file mode 100644
index bccc25e..0000000
--- a/www-client/firefox/files/firefox-31.0-webm-disallow-negative-samples.patch
+++ /dev/null
@@ -1,29 +0,0 @@
---- a/content/media/webm/WebMReader.cpp 2014-10-20 21:59:39.000000000
-0400
-+++ b/content/media/webm/WebMReader.cpp 2014-10-28 09:06:51.959665416
-0400
-@@ -668,7 +668,15 @@
- return true;
- }
- int32_t keepFrames = frames - skipFrames;
-+ if (keepFrames < 0) {
-+ NS_WARNING("Int overflow in keepFrames");
-+ return false;
-+ }
- int samples = keepFrames * channels;
-+ if (samples < 0) {
-+ NS_WARNING("Int overflow in samples");
-+ return false;
-+ }
- nsAutoArrayPtr<AudioDataValue> trimBuffer(new
AudioDataValue[samples]);
- for (int i = 0; i < samples; i++)
- trimBuffer[i] = buffer[skipFrames*channels + i];
-@@ -691,6 +699,10 @@
- int32_t keepFrames = frames - discardFrames.value();
- if (keepFrames > 0) {
- int samples = keepFrames * channels;
-+ if (samples < 0) {
-+ NS_WARNING("Int overflow in samples");
-+ return false;
-+ }
- nsAutoArrayPtr<AudioDataValue> trimBuffer(new
AudioDataValue[samples]);
- for (int i = 0; i < samples; i++)
- trimBuffer[i] = buffer[i];
diff --git a/www-client/firefox/files/firefox-32.0-hppa-js-configure.patch
b/www-client/firefox/files/firefox-32.0-hppa-js-configure.patch
deleted file mode 100644
index c37edda..0000000
--- a/www-client/firefox/files/firefox-32.0-hppa-js-configure.patch
+++ /dev/null
@@ -1,21 +0,0 @@
---- a/mozilla-release/js/src/configure.in
-+++ b/mozilla-release/js/src/configure.in
-@@ -958,7 +958,7 @@
- CPU_ARCH=s390x
- ;;
-
--hppa* | parisc)
-+hppa* | parisc*)
- CPU_ARCH=hppa
- ;;
-
-@@ -2009,6 +2009,9 @@
- AC_DEFINE(JS_CPU_MIPS)
- AC_DEFINE(JS_NUNBOX32)
- ;;
-+hppa*)
-+ AC_DEFINE(JS_NUNBOX32)
-+ ;;
- esac
-
- MOZ_ARG_DISABLE_BOOL(ion,
diff --git a/www-client/firefox/files/firefox-33.0-jemalloc-configure.patch
b/www-client/firefox/files/firefox-33.0-jemalloc-configure.patch
deleted file mode 100644
index 0e6e11e..0000000
--- a/www-client/firefox/files/firefox-33.0-jemalloc-configure.patch
+++ /dev/null
@@ -1,29 +0,0 @@
---- a/memory/jemalloc/src/configure.ac 2014-10-11 05:06:41.000000000 -0400
-+++ b/memory/jemalloc/src/configure.ac 2014-10-16 13:41:10.809799170 -0400
-@@ -887,7 +887,7 @@
- dnl Check whether the BSD/SUSv1 sbrk() exists. If not, disable DSS support.
- AC_CHECK_FUNC([sbrk], [have_sbrk="1"], [have_sbrk="0"])
- if test "x$have_sbrk" = "x1" ; then
-- if test "x$sbrk_deprecated" == "x1" ; then
-+ if test "x$sbrk_deprecated" = "x1" ; then
- AC_MSG_RESULT([Disabling dss allocation because sbrk is deprecated])
- enable_dss="0"
- else
-@@ -1180,7 +1180,7 @@
- printf("%d\n", rv);
- }
- ], [je_cv_gcc_builtin_ffsl])
--if test "x${je_cv_gcc_builtin_ffsl}" == "xyes" ; then
-+if test "x${je_cv_gcc_builtin_ffsl}" = "xyes" ; then
- AC_DEFINE([JEMALLOC_INTERNAL_FFSL], [__builtin_ffsl])
- AC_DEFINE([JEMALLOC_INTERNAL_FFS], [__builtin_ffs])
- else
-@@ -1194,7 +1194,7 @@
- printf("%d\n", rv);
- }
- ], [je_cv_function_ffsl])
-- if test "x${je_cv_function_ffsl}" == "xyes" ; then
-+ if test "x${je_cv_function_ffsl}" = "xyes" ; then
- AC_DEFINE([JEMALLOC_INTERNAL_FFSL], [ffsl])
- AC_DEFINE([JEMALLOC_INTERNAL_FFS], [ffs])
- else
diff --git a/www-client/firefox/files/firefox-35.0-gmp-clearkey-sprintf.patch
b/www-client/firefox/files/firefox-35.0-gmp-clearkey-sprintf.patch
new file mode 100644
index 0000000..dfd9a8d
--- /dev/null
+++ b/www-client/firefox/files/firefox-35.0-gmp-clearkey-sprintf.patch
@@ -0,0 +1,10 @@
+--- a/mozilla-beta/media/gmp-clearkey/0.1/openaes/oaes_lib.c 2014-12-04
11:24:16.279571363 -0500
++++ b/mozilla-beta/media/gmp-clearkey/0.1/openaes/oaes_lib.c 2014-12-04
11:23:07.449572313 -0500
+@@ -42,6 +42,7 @@
+
+ #include "oaes_config.h"
+ #include "oaes_lib.h"
++#include "standard.h"
+
+ #ifdef OAES_HAVE_ISAAC
+ #include "rand.h"
diff --git a/www-client/firefox/files/fix-amd64-build-musl.patch
b/www-client/firefox/files/fix-amd64-build-musl.patch
deleted file mode 100644
index 6482af8..0000000
--- a/www-client/firefox/files/fix-amd64-build-musl.patch
+++ /dev/null
@@ -1,39 +0,0 @@
----
a/mozilla-release/toolkit/crashreporter/google-breakpad/src/third_party/lss/linux_syscall_support.h
-+++
b/mozilla-release/toolkit/crashreporter/google-breakpad/src/third_party/lss/linux_syscall_support.h
-@@ -2814,7 +2814,7 @@
- LSS_INLINE _syscall6(void*, mmap, void*, s,
- size_t, l, int, p,
- int, f, int, d,
-- __off64_t, o)
-+ off64_t, o)
-
- LSS_INLINE _syscall4(int, newfstatat, int, d,
- const char *, p,
---- a/mozilla-release/toolkit/xre/nsSigHandlers.cpp
-+++ b/mozilla-release/toolkit/xre/nsSigHandlers.cpp
-@@ -152,7 +152,7 @@
- status->__invalid = status->__denorm = status->__zdiv = status->__ovrfl =
status->__undfl =
- status->__precis = status->__stkflt = status->__errsumm = 0;
-
-- __uint32_t *mxcsr = &uc->uc_mcontext->__fs.__fpu_mxcsr;
-+ uint32_t *mxcsr = &uc->uc_mcontext->__fs.__fpu_mxcsr;
- *mxcsr |= SSE_EXCEPTION_MASK; /* disable all SSE exceptions */
- *mxcsr &= ~SSE_STATUS_FLAGS; /* clear all pending SSE exceptions */
- #endif
-@@ -172,13 +172,13 @@
- *sw &= ~FPU_STATUS_FLAGS;
- #endif
- #if defined(__amd64__)
-- __uint16_t *cw = &uc->uc_mcontext.fpregs->cwd;
-+ uint16_t *cw = &uc->uc_mcontext.fpregs->cwd;
- *cw |= FPU_EXCEPTION_MASK;
-
-- __uint16_t *sw = &uc->uc_mcontext.fpregs->swd;
-+ uint16_t *sw = &uc->uc_mcontext.fpregs->swd;
- *sw &= ~FPU_STATUS_FLAGS;
-
-- __uint32_t *mxcsr = &uc->uc_mcontext.fpregs->mxcsr;
-+ uint32_t *mxcsr = &uc->uc_mcontext.fpregs->mxcsr;
- *mxcsr |= SSE_EXCEPTION_MASK; /* disable all SSE exceptions */
- *mxcsr &= ~SSE_STATUS_FLAGS; /* clear all pending SSE exceptions */
- #endif
diff --git a/www-client/firefox/files/fix-android-check-musl.patch
b/www-client/firefox/files/fix-android-check-musl.patch
deleted file mode 100644
index e81da0f..0000000
--- a/www-client/firefox/files/fix-android-check-musl.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/mozilla-release/ipc/chromium/src/base/debug_util_posix.cc
-+++ b/mozilla-release/ipc/chromium/src/base/debug_util_posix.cc
-@@ -5,7 +5,7 @@
- #include "build/build_config.h"
- #include "base/debug_util.h"
-
--#define MOZ_HAVE_EXECINFO_H (defined(OS_LINUX) && !defined(ANDROID))
-+#define MOZ_HAVE_EXECINFO_H (defined(OS_LINUX) && defined(__GLIBC__))
-
- #include <errno.h>
- #include <fcntl.h>
diff --git a/www-client/firefox/files/fix-jemalloc-includes-musl.patch
b/www-client/firefox/files/fix-jemalloc-includes-musl.patch
deleted file mode 100644
index 928673a..0000000
--- a/www-client/firefox/files/fix-jemalloc-includes-musl.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/mozilla-release/memory/mozjemalloc/jemalloc.c
-+++ b/mozilla-release/memory/mozjemalloc/jemalloc.c
-@@ -337,7 +337,6 @@
- #include <sys/time.h>
- #include <sys/types.h>
- #if !defined(MOZ_MEMORY_SOLARIS) && !defined(MOZ_MEMORY_ANDROID)
--#include <sys/sysctl.h>
- #endif
- #include <sys/uio.h>
- #ifndef MOZ_MEMORY
diff --git a/www-client/firefox/files/fix-mtransport-includes-musl.patch
b/www-client/firefox/files/fix-mtransport-includes-musl.patch
deleted file mode 100644
index 92dd34f..0000000
--- a/www-client/firefox/files/fix-mtransport-includes-musl.patch
+++ /dev/null
@@ -1,20 +0,0 @@
---- a/mozilla-release/media/mtransport/third_party/nICEr/src/stun/addrs.c
-+++ b/mozilla-release/media/mtransport/third_party/nICEr/src/stun/addrs.c
-@@ -45,7 +45,6 @@
- #include <sys/param.h>
- #include <sys/socket.h>
- #ifndef ANDROID
--#include <sys/sysctl.h>
- #include <sys/syslog.h>
- #else
- #include <syslog.h>
-@@ -63,8 +61,8 @@
- #include <sys/sockio.h>
- #else
- #include <linux/sockios.h>
--#include <linux/if.h>
- #include <linux/kernel.h>
-+#include <linux/if.h>
- #include <linux/wireless.h>
- #ifndef ANDROID
- #include <linux/ethtool.h>
diff --git a/www-client/firefox/files/fts.patch
b/www-client/firefox/files/fts.patch
new file mode 100644
index 0000000..4c1734f
--- /dev/null
+++ b/www-client/firefox/files/fts.patch
@@ -0,0 +1,480 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1428142499 -7200
+# Sat Apr 04 12:14:59 2015 +0200
+# Node ID b85504ff4ee9c548d58e75398a2de69f2089e907
+# Parent 90adc073cbc6398f4fab9b1cd07b685368559f34
+# https://bugzilla.mozilla.org/show_bug.cgi?id=1139173
+ipc/chromium: Remove dead code to make it compile on linux without <fts.h>
+
+diff -r 90adc073cbc6 -r b85504ff4ee9 ipc/chromium/moz.build
+--- a/ipc/chromium/moz.build Thu Apr 02 08:10:00 2015 -0400
++++ b/ipc/chromium/moz.build Sat Apr 04 12:14:59 2015 +0200
+@@ -50,7 +50,6 @@
+ 'src/base/pickle.cc',
+ 'src/base/rand_util.cc',
+ 'src/base/revocable_store.cc',
+- 'src/base/scoped_temp_dir.cc',
+ 'src/base/string_piece.cc',
+ 'src/base/string_util.cc',
+ 'src/base/thread.cc',
+diff -r 90adc073cbc6 -r b85504ff4ee9 ipc/chromium/src/base/file_util.cc
+--- a/ipc/chromium/src/base/file_util.cc Thu Apr 02 08:10:00 2015 -0400
++++ b/ipc/chromium/src/base/file_util.cc Sat Apr 04 12:14:59 2015 +0200
+@@ -139,12 +139,6 @@
+ path->push_back(FilePath::kSeparators[0]);
+ path->append(new_ending);
+ }
+-bool CopyDirectory(const std::wstring& from_path, const std::wstring& to_path,
+- bool recursive) {
+- return CopyDirectory(FilePath::FromWStringHack(from_path),
+- FilePath::FromWStringHack(to_path),
+- recursive);
+-}
+ bool CopyFile(const std::wstring& from_path, const std::wstring& to_path) {
+ return CopyFile(FilePath::FromWStringHack(from_path),
+ FilePath::FromWStringHack(to_path));
+@@ -172,8 +166,8 @@
+ *temp_file = temp_file_path.ToWStringHack();
+ return true;
+ }
+-bool Delete(const std::wstring& path, bool recursive) {
+- return Delete(FilePath::FromWStringHack(path), recursive);
++bool Delete(const std::wstring& path) {
++ return Delete(FilePath::FromWStringHack(path));
+ }
+ bool DirectoryExists(const std::wstring& path) {
+ return DirectoryExists(FilePath::FromWStringHack(path));
+diff -r 90adc073cbc6 -r b85504ff4ee9 ipc/chromium/src/base/file_util.h
+--- a/ipc/chromium/src/base/file_util.h Thu Apr 02 08:10:00 2015 -0400
++++ b/ipc/chromium/src/base/file_util.h Sat Apr 04 12:14:59 2015 +0200
+@@ -16,7 +16,6 @@
+ #include <sys/stat.h>
+ #elif defined(OS_POSIX)
+ #include <sys/types.h>
+-#include <fts.h>
+ #include <sys/stat.h>
+ #endif
+
+@@ -87,34 +86,17 @@
+
+ // Deletes the given path, whether it's a file or a directory.
+ // If it's a directory, it's perfectly happy to delete all of the
+-// directory's contents. Passing true to recursive deletes
+-// subdirectories and their contents as well.
++// directory's contents.
+ // Returns true if successful, false otherwise.
+-//
+-// WARNING: USING THIS WITH recursive==true IS EQUIVALENT
+-// TO "rm -rf", SO USE WITH CAUTION.
+-bool Delete(const FilePath& path, bool recursive);
++bool Delete(const FilePath& path);
+ // Deprecated temporary compatibility function.
+-bool Delete(const std::wstring& path, bool recursive);
++bool Delete(const std::wstring& path);
+
+ // Copies a single file. Use CopyDirectory to copy directories.
+ bool CopyFile(const FilePath& from_path, const FilePath& to_path);
+ // Deprecated temporary compatibility function.
+ bool CopyFile(const std::wstring& from_path, const std::wstring& to_path);
+
+-// Copies the given path, and optionally all subdirectories and their contents
+-// as well.
+-// If there are files existing under to_path, always overwrite.
+-// Returns true if successful, false otherwise.
+-// Dont't use wildcards on the names, it may stop working without notice.
+-//
+-// If you only need to copy a file use CopyFile, it's faster.
+-bool CopyDirectory(const FilePath& from_path, const FilePath& to_path,
+- bool recursive);
+-// Deprecated temporary compatibility function.
+-bool CopyDirectory(const std::wstring& from_path, const std::wstring& to_path,
+- bool recursive);
+-
+ // Returns true if the given path exists on the local filesystem,
+ // false otherwise.
+ bool PathExists(const FilePath& path);
+diff -r 90adc073cbc6 -r b85504ff4ee9 ipc/chromium/src/base/file_util_posix.cc
+--- a/ipc/chromium/src/base/file_util_posix.cc Thu Apr 02 08:10:00 2015 -0400
++++ b/ipc/chromium/src/base/file_util_posix.cc Sat Apr 04 12:14:59 2015 +0200
+@@ -8,13 +8,10 @@
+ #include <errno.h>
+ #include <fcntl.h>
+ #include <fnmatch.h>
+-#ifndef ANDROID
+-#include <fts.h>
+-#endif
+ #include <libgen.h>
+ #include <stdio.h>
+ #include <string.h>
+-#include <sys/errno.h>
++#include <errno.h>
+ #include <sys/mman.h>
+ #define _DARWIN_USE_64_BIT_INODE // Use 64-bit inode data structures
+ #include <sys/stat.h>
+@@ -53,7 +50,7 @@
+ // which works both with and without the recursive flag. I'm not sure we need
+ // that functionality. If not, remove from file_util_win.cc, otherwise add it
+ // here.
+-bool Delete(const FilePath& path, bool recursive) {
++bool Delete(const FilePath& path) {
+ const char* path_str = path.value().c_str();
+ struct stat file_info;
+ int test = stat(path_str, &file_info);
+@@ -64,174 +61,8 @@
+ }
+ if (!S_ISDIR(file_info.st_mode))
+ return (unlink(path_str) == 0);
+- if (!recursive)
+- return (rmdir(path_str) == 0);
+
+-#ifdef ANDROID
+- // XXX Need ftsless impl for bionic
+- return false;
+-#else
+- bool success = true;
+- int ftsflags = FTS_PHYSICAL | FTS_NOSTAT;
+- char top_dir[PATH_MAX];
+- if (base::strlcpy(top_dir, path_str,
+- arraysize(top_dir)) >= arraysize(top_dir)) {
+- return false;
+- }
+- char* dir_list[2] = { top_dir, NULL };
+- FTS* fts = fts_open(dir_list, ftsflags, NULL);
+- if (fts) {
+- FTSENT* fts_ent = fts_read(fts);
+- while (success && fts_ent != NULL) {
+- switch (fts_ent->fts_info) {
+- case FTS_DNR:
+- case FTS_ERR:
+- // log error
+- success = false;
+- continue;
+- break;
+- case FTS_DP:
+- success = (rmdir(fts_ent->fts_accpath) == 0);
+- break;
+- case FTS_D:
+- break;
+- case FTS_NSOK:
+- case FTS_F:
+- case FTS_SL:
+- case FTS_SLNONE:
+- success = (unlink(fts_ent->fts_accpath) == 0);
+- break;
+- default:
+- DCHECK(false);
+- break;
+- }
+- fts_ent = fts_read(fts);
+- }
+- fts_close(fts);
+- }
+- return success;
+-#endif
+-}
+-
+-bool Move(const FilePath& from_path, const FilePath& to_path) {
+- if (rename(from_path.value().c_str(), to_path.value().c_str()) == 0)
+- return true;
+-
+- if (!CopyDirectory(from_path, to_path, true))
+- return false;
+-
+- Delete(from_path, true);
+- return true;
+-}
+-
+-bool CopyDirectory(const FilePath& from_path,
+- const FilePath& to_path,
+- bool recursive) {
+- // Some old callers of CopyDirectory want it to support wildcards.
+- // After some discussion, we decided to fix those callers.
+- // Break loudly here if anyone tries to do this.
+- // TODO(evanm): remove this once we're sure it's ok.
+- DCHECK(to_path.value().find('*') == std::string::npos);
+- DCHECK(from_path.value().find('*') == std::string::npos);
+-
+- char top_dir[PATH_MAX];
+- if (base::strlcpy(top_dir, from_path.value().c_str(),
+- arraysize(top_dir)) >= arraysize(top_dir)) {
+- return false;
+- }
+-
+-#ifdef ANDROID
+- // XXX Need ftsless impl for bionic
+- return false;
+-#else
+- char* dir_list[] = { top_dir, NULL };
+- FTS* fts = fts_open(dir_list, FTS_PHYSICAL | FTS_NOSTAT, NULL);
+- if (!fts) {
+- CHROMIUM_LOG(ERROR) << "fts_open failed: " << strerror(errno);
+- return false;
+- }
+-
+- int error = 0;
+- FTSENT* ent;
+- while (!error && (ent = fts_read(fts)) != NULL) {
+- // ent->fts_path is the source path, including from_path, so paste
+- // the suffix after from_path onto to_path to create the target_path.
+- std::string suffix(&ent->fts_path[from_path.value().size()]);
+- // Strip the leading '/' (if any).
+- if (!suffix.empty()) {
+- DCHECK_EQ('/', suffix[0]);
+- suffix.erase(0, 1);
+- }
+- const FilePath target_path = to_path.Append(suffix);
+- switch (ent->fts_info) {
+- case FTS_D: // Preorder directory.
+- // If we encounter a subdirectory in a non-recursive copy, prune it
+- // from the traversal.
+- if (!recursive && ent->fts_level > 0) {
+- if (fts_set(fts, ent, FTS_SKIP) != 0)
+- error = errno;
+- continue;
+- }
+-
+- // Try creating the target dir, continuing on it if it exists already.
+- // Rely on the user's umask to produce correct permissions.
+- if (mkdir(target_path.value().c_str(), 0777) != 0) {
+- if (errno != EEXIST)
+- error = errno;
+- }
+- break;
+- case FTS_F: // Regular file.
+- case FTS_NSOK: // File, no stat info requested.
+- errno = 0;
+- if (!CopyFile(FilePath(ent->fts_path), target_path))
+- error = errno ? errno : EINVAL;
+- break;
+- case FTS_DP: // Postorder directory.
+- case FTS_DOT: // "." or ".."
+- // Skip it.
+- continue;
+- case FTS_DC: // Directory causing a cycle.
+- // Skip this branch.
+- if (fts_set(fts, ent, FTS_SKIP) != 0)
+- error = errno;
+- break;
+- case FTS_DNR: // Directory cannot be read.
+- case FTS_ERR: // Error.
+- case FTS_NS: // Stat failed.
+- // Abort with the error.
+- error = ent->fts_errno;
+- break;
+- case FTS_SL: // Symlink.
+- case FTS_SLNONE: // Symlink with broken target.
+- CHROMIUM_LOG(WARNING) << "CopyDirectory() skipping symbolic link: " <<
+- ent->fts_path;
+- continue;
+- case FTS_DEFAULT: // Some other sort of file.
+- CHROMIUM_LOG(WARNING) << "CopyDirectory() skipping file of unknown
type: " <<
+- ent->fts_path;
+- continue;
+- default:
+- NOTREACHED();
+- continue; // Hope for the best!
+- }
+- }
+- // fts_read may have returned NULL and set errno to indicate an error.
+- if (!error && errno != 0)
+- error = errno;
+-
+- if (!fts_close(fts)) {
+- // If we already have an error, let's use that error instead of the error
+- // fts_close set.
+- if (!error)
+- error = errno;
+- }
+-
+- if (error) {
+- CHROMIUM_LOG(ERROR) << "CopyDirectory(): " << strerror(error);
+- return false;
+- }
+- return true;
+-#endif
++ return (rmdir(path_str) == 0);
+ }
+
+ bool PathExists(const FilePath& path) {
+diff -r 90adc073cbc6 -r b85504ff4ee9 ipc/chromium/src/base/file_util_win.cc
+--- a/ipc/chromium/src/base/file_util_win.cc Thu Apr 02 08:10:00 2015 -0400
++++ b/ipc/chromium/src/base/file_util_win.cc Sat Apr 04 12:14:59 2015 +0200
+@@ -27,14 +27,14 @@
+ return true;
+ }
+
+-bool Delete(const FilePath& path, bool recursive) {
++bool Delete(const FilePath& path) {
+ if (path.value().length() >= MAX_PATH)
+ return false;
+
+- // If we're not recursing use DeleteFile; it should be faster. DeleteFile
++ // Use DeleteFile; it should be faster. DeleteFile
+ // fails if passed a directory though, which is why we fall through on
+ // failure to the SHFileOperation.
+- if (!recursive && DeleteFile(path.value().c_str()) != 0)
++ if (DeleteFile(path.value().c_str()) != 0)
+ return true;
+
+ // SHFILEOPSTRUCT wants the path to be terminated with two NULLs,
+@@ -48,8 +48,7 @@
+ file_operation.wFunc = FO_DELETE;
+ file_operation.pFrom = double_terminated_path;
+ file_operation.fFlags = FOF_NOERRORUI | FOF_SILENT | FOF_NOCONFIRMATION;
+- if (!recursive)
+- file_operation.fFlags |= FOF_NORECURSION | FOF_FILESONLY;
++ file_operation.fFlags |= FOF_NORECURSION | FOF_FILESONLY;
+ int err = SHFileOperation(&file_operation);
+ // Some versions of Windows return ERROR_FILE_NOT_FOUND when
+ // deleting an empty directory.
+@@ -98,26 +97,6 @@
+ return (SHFileOperation(&file_operation) == 0);
+ }
+
+-bool CopyDirectory(const FilePath& from_path, const FilePath& to_path,
+- bool recursive) {
+- if (recursive)
+- return ShellCopy(from_path, to_path, true);
+-
+- // Instead of creating a new directory, we copy the old one to include the
+- // security information of the folder as part of the copy.
+- if (!PathExists(to_path)) {
+- // Except that Vista fails to do that, and instead do a recursive copy if
+- // the target directory doesn't exist.
+- if (win_util::GetWinVersion() >= win_util::WINVERSION_VISTA)
+- CreateDirectory(to_path);
+- else
+- ShellCopy(from_path, to_path, false);
+- }
+-
+- FilePath directory = from_path.Append(L"*.*");
+- return ShellCopy(directory, to_path, false);
+-}
+-
+ bool PathExists(const FilePath& path) {
+ return (GetFileAttributes(path.value().c_str()) != INVALID_FILE_ATTRIBUTES);
+ }
+diff -r 40f6b9e6448e -r e25335f4fbb2 ipc/chromium/src/base/scoped_temp_dir.cc
+--- a/ipc/chromium/src/base/scoped_temp_dir.cc Tue Mar 03 23:02:07 2015 +0100
++++ /dev/null Thu Jan 01 00:00:00 1970 +0000
+@@ -1,47 +0,0 @@
+-// Copyright (c) 2009 The Chromium Authors. All rights reserved.
+-// Use of this source code is governed by a BSD-style license that can be
+-// found in the LICENSE file.
+-
+-#include "base/scoped_temp_dir.h"
+-
+-#include "base/file_util.h"
+-#include "base/logging.h"
+-#include "base/string_util.h"
+-
+-ScopedTempDir::ScopedTempDir() {
+-}
+-
+-ScopedTempDir::~ScopedTempDir() {
+- if (!path_.empty() && !file_util::Delete(path_, true))
+- CHROMIUM_LOG(ERROR) << "ScopedTempDir unable to delete " << path_.value();
+-}
+-
+-bool ScopedTempDir::CreateUniqueTempDir() {
+- // This "scoped_dir" prefix is only used on Windows and serves as a template
+- // for the unique name.
+- if (!file_util::CreateNewTempDirectory(FILE_PATH_LITERAL("scoped_dir"),
+- &path_))
+- return false;
+-
+- return true;
+-}
+-
+-bool ScopedTempDir::Set(const FilePath& path) {
+- DCHECK(path_.empty());
+- if (!file_util::DirectoryExists(path) &&
+- !file_util::CreateDirectory(path)) {
+- return false;
+- }
+- path_ = path;
+- return true;
+-}
+-
+-FilePath ScopedTempDir::Take() {
+- FilePath ret = path_;
+- path_ = FilePath();
+- return ret;
+-}
+-
+-bool ScopedTempDir::IsValid() const {
+- return !path_.empty() && file_util::DirectoryExists(path_);
+-}
+diff -r 40f6b9e6448e -r e25335f4fbb2 ipc/chromium/src/base/scoped_temp_dir.h
+--- a/ipc/chromium/src/base/scoped_temp_dir.h Tue Mar 03 23:02:07 2015 +0100
++++ /dev/null Thu Jan 01 00:00:00 1970 +0000
+@@ -1,47 +0,0 @@
+-// Copyright (c) 2009 The Chromium Authors. All rights reserved.
+-// Use of this source code is governed by a BSD-style license that can be
+-// found in the LICENSE file.
+-
+-#ifndef BASE_SCOPED_TEMP_DIR_H_
+-#define BASE_SCOPED_TEMP_DIR_H_
+-
+-// An object representing a temporary / scratch directory that should be
cleaned
+-// up (recursively) when this object goes out of scope. Note that since
+-// deletion occurs during the destructor, no further error handling is
possible
+-// if the directory fails to be deleted. As a result, deletion is not
+-// guaranteed by this class.
+-
+-#include "base/file_path.h"
+-
+-class ScopedTempDir {
+- public:
+- // No directory is owned/created initially.
+- ScopedTempDir();
+-
+- // Recursively delete path_
+- ~ScopedTempDir();
+-
+- // Creates a unique directory in TempPath, and takes ownership of it.
+- // See file_util::CreateNewTemporaryDirectory.
+- bool CreateUniqueTempDir();
+-
+- // Takes ownership of directory at |path|, creating it if necessary.
+- // Don't call multiple times unless Take() has been called first.
+- bool Set(const FilePath& path);
+-
+- // Caller takes ownership of the temporary directory so it won't be
destroyed
+- // when this object goes out of scope.
+- FilePath Take();
+-
+- const FilePath& path() const { return path_; }
+-
+- // Returns true if path_ is non-empty and exists.
+- bool IsValid() const;
+-
+- private:
+- FilePath path_;
+-
+- DISALLOW_COPY_AND_ASSIGN(ScopedTempDir);
+-};
+-
+-#endif // BASE_SCOPED_TEMP_DIR_H_
+diff -r 90adc073cbc6 -r b85504ff4ee9
ipc/chromium/src/base/shared_memory_posix.cc
+--- a/ipc/chromium/src/base/shared_memory_posix.cc Thu Apr 02 08:10:00
2015 -0400
++++ b/ipc/chromium/src/base/shared_memory_posix.cc Sat Apr 04 12:14:59
2015 +0200
+@@ -93,7 +93,7 @@
+
+ FilePath path(WideToUTF8(mem_filename));
+ if (file_util::PathExists(path)) {
+- return file_util::Delete(path, false);
++ return file_util::Delete(path);
+ }
+
+ // Doesn't exist, so success.
+@@ -170,7 +170,7 @@
+ // Deleting the file prevents anyone else from mapping it in
+ // (making it private), and prevents the need for cleanup (once
+ // the last fd is closed, it is truly freed).
+- file_util::Delete(path, false);
++ file_util::Delete(path);
+ } else {
+ std::wstring mem_filename;
+ if (FilenameForMemoryName(name, &mem_filename) == false)
diff --git a/www-client/firefox/files/include-systypesh-musl.patch
b/www-client/firefox/files/include-systypesh-musl.patch
deleted file mode 100644
index 601b0c3..0000000
--- a/www-client/firefox/files/include-systypesh-musl.patch
+++ /dev/null
@@ -1,21 +0,0 @@
---- a/mozilla-release/tools/profiler/local_debug_info_symbolizer.cc
-+++ b/mozilla-release/tools/profiler/local_debug_info_symbolizer.cc
-@@ -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 <sys/types.h>
- #include "PlatformMacros.h"
- #include "nsAutoPtr.h"
-
---- a/mozilla-release/tools/profiler/platform.h
-+++ b/mozilla-release/tools/profiler/platform.h
-@@ -29,6 +29,8 @@
- #ifndef TOOLS_PLATFORM_H_
- #define TOOLS_PLATFORM_H_
-
-+#include <sys/types.h>
-+
- #ifdef ANDROID
- #include <android/log.h>
- #else
diff --git a/www-client/firefox/files/libstagefright-cdefs.patch
b/www-client/firefox/files/libstagefright-cdefs.patch
new file mode 100644
index 0000000..b45f97f
--- /dev/null
+++ b/www-client/firefox/files/libstagefright-cdefs.patch
@@ -0,0 +1,21 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1423171584 -3600
+# Thu Feb 05 22:26:24 2015 +0100
+# Node ID 48a43c9da31a3ae083edd563be50fb04d9a5b99a
+# Parent 2d344ef8da33717224d5a08570dc834ca2254f9f
+# https://bugzilla.mozilla.org/show_bug.cgi?id=1151202
+libstagefright: Fix compilation for systems without <sys/cdefs.h>
+
+diff -r 2d344ef8da33 -r 48a43c9da31a
media/libstagefright/system/core/include/cutils/properties.h
+--- a/media/libstagefright/system/core/include/cutils/properties.h Sun Feb
01 19:32:36 2015 +0100
++++ b/media/libstagefright/system/core/include/cutils/properties.h Thu Feb
05 22:26:24 2015 +0100
+@@ -17,7 +17,7 @@
+ #ifndef __CUTILS_PROPERTIES_H
+ #define __CUTILS_PROPERTIES_H
+
+-#include <sys/cdefs.h>
++#include <sys/types.h>
+ #include <stddef.h>
+
+ #ifdef __cplusplus
diff --git a/www-client/firefox/files/make-handleInt-unsigned-long-musl.patch
b/www-client/firefox/files/make-handleInt-unsigned-long-musl.patch
deleted file mode 100644
index 7b9743a..0000000
--- a/www-client/firefox/files/make-handleInt-unsigned-long-musl.patch
+++ /dev/null
@@ -1,11 +0,0 @@
----
a/mozilla-release/media/webrtc/signaling/src/sipcc/cpr/include/cpr_threads.h
-+++
b/mozilla-release/media/webrtc/signaling/src/sipcc/cpr/include/cpr_threads.h
-@@ -30,7 +30,7 @@
- uint32_t threadId;
- union {
- void *handlePtr;
-- uint64_t handleInt;
-+ unsigned long handleInt;
- } u;
- } cpr_thread_t;
-
diff --git a/www-client/firefox/files/profiler-gettid.patch
b/www-client/firefox/files/profiler-gettid.patch
new file mode 100644
index 0000000..d9983b4
--- /dev/null
+++ b/www-client/firefox/files/profiler-gettid.patch
@@ -0,0 +1,51 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1423173146 -3600
+# Thu Feb 05 22:52:26 2015 +0100
+# Node ID c084550fcab646d911bbf4f05747f228759161e4
+# Parent 2d344ef8da33717224d5a08570dc834ca2254f9f
+profiler: avoid getcontext and gettid
+
+diff -r 2d344ef8da33 -r c084550fcab6 tools/profiler/GeckoTaskTracer.cpp
+--- a/tools/profiler/GeckoTaskTracer.cpp Sun Feb 01 19:32:36 2015 +0100
++++ b/tools/profiler/GeckoTaskTracer.cpp Thu Feb 05 22:52:26 2015 +0100
+@@ -18,8 +18,8 @@
+
+ #include <stdarg.h>
+
+-#if defined(__GLIBC__)
+-// glibc doesn't implement gettid(2).
++#if defined(OS_LINUX) && !defined(ANDROID)
++// only bionic wraps gettid(2).
+ #include <sys/syscall.h>
+ static pid_t gettid()
+ {
+diff -r 2d344ef8da33 -r c084550fcab6 tools/profiler/platform-linux.cc
+--- a/tools/profiler/platform-linux.cc Sun Feb 01 19:32:36 2015 +0100
++++ b/tools/profiler/platform-linux.cc Thu Feb 05 22:52:26 2015 +0100
+@@ -92,8 +92,8 @@
+
+ #define SIGNAL_SAVE_PROFILE SIGUSR2
+
+-#if defined(__GLIBC__)
+-// glibc doesn't implement gettid(2).
++#if !defined(ANDROID)
++// only android wraps gettid(2).
+ #include <sys/syscall.h>
+ pid_t gettid()
+ {
+@@ -652,10 +652,10 @@
+ {
+ MOZ_ASSERT(aContext);
+ ucontext_t* pContext = reinterpret_cast<ucontext_t*>(aContext);
+- if (!getcontext(pContext)) {
+- context = pContext;
+- SetSampleContext(this, aContext);
+- }
++// if (!getcontext(pContext)) {
++// context = pContext;
++// SetSampleContext(this, aContext);
++// }
+ }
+
+ void OS::SleepMicro(int microseconds)
diff --git a/www-client/firefox/files/sandbox-cdefs.patch
b/www-client/firefox/files/sandbox-cdefs.patch
new file mode 100644
index 0000000..9591a29
--- /dev/null
+++ b/www-client/firefox/files/sandbox-cdefs.patch
@@ -0,0 +1,21 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1423172498 -3600
+# Thu Feb 05 22:41:38 2015 +0100
+# Node ID 375c73854f92701f13403b8461b35727dccde825
+# Parent 2d344ef8da33717224d5a08570dc834ca2254f9f
+# https://codereview.chromium.org/278583005
+chromium sandbox: Avoid cdefs.h
+
+diff -r 2d344ef8da33 -r 375c73854f92
security/sandbox/chromium/sandbox/linux/seccomp-bpf/linux_seccomp.h
+--- a/security/sandbox/chromium/sandbox/linux/seccomp-bpf/linux_seccomp.h
Sun Feb 01 19:32:36 2015 +0100
++++ b/security/sandbox/chromium/sandbox/linux/seccomp-bpf/linux_seccomp.h
Thu Feb 05 22:41:38 2015 +0100
+@@ -16,7 +16,7 @@
+ #include <asm/unistd.h>
+ #include <linux/filter.h>
+
+-#include <sys/cdefs.h>
++#include <sys/types.h>
+ // Old Bionic versions do not have sys/user.h. The if can be removed once we
no
+ // longer need to support these old Bionic versions.
+ // All x86_64 builds use a new enough bionic to have sys/user.h.
diff --git a/www-client/firefox/files/fix-sctp-includes-musl.patch
b/www-client/firefox/files/sctp-36.patch
similarity index 56%
rename from www-client/firefox/files/fix-sctp-includes-musl.patch
rename to www-client/firefox/files/sctp-36.patch
index a659e40..77a18a8 100644
--- a/www-client/firefox/files/fix-sctp-includes-musl.patch
+++ b/www-client/firefox/files/sctp-36.patch
@@ -1,7 +1,10 @@
---- a/mozilla-release/netwerk/sctp/src/netinet/sctp_os_userspace.h
-+++ b/mozilla-release/netwerk/sctp/src/netinet/sctp_os_userspace.h
-@@ -400,9 +400,11 @@
- #define if_nametoindex(x) win_if_nametoindex(x)
+https://bugzilla.mozilla.org/show_bug.cgi?id=1146096
+
+diff -r e965a1a534ec -r 4ca8a9e27180
netwerk/sctp/src/netinet/sctp_os_userspace.h
+--- a/netwerk/sctp/src/netinet/sctp_os_userspace.h Tue Mar 17 14:22:40
2015 -0400
++++ b/netwerk/sctp/src/netinet/sctp_os_userspace.h Tue Mar 17 22:17:01
2015 +0100
+@@ -273,9 +273,11 @@
+ #endif
#else /* !defined(Userspace_os_Windows) */
+#ifdef __FreeBSD__
@@ -13,7 +16,7 @@
#include <pthread.h>
#endif
typedef pthread_mutex_t userland_mutex_t;
-@@ -427,7 +427,7 @@
+@@ -437,7 +439,7 @@
/* #include <sys/param.h> in FreeBSD defines MSIZE */
/* #include <sys/ktr.h> */
/* #include <sys/systm.h> */
@@ -22,8 +25,9 @@
#include <user_queue.h>
#else
#include <sys/queue.h>
---- a/mozilla-release/netwerk/sctp/src/netinet/sctp_pcb.c
-+++ b/mozilla-release/netwerk/sctp/src/netinet/sctp_pcb.c
+diff -r e965a1a534ec -r 4ca8a9e27180 netwerk/sctp/src/netinet/sctp_pcb.c
+--- a/netwerk/sctp/src/netinet/sctp_pcb.c Tue Mar 17 14:22:40 2015 -0400
++++ b/netwerk/sctp/src/netinet/sctp_pcb.c Tue Mar 17 22:17:01 2015 +0100
@@ -30,6 +30,9 @@
* THE POSSIBILITY OF SUCH DAMAGE.
*/
@@ -33,9 +37,10 @@
+
#ifdef __FreeBSD__
#include <sys/cdefs.h>
- __FBSDID("$FreeBSD: head/sys/netinet/sctp_pcb.c 258765 2013-11-30 12:51:19Z
tuexen $");
---- a/mozilla-release/netwerk/sctp/src/user_queue.h
-+++ b/mozilla-release/netwerk/sctp/src/user_queue.h
+ __FBSDID("$FreeBSD: head/sys/netinet/sctp_pcb.c 277031 2015-01-11 21:55:30Z
tuexen $");
+diff -r e965a1a534ec -r 4ca8a9e27180 netwerk/sctp/src/user_queue.h
+--- a/netwerk/sctp/src/user_queue.h Tue Mar 17 14:22:40 2015 -0400
++++ b/netwerk/sctp/src/user_queue.h Tue Mar 17 22:17:01 2015 +0100
@@ -31,7 +31,7 @@
#ifndef _USER_QUEUE_H_
#define _USER_QUEUE_H_
diff --git a/www-client/firefox/files/sctp.patch
b/www-client/firefox/files/sctp.patch
new file mode 100644
index 0000000..5155c85
--- /dev/null
+++ b/www-client/firefox/files/sctp.patch
@@ -0,0 +1,58 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1426627021 -3600
+# Tue Mar 17 22:17:01 2015 +0100
+# Node ID 4ca8a9e2718089a1d220d1d420ebe583be4be9e5
+# Parent e965a1a534ecb6635975fae33a929dc6c06bcb50
+# https://bugzilla.mozilla.org/show_bug.cgi?id=1146096
+
+diff -r e965a1a534ec -r 4ca8a9e27180
netwerk/sctp/src/netinet/sctp_os_userspace.h
+--- a/netwerk/sctp/src/netinet/sctp_os_userspace.h Tue Mar 17 14:22:40
2015 -0400
++++ b/netwerk/sctp/src/netinet/sctp_os_userspace.h Tue Mar 17 22:17:01
2015 +0100
+@@ -273,9 +273,11 @@
+ #endif
+
+ #else /* !defined(Userspace_os_Windows) */
++#ifdef __FreeBSD__
+ #include <sys/cdefs.h> /* needed? added from old __FreeBSD__ */
++#endif /* __FreeBSD__ */
+ #include <sys/socket.h>
+-#if defined(__Userspace_os_DragonFly) || defined(__Userspace_os_FreeBSD) ||
defined(__Userspace_os_Linux) || defined(__Userspace_os_NetBSD) ||
defined(__Userspace_os_OpenBSD) || defined(__Userspace_os_NaCl)
++#if !defined(__Userspace_os_Windows) && !defined(__Userspace_os_Darwin)
+ #include <pthread.h>
+ #endif
+ typedef pthread_mutex_t userland_mutex_t;
+@@ -437,7 +439,7 @@
+ /* #include <sys/param.h> in FreeBSD defines MSIZE */
+ /* #include <sys/ktr.h> */
+ /* #include <sys/systm.h> */
+-#if defined(__Userspace_os_Windows)
++#if 1
+ #include <user_queue.h>
+ #else
+ #include <sys/queue.h>
+diff -r e965a1a534ec -r 4ca8a9e27180 netwerk/sctp/src/netinet/sctp_pcb.c
+--- a/netwerk/sctp/src/netinet/sctp_pcb.c Tue Mar 17 14:22:40 2015 -0400
++++ b/netwerk/sctp/src/netinet/sctp_pcb.c Tue Mar 17 22:17:01 2015 +0100
+@@ -30,6 +30,9 @@
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
++#define _BSD_SOURCE /* for IPPORT_RESERVED */
++#include <netdb.h>
++
+ #ifdef __FreeBSD__
+ #include <sys/cdefs.h>
+ __FBSDID("$FreeBSD: head/sys/netinet/sctp_pcb.c 277031 2015-01-11 21:55:30Z
tuexen $");
+diff -r e965a1a534ec -r 4ca8a9e27180 netwerk/sctp/src/user_queue.h
+--- a/netwerk/sctp/src/user_queue.h Tue Mar 17 14:22:40 2015 -0400
++++ b/netwerk/sctp/src/user_queue.h Tue Mar 17 22:17:01 2015 +0100
+@@ -31,7 +31,7 @@
+ #ifndef _USER_QUEUE_H_
+ #define _USER_QUEUE_H_
+
+-#if !defined (__Userspace_os_Windows)
++#if defined(__Userspace_os_FreeBSD)
+ #include <sys/cdefs.h>
+ #endif
+ /*
diff --git a/www-client/firefox/files/sipcc.patch
b/www-client/firefox/files/sipcc.patch
new file mode 100644
index 0000000..060fdf9
--- /dev/null
+++ b/www-client/firefox/files/sipcc.patch
@@ -0,0 +1,159 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1423304332 -3600
+# Sat Feb 07 11:18:52 2015 +0100
+# Node ID fbbc5e616bd05c0f3b29ede3d777609e04dce620
+# Parent 204cb68867f5b09f0949bd4a49a4a8c1aaf0f467
+# https://bugzilla.mozilla.org/show_bug.cgi?id=1130709
+sipcc: Make __BEGIN_DECLS and __END_DECLS explicit
+
+diff -r 204cb68867f5 -r fbbc5e616bd0
media/webrtc/signaling/src/sdp/sipcc/cpr_darwin_types.h
+--- a/media/webrtc/signaling/src/sdp/sipcc/cpr_darwin_types.h Sat Feb 07
09:22:26 2015 +0100
++++ b/media/webrtc/signaling/src/sdp/sipcc/cpr_darwin_types.h Sat Feb 07
11:18:52 2015 +0100
+@@ -54,27 +54,6 @@
+ #endif
+
+ /**
+- * __BEGIN_DECLS and __END_DECLS
+- *
+- * Define macros for compilation by C++ compiler
+- */
+-#ifndef __BEGIN_DECLS
+-#ifdef __cplusplus
+-#define __BEGIN_DECLS extern "C" {
+-#else
+-#define __BEGIN_DECLS
+-#endif
+-#endif
+-
+-#ifndef __END_DECLS
+-#ifdef __cplusplus
+-#define __END_DECLS }
+-#else
+-#define __END_DECLS
+-#endif
+-#endif
+-
+-/**
+ * Define TRUE/FALSE
+ * defined in several header files
+ */
+diff -r 204cb68867f5 -r fbbc5e616bd0
media/webrtc/signaling/src/sdp/sipcc/cpr_linux_types.h
+--- a/media/webrtc/signaling/src/sdp/sipcc/cpr_linux_types.h Sat Feb 07
09:22:26 2015 +0100
++++ b/media/webrtc/signaling/src/sdp/sipcc/cpr_linux_types.h Sat Feb 07
11:18:52 2015 +0100
+@@ -62,28 +62,6 @@
+ #endif
+ #endif
+
+-
+-
+-/**
+- * __BEGIN_DECLS and __END_DECLS
+- *
+- * Define macros for compilation by C++ compiler
+- */
+-#ifndef __BEGIN_DECLS
+-#ifdef __cplusplus
+-#define __BEGIN_DECLS extern "C" {
+-#else
+-#define __BEGIN_DECLS
+-#endif
+-#endif
+-
+-#ifndef __END_DECLS
+-#ifdef __cplusplus
+-#define __END_DECLS }
+-#else
+-#define __END_DECLS
+-#endif
+-#endif
+ /**
+ * Define TRUE/FALSE
+ * defined in several header files
+diff -r 204cb68867f5 -r fbbc5e616bd0
media/webrtc/signaling/src/sdp/sipcc/cpr_string.h
+--- a/media/webrtc/signaling/src/sdp/sipcc/cpr_string.h Sat Feb 07
09:22:26 2015 +0100
++++ b/media/webrtc/signaling/src/sdp/sipcc/cpr_string.h Sat Feb 07
11:18:52 2015 +0100
+@@ -10,7 +10,9 @@
+ #include "cpr_types.h"
+ #include "cpr_strings.h"
+
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+
+ /**
+ * sstrncpy
+@@ -130,6 +132,8 @@
+ char *
+ cpr_strdup(const char *str);
+
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+
+ #endif
+diff -r 204cb68867f5 -r fbbc5e616bd0
media/webrtc/signaling/src/sdp/sipcc/cpr_strings.h
+--- a/media/webrtc/signaling/src/sdp/sipcc/cpr_strings.h Sat Feb 07
09:22:26 2015 +0100
++++ b/media/webrtc/signaling/src/sdp/sipcc/cpr_strings.h Sat Feb 07
11:18:52 2015 +0100
+@@ -7,8 +7,6 @@
+
+ #include "cpr_types.h"
+
+-__BEGIN_DECLS
+-
+
+ #include <string.h>
+
+@@ -25,6 +23,4 @@
+
+ #endif // _MSC_VER
+
+-__END_DECLS
+-
+ #endif
+diff -r 204cb68867f5 -r fbbc5e616bd0
media/webrtc/signaling/src/sdp/sipcc/cpr_types.h
+--- a/media/webrtc/signaling/src/sdp/sipcc/cpr_types.h Sat Feb 07 09:22:26
2015 +0100
++++ b/media/webrtc/signaling/src/sdp/sipcc/cpr_types.h Sat Feb 07 11:18:52
2015 +0100
+@@ -13,7 +13,9 @@
+ #include "cpr_darwin_types.h"
+ #endif
+
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+
+ /*
+ * CPR Return Codes
+@@ -114,6 +116,8 @@
+
+ typedef const char *string_t;
+
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+
+ #endif
+diff -r 204cb68867f5 -r fbbc5e616bd0
media/webrtc/signaling/src/sdp/sipcc/cpr_win_types.h
+--- a/media/webrtc/signaling/src/sdp/sipcc/cpr_win_types.h Sat Feb 07
09:22:26 2015 +0100
++++ b/media/webrtc/signaling/src/sdp/sipcc/cpr_win_types.h Sat Feb 07
11:18:52 2015 +0100
+@@ -100,16 +100,5 @@
+ */
+ /* DONE defined in windef.h */
+
+-/*
+- * Define __BEGIN_DECLS and __END_DECLS
+- */
+-#ifdef __cplusplus
+-#define __BEGIN_DECLS extern "C" {
+-#define __END_DECLS }
+-#else
+-#define __BEGIN_DECLS
+-#define __END_DECLS
+-#endif
+-
+ #endif // _CPR_WIN_TYPES_H_
+
diff --git a/www-client/firefox/files/stab.h b/www-client/firefox/files/stab.h
deleted file mode 100644
index 6207982..0000000
--- a/www-client/firefox/files/stab.h
+++ /dev/null
@@ -1,72 +0,0 @@
-/* $OpenBSD: stab.h,v 1.3 2003/06/02 19:34:12 millert Exp $ */
-/* $NetBSD: stab.h,v 1.4 1994/10/26 00:56:25 cgd Exp $ */
-
-/*-
- * Copyright (c) 1991 The Regents of the University of California.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- * 3. Neither the name of the University nor the names of its contributors
- * may be used to endorse or promote products derived from this software
- * without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- * @(#)stab.h 5.2 (Berkeley) 4/4/91
- */
-
-#ifndef _STAB_H_
-#define _STAB_H_
-
-/*
- * The following are symbols used by various debuggers and by the Pascal
- * compiler. Each of them must have one (or more) of the bits defined by
- * the N_STAB mask set.
- */
-
-#define N_UNDF 0x00
-#define N_GSYM 0x20 /* global symbol */
-#define N_FNAME 0x22 /* F77 function name */
-#define N_FUN 0x24 /* procedure name */
-#define N_STSYM 0x26 /* data segment variable */
-#define N_LCSYM 0x28 /* bss segment variable */
-#define N_MAIN 0x2a /* main function name */
-#define N_PC 0x30 /* global Pascal symbol */
-#define N_RSYM 0x40 /* register variable */
-#define N_SLINE 0x44 /* text segment line number */
-#define N_DSLINE 0x46 /* data segment line number */
-#define N_BSLINE 0x48 /* bss segment line number */
-#define N_SSYM 0x60 /* structure/union element */
-#define N_SO 0x64 /* main source file name */
-#define N_LSYM 0x80 /* stack variable */
-#define N_BINCL 0x82 /* include file beginning */
-#define N_SOL 0x84 /* included source file name */
-#define N_PSYM 0xa0 /* parameter variable */
-#define N_EINCL 0xa2 /* include file end */
-#define N_ENTRY 0xa4 /* alternate entry point */
-#define N_LBRAC 0xc0 /* left bracket */
-#define N_EXCL 0xc2 /* deleted include file */
-#define N_RBRAC 0xe0 /* right bracket */
-#define N_BCOMM 0xe2 /* begin common */
-#define N_ECOMM 0xe4 /* end common */
-#define N_ECOML 0xe8 /* end common (local name) */
-#define N_LENG 0xfe /* length of preceding entry */
-
-#endif /* !_STAB_H_ */
diff --git a/www-client/firefox/files/updater.patch
b/www-client/firefox/files/updater.patch
new file mode 100644
index 0000000..e6852a3
--- /dev/null
+++ b/www-client/firefox/files/updater.patch
@@ -0,0 +1,42 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1428142217 -7200
+# Sat Apr 04 12:10:17 2015 +0200
+# Node ID c04cc88f3bb26e254356df6de06583a542ae6796
+# Parent 90adc073cbc6398f4fab9b1cd07b685368559f34
+updater: no fts.h and MAXNAMLEN
+
+diff -r 90adc073cbc6 -r c04cc88f3bb2
toolkit/mozapps/update/common/updatedefines.h
+--- a/toolkit/mozapps/update/common/updatedefines.h Thu Apr 02 08:10:00
2015 -0400
++++ b/toolkit/mozapps/update/common/updatedefines.h Sat Apr 04 12:10:17
2015 +0200
+@@ -109,7 +109,7 @@
+ # include <sys/wait.h>
+ # include <unistd.h>
+
+-#ifdef SOLARIS
++#if 1
+ # include <sys/stat.h>
+ #else
+ # include <fts.h>
+diff -r 90adc073cbc6 -r c04cc88f3bb2 toolkit/mozapps/update/updater/updater.cpp
+--- a/toolkit/mozapps/update/updater/updater.cpp Thu Apr 02 08:10:00
2015 -0400
++++ b/toolkit/mozapps/update/updater/updater.cpp Sat Apr 04 12:10:17
2015 +0200
+@@ -3338,7 +3338,8 @@
+ return rv;
+ }
+
+-#elif defined(SOLARIS)
++#elif 1
++//#defined(SOLARIS)
+ int add_dir_entries(const NS_tchar *dirpath, ActionList *list)
+ {
+ int rv = OK;
+@@ -3346,7 +3347,7 @@
+ NS_tchar foundpath[MAXPATHLEN];
+ struct {
+ dirent dent_buffer;
+- char chars[MAXNAMLEN];
++ char chars[NAME_MAX];
+ } ent_buf;
+ struct dirent* ent;
+
diff --git a/www-client/firefox/files/xpcom-blocksize.patch
b/www-client/firefox/files/xpcom-blocksize.patch
new file mode 100644
index 0000000..9e25ba9
--- /dev/null
+++ b/www-client/firefox/files/xpcom-blocksize.patch
@@ -0,0 +1,22 @@
+# HG changeset patch
+# User Felix Janda <[email protected]>
+# Date 1424989496 -3600
+# Thu Feb 26 23:24:56 2015 +0100
+# Node ID 6980ec675819ae01048026a1be510c64e069ffe3
+# Parent 490274146476bc459cc1a9ed9e0d3771a4fe7d57
+xpcom: Use dbtob instead of BLOCK_SIZE
+
+diff -r 490274146476 -r 6980ec675819 xpcom/io/nsLocalFileUnix.cpp
+--- a/xpcom/io/nsLocalFileUnix.cpp Thu Feb 26 22:58:09 2015 +0100
++++ b/xpcom/io/nsLocalFileUnix.cpp Thu Feb 26 23:24:56 2015 +0100
+@@ -1408,8 +1408,8 @@
+ && dq.dqb_bhardlimit) {
+ int64_t QuotaSpaceAvailable = 0;
+ // dqb_bhardlimit is count of BLOCK_SIZE blocks, dqb_curspace is bytes
+- if ((BLOCK_SIZE * dq.dqb_bhardlimit) > dq.dqb_curspace)
+- QuotaSpaceAvailable = int64_t(BLOCK_SIZE * dq.dqb_bhardlimit -
dq.dqb_curspace);
++ if (dbtob(dq.dqb_bhardlimit) > dq.dqb_curspace)
++ QuotaSpaceAvailable = (dbtob(dq.dqb_bhardlimit) - dq.dqb_curspace);
+ if (QuotaSpaceAvailable < *aDiskSpaceAvailable) {
+ *aDiskSpaceAvailable = QuotaSpaceAvailable;
+ }
diff --git a/www-client/firefox/firefox-34.0.5-r99.ebuild
b/www-client/firefox/firefox-37.0.1-r99.ebuild
similarity index 77%
rename from www-client/firefox/firefox-34.0.5-r99.ebuild
rename to www-client/firefox/firefox-37.0.1-r99.ebuild
index 9ed5ca2..cafee6c 100644
--- a/www-client/firefox/firefox-34.0.5-r99.ebuild
+++ b/www-client/firefox/firefox-37.0.1-r99.ebuild
@@ -1,6 +1,6 @@
-# Copyright 1999-2014 Gentoo Foundation
+# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header:
/var/cvsroot/gentoo-x86/www-client/firefox/firefox-34.0.5-r1.ebuild,v 1.2
2014/12/05 23:06:43 axs Exp $
+# $Header: /var/cvsroot/gentoo-x86/www-client/firefox/firefox-37.0.1.ebuild,v
1.1 2015/04/05 23:07:55 polynomial-c Exp $
EAPI="5"
VIRTUALX_REQUIRED="pgo"
@@ -8,7 +8,9 @@ WANT_AUTOCONF="2.1"
MOZ_ESR=""
# This list can be updated with scripts/get_langs.sh from the mozilla overlay
-MOZ_LANGS=( af ar as ast be bg bn-BD bn-IN br bs ca cs csb cy da de el en
+# No official support as of fetch time
+# csb
+MOZ_LANGS=( af ar as ast be bg bn-BD bn-IN br bs ca cs cy da de el en
en-GB en-US en-ZA eo es-AR es-CL es-ES es-MX et eu fa fi fr fy-NL ga-IE gd
gl gu-IN he hi-IN hr hu hy-AM id is it ja kk km kn ko lt lv mai mk ml mr
nb-NO nl nn-NO or pa-IN pl pt-BR pt-PT rm ro ru si sk sl son sq sr sv-SE ta te
@@ -25,35 +27,38 @@ if [[ ${MOZ_ESR} == 1 ]]; then
fi
# Patch version
-PATCH="${PN}-34.0-patches-0.1"
+PATCH="${PN}-36.0-patches-01"
# Upstream ftp release URI that's used by mozlinguas.eclass
# We don't use the http mirror because it deletes old tarballs.
-MOZ_FTP_URI="ftp://ftp.mozilla.org/pub/${PN}/releases/"
-MOZ_HTTP_URI="http://ftp.mozilla.org/pub/${PN}/releases/"
+MOZ_FTP_URI="ftp://ftp.mozilla.org/pub/${PN}/releases"
+MOZ_HTTP_URI="http://ftp.mozilla.org/pub/${PN}/releases"
MOZCONFIG_OPTIONAL_WIFI=1
MOZCONFIG_OPTIONAL_JIT="enabled"
-inherit check-reqs flag-o-matic toolchain-funcs eutils gnome2-utils
mozconfig-v5.34 multilib pax-utils fdo-mime autotools virtualx mozlinguas
+inherit check-reqs flag-o-matic toolchain-funcs eutils gnome2-utils
mozconfig-v5.36 multilib pax-utils fdo-mime autotools virtualx mozlinguas
DESCRIPTION="Firefox Web Browser"
HOMEPAGE="http://www.mozilla.com/firefox"
-KEYWORDS="~amd64 ~arm ~mips ~ppc ~x86"
+KEYWORDS="~amd64 ~arm ~ppc ~x86"
+
SLOT="0"
LICENSE="MPL-2.0 GPL-2 LGPL-2.1"
IUSE="bindist hardened +minimal pgo selinux +gmp-autoupdate test"
+RESTRICT="!bindist? ( bindist )"
# More URIs appended below...
SRC_URI="${SRC_URI}
http://dev.gentoo.org/~anarchy/mozilla/patchsets/${PATCH}.tar.xz
- http://dev.gentoo.org/~axs/distfiles/${PATCH}.tar.xz"
+ http://dev.gentoo.org/~axs/distfiles/${PATCH}.tar.xz
+ http://dev.gentoo.org/~polynomial-c/mozilla/patchsets/${PATCH}.tar.xz"
ASM_DEPEND=">=dev-lang/yasm-1.1"
# Mesa 7.10 needed for WebGL + bugfixes
RDEPEND="
- >=dev-libs/nss-3.17.2
+ >=dev-libs/nss-3.17.4
>=dev-libs/nspr-4.10.7
selinux? ( sec-policy/selinux-mozilla )"
@@ -126,13 +131,6 @@ pkg_pretend() {
CHECKREQS_DISK_BUILD="4G"
fi
check-reqs_pkg_setup
-
- if use jit && [[ -n ${PROFILE_IS_HARDENED} ]]; then
- ewarn "You are emerging this package on a hardened profile with
USE=jit enabled."
- ewarn "This is horribly insecure as it disables all PAGEEXEC
restrictions."
- ewarn "Please ensure you know what you are doing. If you
don't, please consider"
- ewarn "emerging the package with USE=-jit"
- fi
}
src_unpack() {
@@ -144,55 +142,41 @@ src_unpack() {
src_prepare() {
# Apply our patches
+ EPATCH_EXCLUDE="8002_jemalloc_configure_unbashify.patch" \
EPATCH_SUFFIX="patch" \
EPATCH_FORCE="yes" \
epatch "${WORKDIR}/firefox"
- # Avoid using basename
https://bugzilla.mozilla.org/show_bug.cgi?id=1041962
- epatch "${FILESDIR}"/avoid-basename-musl.patch
- # <fts.h> unavailable on Android and musl, portions from
- # http://git.alpinelinux.org/cgit/aports/tree/main/firefox/fix-ipc.patch
- epatch "${FILESDIR}"/avoid-fts-on-nonglibc-musl.patch
- # getcontext() unavailable on musl, safe to omit
- epatch "${FILESDIR}"/avoid-getcontext-musl.patch
- # the glibc check should be non-Android Linux
- epatch "${FILESDIR}"/define-gettid-unconditonally-musl.patch
- # <a.out.h> unavailable on musl, yet somehow the build system still
defines
- # HAVE_A_OUT_H - unconditionally disable for now, better to fix
configure.
- # Portions from
- #
http://git.alpinelinux.org/cgit/aports/tree/main/firefox/fix-toolkit.patch
- epatch "${FILESDIR}"/dont-include-aouth-musl.patch
- # non-Android Linux check should be a glibc Linux check
- epatch "${FILESDIR}"/fix-android-check-musl.patch
- # <sys/sysctl.h> unavailable on musl
- epatch "${FILESDIR}"/fix-jemalloc-includes-musl.patch
- # <sys/sysctl.h> unavailable on musl, also wrong order of kernel headers
- # Portions from
- #
http://git.alpinelinux.org/cgit/aports/tree/main/firefox/fix-media.patch
- epatch "${FILESDIR}"/fix-mtransport-includes-musl.patch
- # Dumb sctp-refimpl include fixes, to be improved and submitted upstream
- # Portions from
- #
http://git.alpinelinux.org/cgit/aports/tree/main/firefox/fix-netwerk.patch
- epatch "${FILESDIR}"/fix-sctp-includes-musl.patch
- # Files erroneously assume other headers include <sys/types.h>
- # Portions from
- #
http://git.alpinelinux.org/cgit/aports/tree/main/firefox/fix-tools.patch
- epatch "${FILESDIR}"/include-systypesh-musl.patch
- # Incorrect assumptions about pthread_t
- # https://bugzilla.mozilla.org/show_bug.cgi?id=1010194
- epatch "${FILESDIR}"/make-handleInt-unsigned-long-musl.patch
- # Felix Janda's amd64 fixes
- epatch "${FILESDIR}"/fix-amd64-build-musl.patch
- # Stagefright includes <sys/cdefs.h>, unavailable on musl. Upstream will
- # probably want to include it on Android.
- epatch "${FILESDIR}"/dont-include-cdefsh-stagefright-musl.patch
+ epatch "${FILESDIR}"/${PN}-35.0-gmp-clearkey-sprintf.patch
+ #epatch "${FILESDIR}"/${PN}-36.0-disable-ion.patch
+ #epatch "${FILESDIR}"/${PN}-36.0-depollute-CONST-from-dtoa.patch
+
+ ## patches for building with musl libc
+
+ # already upstream
+ epatch "${FILESDIR}"/1130164.patch
+ epatch "${FILESDIR}"/1130175.patch
+ epatch "${FILESDIR}"/sctp-36.patch # backported
+ epatch "${FILESDIR}"/1130710.patch
+
+ # others against hg
+ epatch "${FILESDIR}"/basename.patch
+ epatch "${FILESDIR}"/crashreporter.patch
+ epatch "${FILESDIR}"/fts.patch
+ epatch "${FILESDIR}"/libstagefright-cdefs.patch
+ epatch "${FILESDIR}"/profiler-gettid.patch
+ epatch "${FILESDIR}"/sandbox-cdefs.patch
+ epatch "${FILESDIR}"/updater.patch
+ epatch "${FILESDIR}"/xpcom-blocksize.patch
+ epatch "${FILESDIR}"/sipcc.patch
+
+ cp
"${S}"/media/mtransport/third_party/nrappkit/src/port/generic/include/sys/queue.h
"${S}"/media/mtransport/third_party/nrappkit/src/port/linux/include/sys
+
+ ## end of musl patching
# Allow user to apply any additional patches without modifing ebuild
epatch_user
- # From http://git.alpinelinux.org/cgit/aports/tree/main/firefox/stab.h,
added N_UNDF
- cp "${FILESDIR}"/stab.h
"${S}"/toolkit/crashreporter/google-breakpad/src/
-
# Enable gnomebreakpad
if use debug ; then
sed -i -e
"s:GNOME_DISABLE_CRASH_DIALOG=1:GNOME_DISABLE_CRASH_DIALOG=0:g" \
@@ -394,7 +378,11 @@ src_install() {
fi
# Required in order to use plugins and even run firefox on hardened.
- pax-mark m
"${ED}"${MOZILLA_FIVE_HOME}/{firefox,firefox-bin,plugin-container}
+ if use jit; then
+ pax-mark m
"${ED}"${MOZILLA_FIVE_HOME}/{firefox,firefox-bin,plugin-container}
+ else
+ pax-mark m "${ED}"${MOZILLA_FIVE_HOME}/plugin-container
+ fi
if use minimal; then
rm -r "${ED}"/usr/include
"${ED}${MOZILLA_FIVE_HOME}"/{idl,include,lib,sdk} \
@@ -411,6 +399,11 @@ src_install() {
insinto /etc/revdep-rebuild
echo "SEARCH_DIRS_MASK=${MOZILLA_FIVE_HOME}" >> ${T}/10firefox
doins "${T}"/10${PN} || die
+
+ # workaround to make firefox find libmozalloc.so on musl
+ insinto /etc/env.d
+ echo "LDPATH=${MOZILLA_FIVE_HOME}" >> "${T}"/20firefox
+ doins "${T}"/20firefox || die
}
pkg_preinst() {