Package:firefox-esr

Version: 128.8.0esr-1

Severity: wishlist

Tags: patch

User: debian-loonga...@lists.debian.org

Usertags: loong64

Dear firefox-esrmaintainers,

Currently, 128.8.0esr-1 fails to compile on the loong64 platform.The attachment is a patch I made locally, which has been verified and can be used for reference.

In addition, I found that the upstream has fixed this problem since version 135.0-1. Can you consider upgrading the firefox-esr version or merging the patch into the current version?

If you have any questions or suggestions, you can contact me at any time.

thanks,
Xiaojuan Zhai

Description: fix loong64 build error 

---

--- firefox-esr-128.8.0esr.orig/media/libpng/moz.build
+++ firefox-esr-128.8.0esr/media/libpng/moz.build
@@ -65,6 +65,9 @@ if CONFIG['HAVE_ALTIVEC']:
         'powerpc/powerpc_init.c'
     ]
 
+if CONFIG['TARGET_CPU'] == 'loongarch64':
+    CFLAGS += ['-mno-lsx']
+
 if CONFIG['MOZ_TREE_FREETYPE']:
     DEFINES['FT_CONFIG_OPTION_USE_PNG'] = True
 
--- firefox-esr-128.8.0esr.orig/media/libyuv/libyuv/libyuv.gyp
+++ firefox-esr-128.8.0esr/media/libyuv/libyuv/libyuv.gyp
@@ -29,6 +29,7 @@
     'mips_msa%': 0,  # Default to msa off.
     'build_neon': 0,
     'build_msa': 0,
+    'build_lsx': 0,
     'conditions': [
        ['(target_arch == "armv7" or target_arch == "armv7s" or \
        (target_arch == "arm" and arm_version >= 7) or target_arch == "arm64")\
@@ -100,6 +101,15 @@
             'LIBYUV_MSA',
           ],
         }],
+        ['build_lsx == 0', {
+          'conditions': [
+            ['target_arch == "loongarch64"', {
+              'cflags_mozilla': [
+                '-mno-lsx',
+              ],
+            }],
+          ],
+        }],
         ['build_with_mozilla == 1', {
           'defines': [
             'HAVE_JPEG'

Reply via email to