Date: Tue, 20 Jan 2015 22:49:42 +0000 (UTC) From: Jan Beich <jbeich@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r377551 - in head/www: firefox/files seamonkey/files Message-ID: <201501202249.t0KMnggX082116@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jbeich Date: Tue Jan 20 22:49:41 2015 New Revision: 377551 URL: https://svnweb.freebsd.org/changeset/ports/377551 QAT: https://qat.redports.org/buildarchive/r377551/ Log: Unbreak build with base libstdc++ on i386 and powerpc std::abs(int64_t) for 32bit archs or std::llabs are not available in base libstdc++ from forked GCC 4.2.1 or before 10.0-RELEASE (r255294) for libstdc++ in lang/gcc47 and earlier (upstream PR libstdc++/54686). To avoid the build error use mozilla::Abs which implements overloads for all signed natural types but has unsigned return value. This change won't be requried for Firefox 36 et al. PR: 196772 Reported by: many Submitted by: bar (initial version) Obtained from: https://github.com/mozilla/gecko-dev/commit/e664fe8 Differential Revision: https://reviews.freebsd.org/D1569 Approved by: flo (mentor) MFH: 2015Q1 Added: head/www/firefox/files/patch-bug1122586 (contents, props changed) head/www/seamonkey/files/patch-bug1122586 (contents, props changed) Added: head/www/firefox/files/patch-bug1122586 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/www/firefox/files/patch-bug1122586 Tue Jan 20 22:49:41 2015 (r377551) @@ -0,0 +1,30 @@ +diff --git content/media/MediaDecoderStateMachine.cpp content/media/MediaDecoderStateMachine.cpp +index 36a6ccf..96d3bd0 100644 +--- content/media/MediaDecoderStateMachine.cpp ++++ content/media/MediaDecoderStateMachine.cpp +@@ -18,6 +18,7 @@ + #include "nsTArray.h" + #include "MediaDecoder.h" + #include "MediaDecoderReader.h" ++#include "mozilla/MathAlgorithms.h" + #include "mozilla/mozalloc.h" + #include "VideoUtils.h" + #include "mozilla/dom/TimeRanges.h" +@@ -165,7 +166,7 @@ static_assert(QUICK_BUFFERING_LOW_DATA_USECS <= AMPLE_AUDIO_USECS, + // MediaDecoderStateMachine::UpdateEstimatedDuration(); changes of duration + // less than this are ignored, as they're assumed to be the result of + // instability in the duration estimation. +-static const int64_t ESTIMATED_DURATION_FUZZ_FACTOR_USECS = USECS_PER_S / 2; ++static const uint64_t ESTIMATED_DURATION_FUZZ_FACTOR_USECS = USECS_PER_S / 2; + + static TimeDuration UsecsToDuration(int64_t aUsecs) { + return TimeDuration::FromMicroseconds(aUsecs); +@@ -1447,7 +1448,7 @@ void MediaDecoderStateMachine::UpdateEstimatedDuration(int64_t aDuration) + AssertCurrentThreadInMonitor(); + int64_t duration = GetDuration(); + if (aDuration != duration && +- std::abs(aDuration - duration) > ESTIMATED_DURATION_FUZZ_FACTOR_USECS) { ++ mozilla::Abs(aDuration - duration) > ESTIMATED_DURATION_FUZZ_FACTOR_USECS) { + SetDuration(aDuration); + nsCOMPtr<nsIRunnable> event = + NS_NewRunnableMethod(mDecoder, &MediaDecoder::DurationChanged); Added: head/www/seamonkey/files/patch-bug1122586 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/www/seamonkey/files/patch-bug1122586 Tue Jan 20 22:49:41 2015 (r377551) @@ -0,0 +1,30 @@ +diff --git content/media/MediaDecoderStateMachine.cpp content/media/MediaDecoderStateMachine.cpp +index 36a6ccf..96d3bd0 100644 +--- mozilla/content/media/MediaDecoderStateMachine.cpp ++++ mozilla/content/media/MediaDecoderStateMachine.cpp +@@ -18,6 +18,7 @@ + #include "nsTArray.h" + #include "MediaDecoder.h" + #include "MediaDecoderReader.h" ++#include "mozilla/MathAlgorithms.h" + #include "mozilla/mozalloc.h" + #include "VideoUtils.h" + #include "mozilla/dom/TimeRanges.h" +@@ -165,7 +166,7 @@ static_assert(QUICK_BUFFERING_LOW_DATA_USECS <= AMPLE_AUDIO_USECS, + // MediaDecoderStateMachine::UpdateEstimatedDuration(); changes of duration + // less than this are ignored, as they're assumed to be the result of + // instability in the duration estimation. +-static const int64_t ESTIMATED_DURATION_FUZZ_FACTOR_USECS = USECS_PER_S / 2; ++static const uint64_t ESTIMATED_DURATION_FUZZ_FACTOR_USECS = USECS_PER_S / 2; + + static TimeDuration UsecsToDuration(int64_t aUsecs) { + return TimeDuration::FromMicroseconds(aUsecs); +@@ -1447,7 +1448,7 @@ void MediaDecoderStateMachine::UpdateEstimatedDuration(int64_t aDuration) + AssertCurrentThreadInMonitor(); + int64_t duration = GetDuration(); + if (aDuration != duration && +- std::abs(aDuration - duration) > ESTIMATED_DURATION_FUZZ_FACTOR_USECS) { ++ mozilla::Abs(aDuration - duration) > ESTIMATED_DURATION_FUZZ_FACTOR_USECS) { + SetDuration(aDuration); + nsCOMPtr<nsIRunnable> event = + NS_NewRunnableMethod(mDecoder, &MediaDecoder::DurationChanged);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201501202249.t0KMnggX082116>