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

auto-attach.sh and usbip not always available in the same directory #1071

Open
Rasmus-Bertell opened this issue Nov 25, 2024 · 0 comments
Open

Comments

@Rasmus-Bertell
Copy link

Rasmus-Bertell commented Nov 25, 2024

auto-attach.sh assumes that ./usbip is always available in the same directory as itself which might not be true in more exotic distributions, leading to errors like nix-community/NixOS-WSL#594.

# Use our distribution-independent build of usbip, which resides in the same directory as this very script.
# NOTE: The working directory should have been set to the location of this script.
LAST_ERROR=$(./usbip attach --remote="$HOST" --busid="$BUSID" 2>&1) || return 1

For context, my paths for auto-attach.sh and usbip are the following.

usbip:          /nix/store/ha3qmkizpjxxd645s4n4j8jbbxhyfj96-usbip-linux-6.6.62/bin/usbip
auto-attach.sh: /nix/store/nll5ayjp1474ax1pyq3qf52arn438dn8-auto-attach.sh
@Rasmus-Bertell Rasmus-Bertell changed the title usbip not always available in the same folder auto-attach.sh and usbip not always available in the same directory Nov 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant