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

Somewhat saner cross-compiling through bootstrapping #21915

Merged
merged 0 commits into from Jan 24, 2017

Conversation

Ericson2314
Copy link
Member

@Ericson2314 Ericson2314 commented Jan 15, 2017

Motivation for this change

Baby step towards #21268. It's not all the niceness, but it breaks (almost) no hashes of the things we test.

Evaluating release-cross.nix (which evals nixpkgs over and over again) now takes about 25% longer (me counting in my head). But splicing is only done when cross, so most users will be unaffected. In any event, it should be possible to eventually remove the expensive recursive splicing for cheap flat splicing.

I think other than doc, I've gotten everything relevant from the original PR taken care of.

N.B the first commit message has a bunch of info relevant for the whole PR, more or less.

TODO:

  • Add manual section. Most of what follows
Things done

http://hydra.nixos.org/jobset/nixpkgs/sonarpulse-cross-tepid, c.f. http://hydra.nixos.org/jobset/nixpkgs/sonarpulse-cross-compare

CC @shlevy

@mention-bot
Copy link

@Ericson2314, thanks for your PR! By analyzing the history of the files in this pull request, we identified @edolstra, @viric, @vcunat, @LnL7 and @copumpkin to be potential reviewers.

@Ericson2314
Copy link
Member Author

@nbp This first bit isn't even tempted to use overridePackages, so you don't need to worry about a potential conflict with that.

@Ericson2314 Ericson2314 added the 6.topic: cross-compilation Building packages on a different sort platform than than they will be run on label Jan 15, 2017
@Ericson2314 Ericson2314 added this to the 17.03 milestone Jan 15, 2017
@Ericson2314 Ericson2314 changed the title Slightly saner cross-compiling through bootstrapping Somewhat saner cross-compiling through bootstrapping Jan 15, 2017
Copy link
Member

@shlevy shlevy left a comment

Choose a reason for hiding this comment

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

Overall 👍

One question: Why does "libiconv: TEMP force building library improperly for target plat like libc" have "TEMP" in the message?

buildPlatform hostPlatform targetPlatform;
};

# The old identifiers for cross-compiling. These should eventually be removed,
Copy link
Member

Choose a reason for hiding this comment

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

Can you open an issue to track the eventual removal? Perhaps after the next release we can add a deprecation message with builtins.trace

Copy link
Member Author

Choose a reason for hiding this comment

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

Oh I already removed crossSystem (it's just used for picking stdenvs now). I was going to remove stdenv.cross after in a kind of victory lap :).

@Ericson2314
Copy link
Member Author

@shlevy ah yes, I'll make that message less scary looking as it's only temp in the larger scheme of things, not like something that should have been squashed.

Then again, this PR only sets up host vs target but doesn't actually utilize it, so I should indeed check if that commit is necessary.

@Ericson2314
Copy link
Member Author

Hmm, the main non-cross tests fail on the base commit, and this commit—in different ways. Oh our CI...

I guess I'll wait until the channel is bumped. Which honestly isn't so bad as I still gotta write the docs (and probably close some port-the-wiki issues on the process, Yay!)

@Ericson2314 Ericson2314 force-pushed the cross-tepid branch 3 times, most recently from cd257fa to 93e24be Compare January 17, 2017 16:32
@Ericson2314
Copy link
Member Author

OK, got lucky and the channel bumped. But my change from the first commit introduces some sort of infinite loop into the tester (too many recurse from derivations?). I'd love to get a stack overflow with a nix backtrace, but I get neither unfortunately.

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