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
vim: Fix install phase parallelism and harden against future failures #227677
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, but the build is failing for me with:
if test -d /nix/store/3aip4s6qj3v0bkvp7p37g84n4iyan4r2-vim-9.0.1441/share/icons/locolor/16x16/apps -a -w /nix/store/3aip4s6qj3v0bkvp7p37g84n4iyan4r2-vim-9.0.1441/share/icons/locolor/16x16/apps \
-a ! -f /nix/store/3aip4s6qj3v0bkvp7p37g84n4iyan4r2-vim-9.0.1441/share/icons/locolor/16x16/apps/gvim.png; then \
cp ../runtime/vim16x16.png /nix/store/3aip4s6qj3v0bkvp7p37g84n4iyan4r2-vim-9.0.1441/share/icons/locolor/16x16/apps/gvim.png; \
fi
if test -d /nix/store/3aip4s6qj3v0bkvp7p37g84n4iyan4r2-vim-9.0.1441/share/applications -a -w /nix/store/3aip4s6qj3v0bkvp7p37g84n4iyan4r2-vim-9.0.1441/share/applications; then \
if test -f po/vim.desktop -a -f po/gvim.desktop; then \
cp po/vim.desktop po/gvim.desktop \
/nix/store/3aip4s6qj3v0bkvp7p37g84n4iyan4r2-vim-9.0.1441/share/applications; \
else \
cp ../runtime/vim.desktop \
../runtime/gvim.desktop \
/nix/store/3aip4s6qj3v0bkvp7p37g84n4iyan4r2-vim-9.0.1441/share/applications; \
fi; \
if test -z "" -a -x ""; then \
-q /nix/store/3aip4s6qj3v0bkvp7p37g84n4iyan4r2-vim-9.0.1441/share/applications; \
fi \
fi
make[1]: Leaving directory '/build/source/src'
/nix/store/5s1yg5l36wzgy1dj0vv1ibarc4g7vrdr-stdenv-linux/setup: eval: line 131: syntax error: unexpected end of file
| @@ -50,6 +50,15 @@ stdenv.mkDerivation { | |||
| ln -s $out/bin/vim $out/bin/vi | |||
| mkdir -p $out/share/vim | |||
| cp "${vimrc}" $out/share/vim/vimrc | |||
|
|
|||
| # Prevent bugs in the upstream makefile from silently failing and missing outputs. | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are those bugs in an upstream issue tracker somewhere? Could we link to that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If so I'd also link from common.nix in line 13
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
d8b0e57
to
16d9773
Compare
Those tools are often used as build-time dependency. Some deficiencies in the upstream makefiles makes it possible that they will not be installed, even though the `make install` call was successful. This *could* make the `vim` build fail where it wouldn't have failed previously, but it will now fail in a correct manner instead of being incorrectly successful. The previous patch (actually using -j1 in install phase) should make this change redundant, but let's not pretend new bugs are never going to happen!
16d9773
to
15ebfa7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change looks good (and the branch now builds for me).
However, since AFAICS this is not fixing a regression on staging (but a problem on master), it should be targeting staging rather than staging-next, right? (https://nixos.org/manual/nixpkgs/unstable/#submitting-changes-commit-policy)
|
I'm not 100% sure. Right now there may be issues with some configurations when I'm leaving the decision of staging vs. staging-next to the peeps actually managing staging/-next. |
Description of changes
exdependency missing fromVimpackage makesfoo2zjsinstallation fail #227660Our current build of
vimhas a not-exactly-reproducible issue where some tools may not end-up being installed. Those tools are used as build-time dependencies in other packages.— https://hydra.nixos.org/build/215173431/nixlog/1
There are two changes in this PR:
When attempting to reproduce the issue, I had to use this, or else on my
-j16system issues wouldn't reproduce.Obviously(?), to test the last commit, you should probably revert the first commit of this PR. Note that it may or may not fail on your specific system due to racing and timing.
There is also an upstream fix sent for two observed parallelism bugs, but since it looks like there could be at least another one, let's keep installing without parallelism.
Things done
sandbox = trueset innix.conf? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/)