diff options
author | jbeich <jbeich@FreeBSD.org> | 2016-11-02 09:42:30 +0800 |
---|---|---|
committer | jbeich <jbeich@FreeBSD.org> | 2016-11-02 09:42:30 +0800 |
commit | a84a2bdb7ce4d76acf7dd744abd2439154426914 (patch) | |
tree | 171dc9211a3eac82863466179ee9da413dd65f85 /www/firefox | |
parent | 9e0eb3b3fdda12206da60f73d0c2e0bf1c27d090 (diff) | |
download | freebsd-ports-gnome-a84a2bdb7ce4d76acf7dd744abd2439154426914.tar.gz freebsd-ports-gnome-a84a2bdb7ce4d76acf7dd744abd2439154426914.tar.zst freebsd-ports-gnome-a84a2bdb7ce4d76acf7dd744abd2439154426914.zip |
www/firefox: update to 50.0 (rc1)
More candidates are likely to come before the official announcement (aka
the rush hour) scheduled on 2016-11-15. This one intended to pick up upstream
security fixes earlier while looking for downstream regressions.
Changes: https://www.mozilla.org/firefox/50.0/releasenotes/
Security: d1853110-07f4-4645-895b-6fd462ad0589
MFH: 2016Q4 (piling up)
Diffstat (limited to 'www/firefox')
-rw-r--r-- | www/firefox/Makefile | 8 | ||||
-rw-r--r-- | www/firefox/distinfo | 6 | ||||
-rw-r--r-- | www/firefox/files/patch-browser-app-nsBrowserApp.cpp | 15 | ||||
-rw-r--r-- | www/firefox/files/patch-bug1021761 | 58 | ||||
-rw-r--r-- | www/firefox/files/patch-bug1130155 | 179 | ||||
-rw-r--r-- | www/firefox/files/patch-bug1278861 | 38 | ||||
-rw-r--r-- | www/firefox/files/patch-bug1299694 | 31 | ||||
-rw-r--r-- | www/firefox/files/patch-bug826985 | 4 | ||||
-rw-r--r-- | www/firefox/files/patch-bug847568 | 216 | ||||
-rw-r--r-- | www/firefox/files/patch-z-bug517422 | 8 |
10 files changed, 149 insertions, 414 deletions
diff --git a/www/firefox/Makefile b/www/firefox/Makefile index 838d16dd142e..9472fce0e9d2 100644 --- a/www/firefox/Makefile +++ b/www/firefox/Makefile @@ -2,23 +2,23 @@ # $FreeBSD$ PORTNAME= firefox -DISTVERSION= 49.0.2 +DISTVERSION= 50.0 DISTVERSIONSUFFIX=.source PORTEPOCH= 1 CATEGORIES= www ipv6 MASTER_SITES= MOZILLA/${PORTNAME}/releases/${DISTVERSION}/source \ - MOZILLA/${PORTNAME}/candidates/${DISTVERSION}-candidates/build2/source + MOZILLA/${PORTNAME}/candidates/${DISTVERSION}-candidates/build1/source MAINTAINER= gecko@FreeBSD.org COMMENT= Web browser based on the browser portion of Mozilla BUILD_DEPENDS= nspr>=4.12:devel/nspr \ - nss>=3.25:security/nss \ + nss>=3.26.2:security/nss \ libevent2>=2.0.21_2:devel/libevent2 \ soundtouch>=1.9.0:audio/soundtouch \ harfbuzz>=1.2.6:print/harfbuzz \ graphite2>=1.3.8:graphics/graphite2 \ - png>=1.6.21:graphics/png \ + png>=1.6.23:graphics/png \ libvorbis>=1.3.5,3:audio/libvorbis \ libvpx>=1.5.0:multimedia/libvpx \ sqlite3>=3.13:databases/sqlite3 \ diff --git a/www/firefox/distinfo b/www/firefox/distinfo index c4e2692fd12f..8fb404efed40 100644 --- a/www/firefox/distinfo +++ b/www/firefox/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1477039138 -SHA256 (firefox-49.0.2.source.tar.xz) = 67abe9202958c36bf60454c91065953aa8f6ede83ea1c0e9cdb870c3fc3d56d0 -SIZE (firefox-49.0.2.source.tar.xz) = 188669928 +TIMESTAMP = 1477916479 +SHA256 (firefox-50.0.source.tar.xz) = b322309e1021254eb1bb69ed5938d0cebc5e8201d155afe595f3db41e03b6357 +SIZE (firefox-50.0.source.tar.xz) = 196035352 diff --git a/www/firefox/files/patch-browser-app-nsBrowserApp.cpp b/www/firefox/files/patch-browser-app-nsBrowserApp.cpp index 97b7b8d0cd0b..68cb778b95a7 100644 --- a/www/firefox/files/patch-browser-app-nsBrowserApp.cpp +++ b/www/firefox/files/patch-browser-app-nsBrowserApp.cpp @@ -1,11 +1,12 @@ ---- browser/app/nsBrowserApp.cpp~ +--- browser/app/nsBrowserApp.cpp.orig 2016-09-19 16:19:28 UTC +++ browser/app/nsBrowserApp.cpp -@@ -417,6 +417,8 @@ int main(int argc, char* argv[]) - TriggerQuirks(); - #endif +@@ -324,6 +324,9 @@ int main(int argc, char* argv[], char* e + { + mozilla::TimeStamp start = mozilla::TimeStamp::Now(); + setenv("MOZ_GMP_PATH", "%%LOCALBASE%%/lib/browser_plugins/symlinks/gecko", 0); + setenv("MOZ_PLUGIN_PATH", "%%LOCALBASE%%/lib/browser_plugins/symlinks/gecko", 0); - int gotCounters; - #if defined(XP_UNIX) - struct rusage initialRUsage; ++ + #ifdef HAS_DLL_BLOCKLIST + DllBlocklist_Initialize(); + diff --git a/www/firefox/files/patch-bug1021761 b/www/firefox/files/patch-bug1021761 index 2b0096c41869..a73bd09f6dc9 100644 --- a/www/firefox/files/patch-bug1021761 +++ b/www/firefox/files/patch-bug1021761 @@ -187,22 +187,13 @@ index a962553..1f780f4 100644 }; enum stream_state { -@@ -262,7 +309,7 @@ alsa_refill_stream(cubeb_stream * stm) +@@ -260,10 +307,10 @@ alsa_refill_stream(cubeb_stream * stm) pthread_mutex_lock(&stm->mutex); -- r = snd_pcm_poll_descriptors_revents(stm->pcm, stm->fds, stm->nfds, &revents); -+ r = WRAP(snd_pcm_poll_descriptors_revents)(stm->pcm, stm->fds, stm->nfds, &revents); - if (r < 0 || revents != POLLOUT) { - /* This should be a stream error; it makes no sense for poll(2) to wake - for this stream and then have the stream report that it's not ready. -@@ -271,10 +318,10 @@ alsa_refill_stream(cubeb_stream * stm) - return RUNNING; - } - - avail = snd_pcm_avail_update(stm->pcm); + avail = WRAP(snd_pcm_avail_update)(stm->pcm); - if (avail == -EPIPE) { + if (avail < 0) { - snd_pcm_recover(stm->pcm, avail, 1); - avail = snd_pcm_avail_update(stm->pcm); + WRAP(snd_pcm_recover)(stm->pcm, avail, 1); @@ -210,19 +201,8 @@ index a962553..1f780f4 100644 } /* Failed to recover from an xrun, this stream must be broken. */ -@@ -293,8 +340,8 @@ alsa_refill_stream(cubeb_stream * stm) - available to write. If avail is still zero here, the stream must be in - a funky state, so recover and try again. */ - if (avail == 0) { -- snd_pcm_recover(stm->pcm, -EPIPE, 1); -- avail = snd_pcm_avail_update(stm->pcm); -+ WRAP(snd_pcm_recover)(stm->pcm, -EPIPE, 1); -+ avail = WRAP(snd_pcm_avail_update)(stm->pcm); - if (avail <= 0) { - pthread_mutex_unlock(&stm->mutex); - stm->state_callback(stm, stm->user_ptr, CUBEB_STATE_ERROR); -@@ -302,7 +349,7 @@ alsa_refill_stream(cubeb_stream * stm) - } +@@ -286,7 +333,7 @@ alsa_refill_stream(cubeb_stream * stm) + return RUNNING; } - p = calloc(1, snd_pcm_frames_to_bytes(stm->pcm, avail)); @@ -230,13 +210,13 @@ index a962553..1f780f4 100644 assert(p); pthread_mutex_unlock(&stm->mutex); -@@ -327,10 +374,10 @@ alsa_refill_stream(cubeb_stream * stm) +@@ -312,10 +359,10 @@ alsa_refill_stream(cubeb_stream * stm) b[i] *= stm->volume; } } - wrote = snd_pcm_writei(stm->pcm, p, got); + wrote = WRAP(snd_pcm_writei)(stm->pcm, p, got); - if (wrote == -EPIPE) { + if (wrote < 0) { - snd_pcm_recover(stm->pcm, wrote, 1); - wrote = snd_pcm_writei(stm->pcm, p, got); + WRAP(snd_pcm_recover)(stm->pcm, wrote, 1); @@ -514,15 +494,15 @@ index a962553..1f780f4 100644 + r = WRAP(snd_pcm_nonblock)(stm->pcm, 1); assert(r == 0); - /* Ugly hack: the PA ALSA plugin allows buffer configurations that can't -@@ -859,7 +965,7 @@ alsa_stream_init(cubeb * ctx, cubeb_stre - latency = latency < 500 ? 500 : latency; + latency_us = latency_frames * 1e6 / stm->params.rate; +@@ -855,7 +961,7 @@ alsa_stream_init(cubeb * ctx, cubeb_stre + latency_us = latency_us < min_latency ? min_latency: latency_us; } - r = snd_pcm_set_params(stm->pcm, format, SND_PCM_ACCESS_RW_INTERLEAVED, + r = WRAP(snd_pcm_set_params)(stm->pcm, format, SND_PCM_ACCESS_RW_INTERLEAVED, stm->params.channels, stm->params.rate, 1, - latency * 1000); + latency_us); if (r < 0) { @@ -867,15 +973,15 @@ alsa_stream_init(cubeb * ctx, cubeb_stre return CUBEB_ERROR_INVALID_FORMAT; @@ -567,12 +547,12 @@ index a962553..1f780f4 100644 if (r < 0) { return CUBEB_ERROR; } -@@ -963,34 +1069,34 @@ alsa_get_preferred_sample_rate(cubeb * ctx, uint32_t * rate) { +@@ -969,34 +1075,34 @@ alsa_get_preferred_sample_rate(cubeb * c /* get a pcm, disabling resampling, so we get a rate the * hardware/dmix/pulse/etc. supports. */ -- r = snd_pcm_open(&pcm, CUBEB_ALSA_PCM_NAME, SND_PCM_STREAM_PLAYBACK | SND_PCM_NO_AUTO_RESAMPLE, 0); -+ r = WRAP(snd_pcm_open)(&pcm, CUBEB_ALSA_PCM_NAME, SND_PCM_STREAM_PLAYBACK | SND_PCM_NO_AUTO_RESAMPLE, 0); +- r = snd_pcm_open(&pcm, CUBEB_ALSA_PCM_NAME, SND_PCM_STREAM_PLAYBACK, SND_PCM_NO_AUTO_RESAMPLE); ++ r = WRAP(snd_pcm_open)(&pcm, CUBEB_ALSA_PCM_NAME, SND_PCM_STREAM_PLAYBACK, SND_PCM_NO_AUTO_RESAMPLE); if (r < 0) { return CUBEB_ERROR; } @@ -1137,14 +1117,14 @@ diff --git media/libcubeb/update.sh media/libcubeb/update.sh index a96badd..2f9585e 100755 --- media/libcubeb/update.sh +++ media/libcubeb/update.sh -@@ -10,6 +10,7 @@ cp $1/src/cubeb_audiounit.c src - cp $1/src/cubeb_pulse.c src - cp $1/src/cubeb_sndio.c src +@@ -16,6 +16,7 @@ cp $1/src/cubeb_audiounit.cpp src + cp $1/src/cubeb_osx_run_loop.h src + cp $1/src/cubeb_jack.cpp src cp $1/src/cubeb_opensl.c src +cp $1/src/cubeb_oss.c src - cp $1/src/cubeb_audiotrack.c src - cp $1/src/cubeb_wasapi.cpp src - cp $1/src/cubeb_resampler.h src + cp $1/src/cubeb_panner.cpp src + cp $1/src/cubeb_panner.h src + cp $1/src/cubeb_pulse.c src diff --git media/webrtc/signaling/test/common.build media/webrtc/signaling/test/common.build index 991f03f..3d99eb5 100644 --- media/webrtc/signaling/test/common.build diff --git a/www/firefox/files/patch-bug1130155 b/www/firefox/files/patch-bug1130155 deleted file mode 100644 index 34584d42823f..000000000000 --- a/www/firefox/files/patch-bug1130155 +++ /dev/null @@ -1,179 +0,0 @@ -commit eab3e3a -Author: Mikhail Teterin <mi@aldan.algebra.com> -Date: Tue Dec 16 19:34:02 2014 -0800 - - Bug 1130155 - Avoid assert failures when consuming only part of buffer. ---- - media/libcubeb/src/cubeb_alsa.c | 112 ++++++++++++++++++++++++++++++---------- - 1 file changed, 85 insertions(+), 27 deletions(-) - -diff --git media/libcubeb/src/cubeb_alsa.c media/libcubeb/src/cubeb_alsa.c -index 9bbc129..e72944a 100644 ---- media/libcubeb/src/cubeb_alsa.c -+++ media/libcubeb/src/cubeb_alsa.c -@@ -14,6 +14,8 @@ - #include <limits.h> - #include <dlfcn.h> - #include <poll.h> -+#include <stdlib.h> -+#include <stdio.h> - #include <unistd.h> - #include <alsa/asoundlib.h> - #include "cubeb/cubeb.h" -@@ -45,6 +47,7 @@ MAKE_TYPEDEF(snd_pcm_avail_update); - MAKE_TYPEDEF(snd_pcm_close); - MAKE_TYPEDEF(snd_pcm_delay); - MAKE_TYPEDEF(snd_pcm_drain); -+MAKE_TYPEDEF(snd_pcm_forward); - MAKE_TYPEDEF(snd_pcm_frames_to_bytes); - MAKE_TYPEDEF(snd_pcm_get_params); - /* snd_pcm_hw_params_alloca is actually a macro */ -@@ -305,32 +308,35 @@ alsa_refill_stream(cubeb_stream * stm) - long got; - void * p; - int draining; -+ unsigned pipefailures, againfailures; - - draining = 0; - - pthread_mutex_lock(&stm->mutex); - -- r = WRAP(snd_pcm_poll_descriptors_revents)(stm->pcm, stm->fds, stm->nfds, &revents); -- if (r < 0 || revents != POLLOUT) { -- /* This should be a stream error; it makes no sense for poll(2) to wake -- for this stream and then have the stream report that it's not ready. -- Unfortunately, this does happen, so just bail out and try again. */ -- pthread_mutex_unlock(&stm->mutex); -- return RUNNING; -- } -+ for (pipefailures = 0;;) { -+ r = WRAP(snd_pcm_poll_descriptors_revents)(stm->pcm, stm->fds, stm->nfds, &revents); -+ if (r < 0 || revents != POLLOUT || -+ (avail = WRAP(snd_pcm_avail_update)(stm->pcm)) == 0) { -+ /* This should be a stream error; it makes no sense for poll(2) to wake -+ for this stream and then have the stream report that it's not ready. -+ Unfortunately, this does happen, so just bail out and try again. */ -+ pthread_mutex_unlock(&stm->mutex); -+ return RUNNING; -+ } - -- avail = WRAP(snd_pcm_avail_update)(stm->pcm); -- if (avail == -EPIPE) { -+ if (avail > 0) -+ break; -+ if (pipefailures++ > 11) { -+ fprintf(stderr, "%s: repeated failures from snd_pcm_avail_update, " -+ "giving up\n", __func__); -+ pthread_mutex_unlock(&stm->mutex); -+ stm->state_callback(stm, stm->user_ptr, CUBEB_STATE_ERROR); -+ return ERROR; -+ } - WRAP(snd_pcm_recover)(stm->pcm, avail, 1); -- avail = WRAP(snd_pcm_avail_update)(stm->pcm); -- } -- -- /* Failed to recover from an xrun, this stream must be broken. */ -- if (avail < 0) { -- pthread_mutex_unlock(&stm->mutex); -- stm->state_callback(stm, stm->user_ptr, CUBEB_STATE_ERROR); -- return ERROR; - } -+ pipefailures = againfailures = 0; - - /* This should never happen. */ - if ((unsigned int) avail > stm->buffer_size) { -@@ -359,10 +365,11 @@ alsa_refill_stream(cubeb_stream * stm) - if (got < 0) { - pthread_mutex_unlock(&stm->mutex); - stm->state_callback(stm, stm->user_ptr, CUBEB_STATE_ERROR); -+ free(p); - return ERROR; - } - if (got > 0) { -- snd_pcm_sframes_t wrote; -+ snd_pcm_sframes_t wrote, towrite = got; - - if (stm->params.format == CUBEB_SAMPLE_FLOAT32NE) { - float * b = (float *) p; -@@ -375,14 +382,62 @@ alsa_refill_stream(cubeb_stream * stm) - b[i] *= stm->volume; - } - } -- wrote = WRAP(snd_pcm_writei)(stm->pcm, p, got); -- if (wrote == -EPIPE) { -- WRAP(snd_pcm_recover)(stm->pcm, wrote, 1); -- wrote = WRAP(snd_pcm_writei)(stm->pcm, p, got); -+ for (;;) { -+ wrote = WRAP(snd_pcm_writei)(stm->pcm, p, -+ towrite > avail ? avail : towrite); -+ switch(wrote) { -+ case -EPIPE: -+ if (pipefailures++ > 3) { -+ fprintf(stderr, "%s: Too many underflows, giving up\n", __func__); -+ stm->state_callback(stm, stm->user_ptr, CUBEB_STATE_ERROR); -+ pthread_mutex_unlock(&stm->mutex); -+ free(p); -+ return ERROR; -+ } -+ WRAP(snd_pcm_recover)(stm->pcm, wrote, 1); -+ continue; -+ case -EAGAIN: -+ if (againfailures++ > 3) { -+ fprintf(stderr, "%s: Too many -EAGAIN errors from snd_pcm_writei, " -+ "giving up\n", __func__); -+ stm->state_callback(stm, stm->user_ptr, CUBEB_STATE_ERROR); -+ pthread_mutex_unlock(&stm->mutex); -+ free(p); -+ return ERROR; -+ } -+ continue; -+ case -EBADFD: -+ fprintf(stderr, "%s: snc_pcm_writei returned -%s, giving up\n", -+ __func__, "EBADFD"); -+ free(p); -+ stm->state_callback(stm, stm->user_ptr, CUBEB_STATE_ERROR); -+ pthread_mutex_unlock(&stm->mutex); -+ return ERROR; -+ } -+ if (wrote < 0) { -+ fprintf(stderr, "%s: snc_pcm_writei returned unexpected error %lld, " -+ "giving up\n", __func__, (long long)wrote); -+ free(p); -+ stm->state_callback(stm, stm->user_ptr, CUBEB_STATE_ERROR); -+ pthread_mutex_unlock(&stm->mutex); -+ return ERROR; -+ } -+ pipefailures = againfailures = 0; -+ stm->write_position += wrote; -+ gettimeofday(&stm->last_activity, NULL); -+ if (wrote > towrite) { -+ fprintf(stderr, "%s: snc_pcm_writei wrote %lld frames, which was more " -+ "than we requested (%lld). This should not happen, giving up\n", -+ __func__, (long long)wrote, (long long)towrite); -+ free(p); -+ stm->state_callback(stm, stm->user_ptr, CUBEB_STATE_ERROR); -+ pthread_mutex_unlock(&stm->mutex); -+ return ERROR; -+ } -+ if (towrite == wrote) -+ break; -+ towrite -= wrote; - } -- assert(wrote >= 0 && wrote == got); -- stm->write_position += wrote; -- gettimeofday(&stm->last_activity, NULL); - } - if (got != avail) { - long buffer_fill = stm->buffer_size - (avail - got); -@@ -1177,7 +1232,10 @@ alsa_stream_get_position(cubeb_stream * stm, uint64_t * position) - return CUBEB_OK; - } - -- assert(delay >= 0); -+ if (delay < 0) { -+ WRAP(snd_pcm_forward)(stm->pcm, -delay); -+ delay = 0; -+ } - - *position = 0; - if (stm->write_position >= (snd_pcm_uframes_t) delay) { diff --git a/www/firefox/files/patch-bug1278861 b/www/firefox/files/patch-bug1278861 deleted file mode 100644 index 179057598809..000000000000 --- a/www/firefox/files/patch-bug1278861 +++ /dev/null @@ -1,38 +0,0 @@ - -# HG changeset patch -# User Nathan Froyd <froydnj@gmail.com> -# Date 1466820205 14400 -# Node ID bd25b06261c840a62d035192cf4b1dbc18f54e3f -# Parent fbe25a30fcbbe172bdd37c70c5b06cdbb07886af -Bug 1278861 - adjust ifdefs in Conversions.h:ToInt32 to catch clang-on-arm-generally; r=luke - -The bug noted in ToInt32 doesn't just exist when compiling for -arm-darwin; it exists for ARM targets generally. The ifdef should -reflect that. - -diff --git js/public/Conversions.h js/public/Conversions.h ---- js/public/Conversions.h -+++ js/public/Conversions.h -@@ -395,19 +395,19 @@ ToIntWidth(double d) - } - - } // namespace detail - - /* ES5 9.5 ToInt32 (specialized for doubles). */ - inline int32_t - ToInt32(double d) - { -- // clang crashes compiling this when targeting arm-darwin: -+ // clang crashes compiling this when targeting arm: - // https://llvm.org/bugs/show_bug.cgi?id=22974 --#if defined (__arm__) && defined (__GNUC__) && !defined(__APPLE__) -+#if defined (__arm__) && defined (__GNUC__) && !defined(__clang__) - int32_t i; - uint32_t tmp0; - uint32_t tmp1; - uint32_t tmp2; - asm ( - // We use a pure integer solution here. In the 'softfp' ABI, the argument - // will start in r0 and r1, and VFP can't do all of the necessary ECMA - // conversions by itself so some integer code will be required anyway. A - diff --git a/www/firefox/files/patch-bug1299694 b/www/firefox/files/patch-bug1299694 deleted file mode 100644 index 2742c32b4f4a..000000000000 --- a/www/firefox/files/patch-bug1299694 +++ /dev/null @@ -1,31 +0,0 @@ -commit 6ab2496 -Author: Chris Pearce <cpearce@mozilla.com> -Date: Mon Sep 5 13:54:37 2016 +1200 - - Bug 1299694 - Ensure we don't enable Widevine unintentionally. r=glandium - - On FreeBSD the target.kernel etc checks in enable_eme are failing, - but we're still falling through to |return value|, and so Widevine - is being enabled. If we remove the |return value| from enable_eme - we at least make Widevine disabled where it's not supposed to be - enabled. - - MozReview-Commit-ID: D1h0IUidxhv ---- - toolkit/moz.configure | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -diff --git toolkit/moz.configure toolkit/moz.configure -index 0c98c7a..a00b6eb 100644 ---- toolkit/moz.configure -+++ toolkit/moz.configure -@@ -366,7 +366,8 @@ def enable_eme(value, target): - return value - elif value and value.origin != 'default': - die('%s is not supported on %s' % (value.format('--enable-eme'), target.alias)) -- return value -+ # Return the same type of OptionValue (Positive or Negative), with an empty tuple. -+ return value.__class__(()) - - @depends(enable_eme, fmp4) - def eme(value, fmp4): diff --git a/www/firefox/files/patch-bug826985 b/www/firefox/files/patch-bug826985 index 7d742174c750..42514af9226f 100644 --- a/www/firefox/files/patch-bug826985 +++ b/www/firefox/files/patch-bug826985 @@ -17,14 +17,14 @@ diff --git config/system-headers config/system-headers index 55e4cd1..76567b3 100644 --- config/system-headers +++ config/system-headers -@@ -629,6 +629,7 @@ libgnome/libgnome.h +@@ -624,6 +624,7 @@ libgnome/libgnome.h libgnomeui/gnome-icon-lookup.h libgnomeui/gnome-icon-theme.h libgnomeui/gnome-ui-init.h +libv4l2.h - limits limits.h link.h + #ifdef ANDROID diff --git old-configure.in configure.in index 55e4cd1..76567b3 100644 --- old-configure.in diff --git a/www/firefox/files/patch-bug847568 b/www/firefox/files/patch-bug847568 index db4ae1da1fb8..79de8056823b 100644 --- a/www/firefox/files/patch-bug847568 +++ b/www/firefox/files/patch-bug847568 @@ -1,20 +1,7 @@ # Allow building against system-wide graphite2/harfbuzz. -diff --git build/moz.configure/old.configure build/moz.configure/old.configure -index 4cbefd5..42ab554 100644 ---- build/moz.configure/old.configure -+++ build/moz.configure/old.configure -@@ -312,6 +312,8 @@ def old_configure_options(*options): - '--with-sixgill', - '--with-soft-float', - '--with-system-bz2', -+ '--with-system-graphite2', -+ '--with-system-harfbuzz', - '--with-system-icu', - '--with-system-jpeg', - '--with-system-libevent', diff --git config/Makefile.in config/Makefile.in -index 14bfc0d..5383399 100644 +index 10807cf..f4b8587 100644 --- config/Makefile.in +++ config/Makefile.in @@ -49,6 +49,8 @@ export:: $(export-preqs) @@ -23,14 +10,14 @@ index 14bfc0d..5383399 100644 -DMOZ_SYSTEM_ICU=$(MOZ_SYSTEM_ICU) \ + -DMOZ_SYSTEM_GRAPHITE2=$(MOZ_SYSTEM_GRAPHITE2) \ + -DMOZ_SYSTEM_HARFBUZZ=$(MOZ_SYSTEM_HARFBUZZ) \ - $(srcdir)/system-headers | $(PERL) $(topsrcdir)/nsprpub/config/make-system-wrappers.pl system_wrappers + $(srcdir)/system-headers $(srcdir)/stl-headers | $(PERL) $(topsrcdir)/nsprpub/config/make-system-wrappers.pl system_wrappers $(INSTALL) system_wrappers $(DIST) diff --git config/system-headers config/system-headers -index 18e8703..bdc5f82 100644 +index 48afa0f..61612f6 100644 --- config/system-headers +++ config/system-headers -@@ -1344,3 +1344,11 @@ unicode/utypes.h +@@ -1331,3 +1331,12 @@ unicode/utypes.h #endif libutil.h unwind.h @@ -39,79 +26,26 @@ index 18e8703..bdc5f82 100644 +graphite2/Segment.h +#endif +#if MOZ_SYSTEM_HARFBUZZ==1 ++harfbuzz/hb-glib.h +harfbuzz/hb-ot.h +harfbuzz/hb.h +#endif -diff --git old-configure.in configure.in -index ac38f40..87536b7 100644 ---- old-configure.in -+++ old-configure.in -@@ -7989,6 +7989,49 @@ if test "$USE_FC_FREETYPE"; then - fi - - dnl ======================================================== -+dnl Check for harfbuzz -+dnl ======================================================== -+ -+MOZ_ARG_WITH_BOOL(system-harfbuzz, -+[ --with-system-harfbuzz Use system harfbuzz (located with pkgconfig)], -+MOZ_SYSTEM_HARFBUZZ=1, -+MOZ_SYSTEM_HARFBUZZ=) -+ -+if test -n "$MOZ_SYSTEM_HARFBUZZ"; then -+ PKG_CHECK_MODULES(MOZ_HARFBUZZ, harfbuzz >= 1.2.6) -+fi -+ -+AC_SUBST(MOZ_SYSTEM_HARFBUZZ) -+ -+dnl ======================================================== -+dnl Check for graphite2 -+dnl ======================================================== -+ -+MOZ_ARG_WITH_BOOL(system-graphite2, -+[ --with-system-graphite2 Use system graphite2 (located with pkgconfig)], -+MOZ_SYSTEM_GRAPHITE2=1, -+MOZ_SYSTEM_GRAPHITE2=) -+ -+if test -n "$MOZ_SYSTEM_GRAPHITE2"; then -+ PKG_CHECK_MODULES(MOZ_GRAPHITE2, graphite2) -+ -+ dnl graphite2.pc has bogus version, check manually -+ AC_TRY_COMPILE([ #include <graphite2/Font.h> -+ #define GR2_VERSION_REQUIRE(major,minor,bugfix) \ -+ ( GR2_VERSION_MAJOR * 10000 + GR2_VERSION_MINOR \ -+ * 100 + GR2_VERSION_BUGFIX >= \ -+ (major) * 10000 + (minor) * 100 + (bugfix) ) -+ ], [ -+ #if !GR2_VERSION_REQUIRE(1,3,8) -+ #error "Insufficient graphite2 version." -+ #endif -+ ], [], -+ [AC_MSG_ERROR([--with-system-graphite2 requested but no working libgraphite2 found])]) -+fi -+ -+AC_SUBST(MOZ_SYSTEM_GRAPHITE2) -+ -+dnl ======================================================== - dnl Check for pixman and cairo - dnl ======================================================== - diff --git dom/base/moz.build dom/base/moz.build -index a660ba4..6b2f602 100644 +index 6e0d4f5..0770717 100644 --- dom/base/moz.build +++ dom/base/moz.build -@@ -397,6 +397,9 @@ if CONFIG['INTEL_ARCHITECTURE']: - SOURCES += ['nsTextFragmentSSE2.cpp'] - SOURCES['nsTextFragmentSSE2.cpp'].flags += CONFIG['SSE2_FLAGS'] +@@ -457,6 +457,9 @@ if CONFIG['MOZ_BUILD_APP'] in ['browser', 'mobile/android', 'xulrunner']: + if CONFIG['MOZ_X11']: + CXXFLAGS += CONFIG['TK_CFLAGS'] +if CONFIG['MOZ_SYSTEM_HARFBUZZ']: -+ SOURCES['nsContentUtils.cpp'].flags += CONFIG['MOZ_HARFBUZZ_CFLAGS'] ++ CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS'] + - EXTRA_COMPONENTS += [ - 'ConsoleAPI.manifest', - 'ConsoleAPIStorage.js', + GENERATED_FILES += [ + 'PropertyUseCounterMap.inc', + 'UseCounterList.h', diff --git gfx/graphite2/moz-gr-update.sh gfx/graphite2/moz-gr-update.sh -index f3d76ea..a9e7fb6 100644 +index faaab1b..04eff5f 100644 --- gfx/graphite2/moz-gr-update.sh +++ gfx/graphite2/moz-gr-update.sh @@ -1,6 +1,7 @@ @@ -122,7 +56,7 @@ index f3d76ea..a9e7fb6 100644 # This script lives in gfx/graphite2, along with the library source, # but must be run from the top level of the mozilla-central tree. -@@ -37,12 +38,16 @@ echo "See" $0 "for update procedure." >> +@@ -37,12 +38,16 @@ echo "See" $0 "for update procedure." >> gfx/graphite2/README.mozilla #find gfx/graphite2/ -name "*.cpp" -exec perl -p -i -e "s/<cstdio>/<stdio.h>/;s/Windows.h/windows.h/;" {} \; #find gfx/graphite2/ -name "*.h" -exec perl -p -i -e "s/<cstdio>/<stdio.h>/;s/Windows.h/windows.h/;" {} \; @@ -141,20 +75,20 @@ index f3d76ea..a9e7fb6 100644 echo echo If gfx/graphite2/src/files.mk has changed, please make corresponding diff --git gfx/harfbuzz/README-mozilla gfx/harfbuzz/README-mozilla -index ca57d16..1ce21fe 100644 +index 24e6cbb..0b7a5df 100644 --- gfx/harfbuzz/README-mozilla +++ gfx/harfbuzz/README-mozilla -@@ -18,3 +18,8 @@ the mozilla tree. - In addition, the src/Makefile.in file here is NOT from upstream, nor is it - generated from src/Makefile.am (the original harfbuzz version); it is a mozilla- - specific makefile that is maintained by hand. +@@ -20,3 +20,8 @@ the mozilla tree. + + If the collection of source files changes, manual updates to moz.build may be + needed, as we don't use the upstream makefiles. + +The in-tree copy may be omitted during build by --with-system-harfbuzz. +Make sure to keep pkg-config version check within old-configure.in in sync +with checkout version or increment latest tag by one if it's not based +on upstream release. diff --git gfx/moz.build gfx/moz.build -index 519aa46..6929751 100644 +index 2509198..5cc4663 100644 --- gfx/moz.build +++ gfx/moz.build @@ -7,6 +7,12 @@ @@ -180,38 +114,38 @@ index 519aa46..6929751 100644 'thebes', 'ipc', diff --git gfx/skia/generate_mozbuild.py gfx/skia/generate_mozbuild.py -index 28fa6b5..240dced 100755 +index ab1365f..8897c27 100755 --- gfx/skia/generate_mozbuild.py +++ gfx/skia/generate_mozbuild.py -@@ -134,6 +134,9 @@ if CONFIG['CLANG_CXX'] or CONFIG['CLANG_ +@@ -140,6 +140,9 @@ if CONFIG['CLANG_CXX'] or CONFIG['CLANG_CL']: '-Wno-unused-private-field', ] +if CONFIG['MOZ_SYSTEM_HARFBUZZ']: + CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS'] + - if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3', 'android', 'gonk', 'qt'): + if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3', 'android', 'gonk'): CXXFLAGS += CONFIG['MOZ_CAIRO_CFLAGS'] CXXFLAGS += CONFIG['CAIRO_FT_CFLAGS'] diff --git gfx/skia/moz.build gfx/skia/moz.build -index 1d0c2f9..adb8941 100644 +index a2f914b..d3759b0 100644 --- gfx/skia/moz.build +++ gfx/skia/moz.build -@@ -752,6 +752,9 @@ if CONFIG['CLANG_CXX'] or CONFIG['CLANG_ +@@ -664,6 +664,9 @@ if CONFIG['CLANG_CXX'] or CONFIG['CLANG_CL']: '-Wno-unused-private-field', ] +if CONFIG['MOZ_SYSTEM_HARFBUZZ']: + CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS'] + - if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3', 'android', 'gonk', 'qt'): + if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3', 'android', 'gonk'): CXXFLAGS += CONFIG['MOZ_CAIRO_CFLAGS'] CXXFLAGS += CONFIG['CAIRO_FT_CFLAGS'] diff --git gfx/thebes/moz.build gfx/thebes/moz.build -index d5852fa..aeeab25 100644 +index bbbce6fd..db0ceb1 100644 --- gfx/thebes/moz.build +++ gfx/thebes/moz.build -@@ -306,7 +306,13 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk +@@ -289,7 +289,13 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('gtk2', 'gtk3'): LOCAL_INCLUDES += CONFIG['SKIA_INCLUDES'] @@ -226,19 +160,55 @@ index d5852fa..aeeab25 100644 if CONFIG['CLANG_CXX']: # Suppress warnings from Skia header files. -index d736943..41a931f 100644 +diff --git intl/unicharutil/util/moz.build intl/unicharutil/util/moz.build +index 9754753..768cc7d 100644 --- intl/unicharutil/util/moz.build +++ intl/unicharutil/util/moz.build -@@ -44,4 +44,7 @@ if CONFIG['ENABLE_INTL_API']: - LOCAL_INCLUDES += CONFIG['MOZ_ICU_INCLUDES'] +@@ -42,4 +42,7 @@ if CONFIG['_MSC_VER']: + if CONFIG['ENABLE_INTL_API']: USE_LIBS += ['icu'] +if CONFIG['MOZ_SYSTEM_HARFBUZZ']: + CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS'] + DIST_INSTALL = True +diff --git moz.configure moz.configure +index e762576..196dafd 100644 +--- moz.configure ++++ moz.configure +@@ -216,6 +216,30 @@ check_prog('GENISOIMAGE', delayed_getattr(extra_programs, 'GENISOIMAGE'), + check_prog('RPMBUILD', delayed_getattr(extra_programs, 'RPMBUILD'), + allow_missing=True) + ++option('--with-system-graphite2', ++ help="Use system graphite2 (located with pkgconfig)") ++ ++@depends('--with-system-graphite2', compile_environment) ++def check_for_graphite2(value, compile_env): ++ return value and compile_env ++ ++system_graphite2 = pkg_check_modules('MOZ_GRAPHITE2', 'graphite2', ++ check_for_graphite2) ++ ++set_config('MOZ_SYSTEM_GRAPHITE2', system_graphite2) ++ ++option('--with-system-harfbuzz', ++ help="Use system harfbuzz (located with pkgconfig)") ++ ++@depends('--with-system-harfbuzz', compile_environment) ++def check_for_harfbuzz(value, compile_env): ++ return value and compile_env ++ ++system_harfbuzz = pkg_check_modules('MOZ_HARFBUZZ', 'harfbuzz >= 1.2.6', ++ check_for_harfbuzz) ++ ++set_config('MOZ_SYSTEM_HARFBUZZ', system_harfbuzz) ++ + option('--enable-system-hunspell', + help="Use system hunspell (located with pkgconfig)") + diff --git netwerk/dns/moz.build netwerk/dns/moz.build -index 0b0717a..2e665c9 100644 +index f788d9a..5662301 100644 --- netwerk/dns/moz.build +++ netwerk/dns/moz.build @@ -66,6 +66,9 @@ LOCAL_INCLUDES += [ @@ -248,16 +218,48 @@ index 0b0717a..2e665c9 100644 +if CONFIG['MOZ_SYSTEM_HARFBUZZ']: + CXXFLAGS += CONFIG['MOZ_HARFBUZZ_CFLAGS'] + - if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk' and CONFIG['ANDROID_VERSION'] > '19': - LOCAL_INCLUDES += ['%' + '%s/bionic/libc/dns/include' % CONFIG['ANDROID_SOURCE']] + if CONFIG['ENABLE_INTL_API']: + DEFINES['IDNA2008'] = True + USE_LIBS += ['icu'] +diff --git old-configure.in old-configure.in +index 0070d48..9d1129f 100644 +--- old-configure.in ++++ old-configure.in +@@ -5764,6 +5764,27 @@ if test "$USE_FC_FREETYPE"; then + fi + + dnl ======================================================== ++dnl Check for graphite2 ++dnl ======================================================== ++if test -n "$MOZ_SYSTEM_GRAPHITE2"; then ++ dnl graphite2.pc has bogus version, check manually ++ _SAVE_CFLAGS=$CFLAGS ++ CFLAGS="$CFLAGS $MOZ_GRAPHITE2_CFLAGS" ++ AC_TRY_COMPILE([ #include <graphite2/Font.h> ++ #define GR2_VERSION_REQUIRE(major,minor,bugfix) \ ++ ( GR2_VERSION_MAJOR * 10000 + GR2_VERSION_MINOR \ ++ * 100 + GR2_VERSION_BUGFIX >= \ ++ (major) * 10000 + (minor) * 100 + (bugfix) ) ++ ], [ ++ #if !GR2_VERSION_REQUIRE(1,3,8) ++ #error "Insufficient graphite2 version." ++ #endif ++ ], [], ++ [AC_MSG_ERROR([--with-system-graphite2 requested but no working libgraphite2 found])]) ++ CFLAGS=$_SAVE_CFLAGS ++fi ++ ++dnl ======================================================== + dnl Check for pixman and cairo + dnl ======================================================== diff --git toolkit/library/moz.build toolkit/library/moz.build -index 67f0db9..d42137a 100644 +index a3d5450..2c684a7e 100644 --- toolkit/library/moz.build +++ toolkit/library/moz.build -@@ -231,6 +231,12 @@ if CONFIG['MOZ_SYSTEM_LIBVPX']: - if not CONFIG['MOZ_TREE_PIXMAN']: - OS_LIBS += CONFIG['MOZ_PIXMAN_LIBS'] +@@ -217,6 +217,12 @@ if CONFIG['MOZ_SYSTEM_JPEG']: + if CONFIG['MOZ_SYSTEM_PNG']: + OS_LIBS += CONFIG['MOZ_PNG_LIBS'] +if CONFIG['MOZ_SYSTEM_GRAPHITE2']: + OS_LIBS += CONFIG['MOZ_GRAPHITE2_LIBS'] @@ -265,6 +267,6 @@ index 67f0db9..d42137a 100644 +if CONFIG['MOZ_SYSTEM_HARFBUZZ']: + OS_LIBS += CONFIG['MOZ_HARFBUZZ_LIBS'] + - if CONFIG['MOZ_OSS']: - OS_LIBS += CONFIG['MOZ_OSS_LIBS'] + if CONFIG['MOZ_SYSTEM_HUNSPELL']: + OS_LIBS += CONFIG['MOZ_HUNSPELL_LIBS'] diff --git a/www/firefox/files/patch-z-bug517422 b/www/firefox/files/patch-z-bug517422 index 5e197e17cda7..482d6eba07d8 100644 --- a/www/firefox/files/patch-z-bug517422 +++ b/www/firefox/files/patch-z-bug517422 @@ -21,7 +21,7 @@ diff --git config/Makefile.in config/Makefile.in index 5383399..0410004 100644 --- config/Makefile.in +++ config/Makefile.in -@@ -77,6 +77,11 @@ export:: $(export-preqs) +@@ -51,6 +51,11 @@ export:: $(export-preqs) -DMOZ_SYSTEM_ICU=$(MOZ_SYSTEM_ICU) \ -DMOZ_SYSTEM_GRAPHITE2=$(MOZ_SYSTEM_GRAPHITE2) \ -DMOZ_SYSTEM_HARFBUZZ=$(MOZ_SYSTEM_HARFBUZZ) \ @@ -30,7 +30,7 @@ index 5383399..0410004 100644 + -DMOZ_SYSTEM_VORBIS=$(MOZ_SYSTEM_VORBIS) \ + -DMOZ_SYSTEM_TREMOR=$(MOZ_SYSTEM_TREMOR) \ + -DMOZ_SYSTEM_SOUNDTOUCH=$(MOZ_SYSTEM_SOUNDTOUCH) \ - $(srcdir)/system-headers | $(PERL) $(topsrcdir)/nsprpub/config/make-system-wrappers.pl system_wrappers + $(srcdir)/system-headers $(srcdir)/stl-headers | $(PERL) $(topsrcdir)/nsprpub/config/make-system-wrappers.pl system_wrappers $(INSTALL) system_wrappers $(DIST) diff --git config/external/moz.build config/external/moz.build @@ -238,7 +238,7 @@ index 2127256..1ec09fe 100644 } size_t -@@ -177,7 +181,11 @@ nsresult AudioStream::EnsureTimeStretcherInitializedUnlocked() +@@ -151,7 +155,11 @@ nsresult AudioStream::EnsureTimeStretche { mMonitor.AssertCurrentThreadOwns(); if (!mTimeStretcher) { @@ -247,7 +247,7 @@ index 2127256..1ec09fe 100644 +#else mTimeStretcher = soundtouch::createSoundTouchObj(); +#endif - mTimeStretcher->setSampleRate(mInRate); + mTimeStretcher->setSampleRate(mAudioClock.GetInputRate()); mTimeStretcher->setChannels(mOutChannels); mTimeStretcher->setPitch(1.0); diff --git dom/media/AudioStream.h dom/media/AudioStream.h |