Package: icedove
Version: 1:45.2.0-4
Severity: important
Tags: sid, patch
Justification: FTBFS
User: [email protected]
Usertags: mips-patch
Package icedove FTBFS for mips64el with an error:
> c++ -o Unified_cpp_media_libyuv1.o -c
> -I/«PKGBUILDDIR»/obj-icedove/dist/system_wrappers -include
> /«PKGBUILDDIR»/mozilla/config/gcc_hidden.h -D_FILE_OFFSET_BITS=64
> -DCHROMIUM_BUILD -DUSE_LIBJPEG_TURBO=1 -DUSE_NSS=1 -DENABLE_ONE_CLICK_SIGNIN
> -DGTK_DISABLE_SINGLE_INCLUDES=1 -D_ISOC99_SOURCE=1 -DENABLE_REMOTING=1
> -DENABLE_WEBRTC=1 -DENABLE_CONFIGURATION_POLICY -DENABLE_INPUT_SPEECH
> -DENABLE_NOTIFICATIONS -DENABLE_GPU=1 -DENABLE_EGLIMAGE=1 -DUSE_SKIA=1
> -DENABLE_TASK_MANAGER=1 -DENABLE_WEB_INTENTS=1 -DENABLE_EXTENSIONS=1
> -DENABLE_PLUGIN_INSTALLATION=1 -DENABLE_PROTECTOR_SERVICE=1
> -DENABLE_SESSION_SERVICE=1 -DENABLE_THEMES=1 -DENABLE_BACKGROUND=1
> -DENABLE_AUTOMATION=1 -DENABLE_PRINTING=1 -DENABLE_CAPTIVE_PORTAL_DETECTION=1
> -DHAVE_JPEG -DLIBYUV_DISABLE_AVX2 -DNDEBUG -DNVALGRIND
> -DDYNAMIC_ANNOTATIONS_ENABLED=0 -DSTATIC_EXPORTABLE_JS_API
> -DMOZILLA_INTERNAL_API -DIMPL_LIBXUL -I/«PKGBUILDDIR»/mozilla/media/libyuv
> -I. -I/«PKGBUILDDIR»/mozilla/media/libyuv/include
> -I/«PKGBUILDDIR»/mozilla/media/libyuv -I../../../ipc/ipdl/_ipdlheaders
> -I/«PKGBUILDDIR»/mozilla/ipc/chromium/src -I/«PKGBUILDDIR»/mozilla/ipc/glue
> -I../../../dist/include -fPIC -DMOZILLA_CLIENT -include
> ../../../mozilla-config.h -MD -MP -MF .deps/Unified_cpp_media_libyuv1.o.pp
> -Wdate-time -D_FORTIFY_SOURCE=2 -Wall -Wempty-body -Woverloaded-virtual
> -Wsign-compare -Wwrite-strings -Wno-invalid-offsetof -Wcast-align -g -O2
> -fdebug-prefix-map=/«PKGBUILDDIR»=. -fstack-protector-strong -Wformat
> -Werror=format-security -fno-delete-null-pointer-checks -fno-schedule-insns2
> -fno-exceptions -fno-strict-aliasing -fno-rtti -ffunction-sections
> -fdata-sections -fno-exceptions -fno-math-errno -std=gnu++0x -pthread -pipe
> -DNDEBUG -DTRIMMED -g -freorder-blocks -Os -fomit-frame-pointer
> /«PKGBUILDDIR»/obj-icedove/media/libyuv/libyuv_libyuv/Unified_cpp_media_libyuv1.cpp
> {standard input}: Assembler messages:
> {standard input}:1247: Error: invalid operands `lw $t4,16($4)'
> {standard input}:1248: Error: invalid operands `lw $t5,20($4)'
> {standard input}:1249: Error: invalid operands `lw $t6,24($4)'
> {standard input}:1250: Error: invalid operands `lw $t7,28($4)'
> ....
Full build log:
https://buildd.debian.org/status/fetch.php?pkg=icedove&arch=mips64el&ver=1%3A45.2.0-4&stamp=1471624442
This issue is caused because register names $t4-$t7 are only available in O32.
I had created a patch that solves this issue by disabling usage of mips
assembly for MIPS64.
The patch is attached. I was able to build icedove successfully for mips64el
using this patch.
Could you please consider including this patch?
Similar solution is available here:
https://github.com/svn2github/libyuv/commit/0fa7dd2dcf668e1733c3344bc47d6484c7d7544c
Regards,
Dejan
--- icedove-45.2.0.orig/mozilla/media/libyuv/include/libyuv/row.h
+++ icedove-45.2.0/mozilla/media/libyuv/include/libyuv/row.h
@@ -330,7 +330,8 @@ extern "C" {
#endif
// The following are available on Mips platforms:
-#if !defined(LIBYUV_DISABLE_MIPS) && defined(__mips__)
+#if !defined(LIBYUV_DISABLE_MIPS) && defined(__mips__)&& \
+ (_MIPS_SIM == _MIPS_SIM_ABI32)
#define HAS_COPYROW_MIPS
#if defined(__mips_dsp) && (__mips_dsp_rev >= 2)
#define HAS_I422TOABGRROW_MIPS_DSPR2
--- icedove-45.2.0.orig/mozilla/media/libyuv/source/rotate_mips.cc
+++ icedove-45.2.0/mozilla/media/libyuv/source/rotate_mips.cc
@@ -18,7 +18,8 @@ extern "C" {
#endif
#if !defined(LIBYUV_DISABLE_MIPS) && \
- defined(__mips_dsp) && (__mips_dsp_rev >= 2)
+ defined(__mips_dsp) && (__mips_dsp_rev >= 2) && \
+ (_MIPS_SIM == _MIPS_SIM_ABI32)
void TransposeWx8_MIPS_DSPR2(const uint8* src, int src_stride,
uint8* dst, int dst_stride,
--- icedove-45.2.0.orig/mozilla/media/libyuv/source/row_mips.cc
+++ icedove-45.2.0/mozilla/media/libyuv/source/row_mips.cc
@@ -16,7 +16,8 @@ extern "C" {
#endif
// The following are available on Mips platforms:
-#if !defined(LIBYUV_DISABLE_MIPS) && defined(__mips__)
+#if !defined(LIBYUV_DISABLE_MIPS) && defined(__mips__) && \
+ (_MIPS_SIM == _MIPS_SIM_ABI32)
#include <sgidefs.h>
@@ -414,7 +415,8 @@ void CopyRow_MIPS(const uint8* src, uint
// MIPS DSPR2 functions
#if !defined(LIBYUV_DISABLE_MIPS) && defined(__mips_dsp) && \
- (__mips_dsp_rev >= 2)
+ (__mips_dsp_rev >= 2) && \
+ (_MIPS_SIM == _MIPS_SIM_ABI32)
void SplitUVRow_MIPS_DSPR2(const uint8* src_uv, uint8* dst_u, uint8* dst_v,
int width) {
__asm__ __volatile__ (
--- icedove-45.2.0.orig/mozilla/media/libyuv/source/scale_mips.cc
+++ icedove-45.2.0/mozilla/media/libyuv/source/scale_mips.cc
@@ -18,7 +18,8 @@ extern "C" {
// This module is for GCC MIPS DSPR2
#if !defined(LIBYUV_DISABLE_MIPS) && \
- defined(__mips_dsp) && (__mips_dsp_rev >= 2)
+ defined(__mips_dsp) && (__mips_dsp_rev >= 2) && \
+ (_MIPS_SIM == _MIPS_SIM_ABI32)
void ScaleRowDown2_MIPS_DSPR2(const uint8* src_ptr, ptrdiff_t src_stride,
uint8* dst, int dst_width) {