Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

firefox: Fixes build with rust 1.33 #57175

Closed
wants to merge 1 commit into from

Conversation

bkchr
Copy link
Contributor

@bkchr bkchr commented Mar 9, 2019

Motivation for this change
Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Assured whether relevant documentation is up to date
  • Fits CONTRIBUTING.md.

Copy link
Member

@andir andir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for looking into this. 👍

The changes do not quiet work out for all our flavors. I left a few comments with ideas.

For demonstration purposes:
@GrahamcOfBorg build firefox-esr-60

@@ -92,6 +92,15 @@ let

browserPatches = [
./env_var_for_system_dir.patch
(fetchpatch {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do not think that these belong here. They do not apply to say firefox-esr-60. We are building a lot of different FireFox flavors from the same common expressions. The tor browsers also use this expression.

There is two ways I could see this work:

  • Find a generic solution that works on "all" the flavors.
  • Use a patch specific to the flavor. E.g. pull from the ESR repo when building the ESR version(s) etc..

I prefer the 2nd approach as that will allow us to remove that from specific versions without triggering rebuilds of all the others.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there already an example for doing this?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

url = "https://hg.mozilla.org/mozilla-central/raw-rev/4f2e84dc490d";
sha256 = "18ba9riwplchii60664j2shydb19s2gyd3jldr1225bqj3wky521";
})
./fix-build-with-rust-1.33.patch
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there some source we could fetch the patch from or did you write it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I needed to adapt this patch, because the original did not apply.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All fine with me. I'd just drop a line where it originally came from in case we have to follow up on that in the future.

@bkchr bkchr force-pushed the firefox_fix_build_rust_1_33 branch from cff3ab7 to 42e99eb Compare March 10, 2019 20:08
@bkchr
Copy link
Contributor Author

bkchr commented Mar 10, 2019

@andir added the requested changes.

@andir
Copy link
Member

andir commented Mar 11, 2019

@GrahamcOfBorg build firefox-esr-60

@bkchr
Copy link
Contributor Author

bkchr commented Mar 11, 2019

@andir I think building firefox on CI takes a little bit too much time^^

@andir
Copy link
Member

andir commented Mar 11, 2019

Well the point was that the ESR release probably still fails to build with the bumped rustc. I did not expect so many intermediate packages to still be built. That is also what I was trying to hint to in my previous comments. We can not just apply that patch for firefox but also firefox-esr-60 will need some mangling with the build pieces (until Mozilla releases a version that is fixed).

@bkchr
Copy link
Contributor Author

bkchr commented Mar 14, 2019

@andir https://www.mozilla.org/firefox/60.6.0/ does this version maybe fix the build for esr?

@andir
Copy link
Member

andir commented Mar 14, 2019

I am trying to figure that out by building https://hg.mozilla.org/mozilla-unified/rev/FIREFOX_60_6_0esr_BUILD2 on top of the current staging branch. Will report back once I have results.

@andir
Copy link
Member

andir commented Mar 15, 2019

@bkchr they did not include the rust fixes in the 60.6 release I tried. The patch seems to be compatible if we remove/adjust a bit of the context. I'll try to work on that in the next day if you do not beat me to it :-)

@Ekleog
Copy link
Member

Ekleog commented Sep 10, 2019

(triage) Firefox ESR 60's latest version appears to be 60.9.0.

Does this version fix the issue? If not, what command line can show the problem? (nix-build . -A firefox-esr-60 appears to pass here)

@bkchr
Copy link
Contributor Author

bkchr commented Sep 10, 2019

This pr is probably outdated and can be closed. @Ekleog what is the problem you see?

@bkchr bkchr closed this Sep 10, 2019
@bkchr bkchr deleted the firefox_fix_build_rust_1_33 branch September 10, 2019 06:04
@Ekleog
Copy link
Member

Ekleog commented Sep 10, 2019

@bkchr I haven't been able to reproduce any issue, but didn't want to close the PR without certainty as I didn't know how to reproduce the initial issue either -- all good to close for me :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants