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

kernel-builder: Work around kernels getting compiled two times #217

Merged

Conversation

@samueldr
Copy link
Member

@samueldr samueldr commented Oct 4, 2020

It looks like this is not a regression from the latest changes to the kernel builder. Testing on top of ffdba8f exhibits the same issue.

This change works around the issue by doing it with one invocation of make, rather than doing it twice.

It has not been figured out at which exact version of the kernel this stops being an issue, and if it is an issue from mainline Linux outright, or something that came from Android-specific modifications.

Though it has been verified that for 3.18, both Qualcomm and Mediatek source trees exhibit the same issue.

Fixes #216


TODO:

  • figure out why it fails for asus-flo
It looks like this is not a regression from the latest changes to the
kernel builder. Testing on top of ffdba8f
exhibits the same issue.

This change works around the issue by doing it with one invocation of
`make`, rather than doing it twice.

It has not been figured out at which exact version of the kernel this
stops being an issue, and if it is an issue from mainline Linux
outright, or something that came from Android-specific modifications.

Though it has been verified that for 3.18, both Qualcomm and Mediatek
source trees exhibit the same issue.

Fixes #216
@samueldr samueldr added the type: bug label Oct 4, 2020
@samueldr
Copy link
Member Author

@samueldr samueldr commented Oct 4, 2020

With asus-flo, maybe other 3.4-based kernels:

With -j12:

mv: cannot stat 'arch/arm/boot/compressed/.misc.o.tmp': No such file or directory

Though disabling this change is enough to make it pass...

+  enableCombiningBuildAndInstallQuirk = false;

Or the following:

+  enableParallelBuilding = false;

Which makes me think this is a parallelism issue that's being brought forward by doing the build all at once. Previously the second build was done without the -j parameter. It is likely that the parallelism issue lies with the install steps only

samueldr added 2 commits Oct 4, 2020
While it builds twice now, it at least build successfully.
Copy link
Contributor

@danielfullmer danielfullmer left a comment

This workaround looks reasonable. I couldn't find any obvious cause of the underlying issue either,

@samueldr samueldr merged commit c2e6b8c into NixOS:master Oct 4, 2020
3 checks passed
3 checks passed
Parse_nix
Details
Documentation
Details
Instantiation
Details
@samueldr samueldr deleted the samueldr-wip:fix/kernel-builder-double-compilation branch Oct 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

2 participants
You can’t perform that action at this time.