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
wireguard-go: fix executable name #88610
Conversation
Why is it not already named like this by the upstream build system? Or is this a convention made up by us?
|
Ah, I see - it's documented in #88567. In that case, please add an explanation to the commit message, so people can see why this happened just by looking at the git history. |
It's supposed to be `wireguard-go` instead of `wireguard`. Upstream does this right in their Makefile, however we use our own build-script which creates a wrong file in $out, so it has to be fixed in the `postInstall`-hook. Closes NixOS#88567
@flokli fixed. |
@flokli can you also take care of the backport? :) |
Ported to stable as 88b9351. |
Huh, didn't get to this before now, but we should probably add the alias for 20.03 to be extra safe of not breaking someones own script in a stable release ;-) |
Fair enough. Done in 404041b. |
More realistically, I kind of doubt anybody uses wireguard-go on Nix. The person who added this package originally disappeared immediately after. |
That commit does not look good. Now the binary is called wireguard but you have a symlink for the real name? That's bonkers. Call it wireguard-go, get rid of the binary called wireguard, and call it a day. |
@zx2c4 please note that this is only on |
There are people who use Nix and wireguard on operating systems other than Linux (e.g. macOS). |
I filed this ticket because I needed wireguard-tools from Nix on macOS, which relies on wireguard-go. |
The official However if you are after some terminal-based or plaintext-configuration-based solution, then, I think, getting LnL7/nix-darwin#79 to work is the coolest option. IIUC when I was working on it, I got stuck at the route management part, and I didn’t like how it was implemented in the Wireguard upstream script either, so I was trying to come up with an alternative solution and then gave up, because the .app appeared. Now I think the best option would be to actually use the proper VPN api of the OS (as the WireGuard.app does), I am just not sure how to easily hook nix-darwin to it. |
I’m using a script set up by my company that relies on I’m also pushing for my team to adopt Nix for other reasons, and I think requiring nix-darwin is too high of a burden for that. Of course the rest of my team is free to still use Homebrew as well, so they could just get wireguard-tools from that; I refuse to use Homebrew for personal reasons. |
Motivation for this change
It's supposed to be
wireguard-go
instead ofwireguard
.Closes #88567
Things done
sandbox
innix.conf
on non-NixOS linux)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)