Skip to content

gnvim: fix install phase with Rust with custom target#115267

Merged
teto merged 1 commit intoNixOS:masterfrom
minijackson:fix-gnvim-with-target
Mar 6, 2021
Merged

gnvim: fix install phase with Rust with custom target#115267
teto merged 1 commit intoNixOS:masterfrom
minijackson:fix-gnvim-with-target

Conversation

@minijackson
Copy link
Member

Motivation for this change

When building with cargo build --release --target <arch> ..., Rust installs the gnvim binary in ./taget/<arch>/release instead of ./target/release, which isn't taken into account by upstream's Makefile.

Normally, the project would have been compiled by using make build, but if I understood it correctly, the buildPhase is now overridden by the new hook system (#112804)

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • 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 nixpkgs-review --run "nixpkgs-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)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

@minijackson minijackson requested a review from teto as a code owner March 6, 2021 16:24
@ofborg ofborg bot added 11.by: package-maintainer This PR was created by a maintainer of all the package it changes. 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. labels Mar 6, 2021
@r-rmcgibbo
Copy link

Result of nixpkgs-review pr 115267 at ec5fb3c run on x86_64-linux 1

2 packages failed to build:

@minijackson
Copy link
Member Author

@ofborg build gnvim

@teto
Copy link
Member

teto commented Mar 6, 2021

$ git worktree add /home/teto/.cache/nixpkgs-review/pr-115267/nixpkgs 7d15e227cf3b30cddd083370814b8d1a2f05ed49
Preparing worktree (detached HEAD 7d15e227cf3)
Updating files: 100% (24774/24774), done.
HEAD is now at 7d15e227cf3 Merge pull request #115232 from xantoz/nyxt-more-platforms
$ git merge --no-commit ec5fb3cce8c8827575a1f2315e3a43b5be55d23c
Automatic merge went well; stopped before committing as requested
$ nix --experimental-features nix-command build --no-link --keep-going --option build-use-sandbox relaxed -f /home/teto/.cache/nixpkgs-review/pr-115267/build.nix

Link to currently reviewing PR:
https://github.com/NixOS/nixpkgs/pull/115267

2 packages built:
gnvim gnvim-unwrapped

it took a while but build passes locally. Binary works.

@teto teto merged commit de6283b into NixOS:master Mar 6, 2021
@minijackson minijackson deleted the fix-gnvim-with-target branch March 7, 2021 15:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 11.by: package-maintainer This PR was created by a maintainer of all the package it changes.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants