Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.

Bug 1083762

Summary: Add ppc64le support to Firefox
Product: [Fedora] Fedora Reporter: Gustavo Luiz Duarte <gustavold>
Component: firefoxAssignee: Jan Horak <jhorak>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: gecko-bugs-nobody, gustavold, jhorak, stransky
Target Milestone: ---   
Target Release: ---   
Hardware: ppc64le   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-05-06 07:47:26 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On:    
Bug Blocks: 1051573    
Attachments:
Description Flags
Part1: Toplevel build/config
none
Part 2: Javascript build/config
none
Part 3: libffi backport
none
Part 4: xptcall port
none
Part 5: webrtc config support
none
Part 6: mfbt config support none

Description Gustavo Luiz Duarte 2014-04-02 22:12:13 UTC
The new little-endian 64-bit PowerPC platform (powerpc64le-linux) is not currently supported by Firefox.  The following is required to have ppc64le support on Firefox:

1. Toplevel build/config support
2. Javascript build/config support
3. js/src/ctypes - libffi backport
4. xptcall port
5. webrtc config support
6. mfbt config support

Ulrich Weigand has implemented that and posted his work on the following bz:
https://bugzilla.mozilla.org/show_bug.cgi?id=976648

Considering Ulrich's patches have been merged into mozilla-central, can we please add those patches to Rawhide?

I will attach Ulrich's patches backported to Rawhide (firefox-28) shortly.

Comment 1 Gustavo Luiz Duarte 2014-04-02 22:21:09 UTC
Created attachment 882023 [details]
Part1: Toplevel build/config

Comment 2 Gustavo Luiz Duarte 2014-04-02 22:22:02 UTC
Created attachment 882024 [details]
Part 2: Javascript build/config

Comment 3 Gustavo Luiz Duarte 2014-04-02 22:23:00 UTC
Created attachment 882026 [details]
Part 3: libffi backport

Comment 4 Gustavo Luiz Duarte 2014-04-02 22:23:53 UTC
Created attachment 882027 [details]
Part 4: xptcall port

Comment 5 Gustavo Luiz Duarte 2014-04-02 22:25:01 UTC
Created attachment 882028 [details]
Part 5: webrtc config support

Comment 6 Gustavo Luiz Duarte 2014-04-02 22:25:37 UTC
Created attachment 882029 [details]
Part 6: mfbt config support

Comment 7 Gustavo Luiz Duarte 2014-04-02 22:37:43 UTC
Please also consider the following change to the spec file:

@@ -378,7 +396,7 @@ export LIBDIR='%{_libdir}'
 MOZ_SMP_FLAGS=-j1
 # On x86 architectures, Mozilla can build up to 4 jobs at once in parallel,
 # however builds tend to fail on other arches when building in parallel.
-%ifarch %{ix86} x86_64 ppc ppc64
+%ifarch %{ix86} x86_64 ppc ppc64 ppc64le
 [ -z "$RPM_BUILD_NCPUS" ] && \
      RPM_BUILD_NCPUS="`/usr/bin/getconf _NPROCESSORS_ONLN`"
 [ "$RPM_BUILD_NCPUS" -ge 2 ] && MOZ_SMP_FLAGS=-j2

Comment 8 Jan Horak 2014-04-03 14:12:00 UTC
This is a big patch, we'd better wait for Firefox 30 which is to be released in ~10 weeks to avoid need for patch rebase to FF 28 unless we find it an urgent matter.

However keeping open because of comment 7.

Comment 9 Gustavo Luiz Duarte 2014-04-03 15:58:58 UTC
Jan, could we at least have these patches conditionally applied only on ppc64le?

With the ppc64le bring up in progress, Firefox is becoming more and more a central package to have. Waiting 10 weeks for firefox is far from optimal from that point of view.

Considering these patches have been merged upstream, we know for sure they will not accumulate forever and we will be able to drop them in ~10 weeks when we get firefox-30 in rawhide.

Comment 10 Martin Stransky 2014-04-03 19:36:04 UTC
I think the conditional apply to ppc64le is okay. If the change is too intrusive we can also ship this one as unbranded version for testing purpose.

Comment 11 Gustavo Luiz Duarte 2014-04-03 20:43:57 UTC
FWIW, I've personally tested Firefox-28 + patches on Rawhide ppc64le and it works fine (with a few color and font glitches that may or may not be a firefox issue). If you have a koji build, let me know and I'd be happy to test that too.

Comment 12 Jan Horak 2014-05-06 07:46:55 UTC
Thanks for the patches, should be part of firefox-29.0-5.fc21 build.