summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWANG Xuerui <xen0n@gentoo.org>2025-02-21 10:13:19 +0800
committerWANG Xuerui <xen0n@gentoo.org>2025-02-21 17:17:58 +0800
commit869ed0f9863ce676ae14d8cdd7504c54f9f5cd94 (patch)
tree9f425e06e35460ffa3511bbb04ded107a0b416bb /www-client
parentwww-client/firefox-bin: match .desktop filename with app --name (diff)
downloadgentoo-869ed0f9863ce676ae14d8cdd7504c54f9f5cd94.tar.gz
gentoo-869ed0f9863ce676ae14d8cdd7504c54f9f5cd94.tar.bz2
gentoo-869ed0f9863ce676ae14d8cdd7504c54f9f5cd94.zip
www-client/firefox: add build support for loong
Some patches are still needed for a successful build with popular CFLAGS on loong, but src_prepare and src_configure need adaptation as well. Reviewed-by: Joonas Niilola <juippis@gentoo.org> Signed-off-by: WANG Xuerui <xen0n@gentoo.org>
Diffstat (limited to 'www-client')
-rw-r--r--www-client/firefox/firefox-128.7.0.ebuild10
-rw-r--r--www-client/firefox/firefox-135.0.1.ebuild10
-rw-r--r--www-client/firefox/firefox-135.0.ebuild10
3 files changed, 21 insertions, 9 deletions
diff --git a/www-client/firefox/firefox-128.7.0.ebuild b/www-client/firefox/firefox-128.7.0.ebuild
index 593ba0759bb1..bffe2b9202a7 100644
--- a/www-client/firefox/firefox-128.7.0.ebuild
+++ b/www-client/firefox/firefox-128.7.0.ebuild
@@ -614,6 +614,10 @@ src_prepare() {
export RUST_TARGET="i686-unknown-linux-musl"
elif use arm64 ; then
export RUST_TARGET="aarch64-unknown-linux-musl"
+ elif use loong; then
+ # Only the LP64D ABI of LoongArch64 is actively supported among
+ # the wider Linux ecosystem, so the assumption is safe.
+ export RUST_TARGET="loongarch64-unknown-linux-musl"
elif use ppc64 ; then
export RUST_TARGET="powerpc64le-unknown-linux-musl"
elif use riscv ; then
@@ -846,7 +850,7 @@ src_configure() {
# amd64, arm, arm64 & x86.
# Might want to flip the logic around if Firefox is to support more arches.
# bug 833001, bug 903411#c8
- if use ppc64 || use riscv; then
+ if use loong || use ppc64 || use riscv; then
mozconfig_add_options_ac '' --disable-sandbox
else
mozconfig_add_options_ac '' --enable-sandbox
@@ -1043,8 +1047,8 @@ src_configure() {
else
mozconfig_add_options_ac 'relr elf-hack' --enable-elf-hack=relr
fi
- elif use ppc64 || use riscv ; then
- # '--disable-elf-hack' is not recognized on ppc64/riscv,
+ elif use loong || use ppc64 || use riscv ; then
+ # '--disable-elf-hack' is not recognized on loong/ppc64/riscv,
# see bgo #917049, #930046
:;
else
diff --git a/www-client/firefox/firefox-135.0.1.ebuild b/www-client/firefox/firefox-135.0.1.ebuild
index 277ebf5efdd0..878488cd4e1c 100644
--- a/www-client/firefox/firefox-135.0.1.ebuild
+++ b/www-client/firefox/firefox-135.0.1.ebuild
@@ -616,6 +616,10 @@ src_prepare() {
export RUST_TARGET="i686-unknown-linux-musl"
elif use arm64 ; then
export RUST_TARGET="aarch64-unknown-linux-musl"
+ elif use loong; then
+ # Only the LP64D ABI of LoongArch64 is actively supported among
+ # the wider Linux ecosystem, so the assumption is safe.
+ export RUST_TARGET="loongarch64-unknown-linux-musl"
elif use ppc64 ; then
export RUST_TARGET="powerpc64le-unknown-linux-musl"
elif use riscv ; then
@@ -831,7 +835,7 @@ src_configure() {
# amd64, arm, arm64 & x86.
# Might want to flip the logic around if Firefox is to support more arches.
# bug 833001, bug 903411#c8
- if use ppc64 || use riscv; then
+ if use loong || use ppc64 || use riscv; then
mozconfig_add_options_ac '' --disable-sandbox
elif use valgrind; then
mozconfig_add_options_ac 'valgrind requirement' --disable-sandbox
@@ -1030,8 +1034,8 @@ src_configure() {
else
mozconfig_add_options_ac 'relr elf-hack' --enable-elf-hack=relr
fi
- elif use ppc64 || use riscv ; then
- # '--disable-elf-hack' is not recognized on ppc64/riscv,
+ elif use loong || use ppc64 || use riscv ; then
+ # '--disable-elf-hack' is not recognized on loong/ppc64/riscv,
# see bgo #917049, #930046
:;
else
diff --git a/www-client/firefox/firefox-135.0.ebuild b/www-client/firefox/firefox-135.0.ebuild
index 1fa325505b35..aaf2355e3c90 100644
--- a/www-client/firefox/firefox-135.0.ebuild
+++ b/www-client/firefox/firefox-135.0.ebuild
@@ -616,6 +616,10 @@ src_prepare() {
export RUST_TARGET="i686-unknown-linux-musl"
elif use arm64 ; then
export RUST_TARGET="aarch64-unknown-linux-musl"
+ elif use loong; then
+ # Only the LP64D ABI of LoongArch64 is actively supported among
+ # the wider Linux ecosystem, so the assumption is safe.
+ export RUST_TARGET="loongarch64-unknown-linux-musl"
elif use ppc64 ; then
export RUST_TARGET="powerpc64le-unknown-linux-musl"
elif use riscv ; then
@@ -831,7 +835,7 @@ src_configure() {
# amd64, arm, arm64 & x86.
# Might want to flip the logic around if Firefox is to support more arches.
# bug 833001, bug 903411#c8
- if use ppc64 || use riscv; then
+ if use loong || use ppc64 || use riscv; then
mozconfig_add_options_ac '' --disable-sandbox
elif use valgrind; then
mozconfig_add_options_ac 'valgrind requirement' --disable-sandbox
@@ -1030,8 +1034,8 @@ src_configure() {
else
mozconfig_add_options_ac 'relr elf-hack' --enable-elf-hack=relr
fi
- elif use ppc64 || use riscv ; then
- # '--disable-elf-hack' is not recognized on ppc64/riscv,
+ elif use loong || use ppc64 || use riscv ; then
+ # '--disable-elf-hack' is not recognized on loong/ppc64/riscv,
# see bgo #917049, #930046
:;
else