Opened 4 years ago

Closed 4 years ago

#15990 closed task (fixed)

Get Windows cross-compilation working with Fx38 in Gitian

Reported by: gk Owned by: tbb-team
Priority: Medium Milestone:
Component: Applications/Tor Browser Version:
Severity: Keywords: tbb-gitian, ff38-esr, TorBrowserTeam201506R, tbb-5.0a3-essential
Cc: boklm, mcs Actual Points:
Parent ID: #15772 Points:
Reviewer: Sponsor:

Description

Unsurprisingly, there are again issues when trying to compile Fx38 for Windows using our current toolchain. This bug is tracking them and the fixes.

Child Tickets

Change History (19)

comment:1 Changed 4 years ago by gk

We need to disable the sandbox code as it currently can't be compiled with mingw-w64 (adding ac_add_options --disable-sandbox to our .mozconfic-mingw). See: https://bugzilla.mozilla.org/show_bug.cgi?id=1042426 for further details.

Especially problematic are the SEH bits. According to Jacek that was not implemented in GCC for years due to patent issues. The patent expired but now it needs someone to code that up for GCC.

comment:2 Changed 4 years ago by boklm

Cc: boklm added

comment:3 Changed 4 years ago by gk

We are running into https://bugzilla.mozilla.org/show_bug.cgi?id=1126724 as well but that is due to needed changes in mingw-w64 itself which the old revision we use for 4.5 does not have yet. Building mingw-w64 from commit 7268caece9b4cb33ff698306e51140b11d7656b0 fixes that one.

comment:4 Changed 4 years ago by mcs

Cc: mcs added

comment:5 Changed 4 years ago by gk

We need as well https://hg.mozilla.org/mozilla-central/rev/e37165f9b5fe which did not make it into ESR 38.

comment:6 Changed 4 years ago by gk

Additionally, we need https://hg.mozilla.org/mozilla-central/rev/824009fbc42f (fixed in 1138967). Then it turns out the mingw-w64 revision in comment:3 is still not recent enough, we need e4a8812d72529fbaf168e50725b0ae6bf9951d23 due to bug 1092634.

comment:7 Changed 4 years ago by gk

We need to bump the mingw-w64 commit we use again. Now we are at a883b47a45ff74ced41dfbd9f748d5c2c61f3c01 due to bug 1156131.

Last edited 4 years ago by gk (previous) (diff)

comment:8 Changed 4 years ago by gk

Okay, the last hurdle is that ESR 38 needs GCC >= 4.7.0 as the host compiler but Ubuntu Precise ships only 4.6.3 which breaks our build. We could patch Firefox to take 4.6.3 as minimum (this works) but it seems too risky to me as ESR bugfix releases might break this fragile solution easily.

I think we should bite the bullet and compile GCC for precise as well (the one for lucid does not work due to library incompatibilities) and use it then for the host compiler part. I tested that and it works.

That's all (surprisingly) and I'll add the final patches/links to them (after the updater patches are ready) to this bug.

comment:9 Changed 4 years ago by gk

The Gitian changes are attached, too. They need the fix for #16150 applied before.

comment:10 Changed 4 years ago by gk

Keywords: TorBrowserTeam201506R added
Status: newneeds_review

comment:11 Changed 4 years ago by mcs

Kathy and I reviewed all of the above patches as best we could. The changes look good to us.

comment:12 Changed 4 years ago by mikeperry

Keywords: tbb-5.0a3-essential added

Tag the set of things we should aim to understand/fix for the fist FF38-based TBB (5.0a3, on June 30th).

comment:13 Changed 4 years ago by arthuredelstein

For the record, some days back I applied the four tor-browser.git patches above to https://github.com/arthuredelstein/tor-browser/commits/tb_GECKO380esr_2015050513_RELBRANCH%2B1

I think the tor-browser-bundle.git patch may still need to be applied.

comment:14 in reply to:  13 Changed 4 years ago by gk

Resolution: fixed
Status: needs_reviewclosed

Replying to arthuredelstein:

I think the tor-browser-bundle.git patch may still need to be applied.

Yes, done with commit d0bc63e7d7a1149c8faf336190d7a771eb46c234.

Note: See TracTickets for help on using tickets.