-
-
Notifications
You must be signed in to change notification settings - Fork 14.5k
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
vscode-extensions.vadimcn.vscode-lldb: fix passthru adapter #264887
Conversation
Result of 1 package failed to build:
|
wrapProgram $out/bin/codelldb \ | ||
--set-default LLDB_DEBUGSERVER_PATH "${lldb.out}/bin/lldb-server" | ||
ln -s ${lldb.lib} $out/lldb | ||
ln -s $out/lib/libcodelldb.so $out/bin/libcodelldb.so |
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.
libs should not be under bin
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.
I've added a comment explaining why codelldb
won't work as a standalone if libcodelldb
isn't symlinked to bin
.
I've tried various other things (like prefixing LD_LIBRARY_PATH
, passing in a flag), but none seem to work.
Do you have any ideas?
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.
Maybe we should put all files under $out/share/codelldb or similar and create a wrapper from that into $out/bin? Then we don't pollute the bin directory with unrelated files.
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.
That appears to work.
@Majiir does this work for you in VSCode?
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.
The plugin fails to build. I think you need to copy only ${adapter}/share/*
instead of ${adapter}/{share,lib}/*
, since there are files with the same name in both.
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.
Thanks - Should be fixed now.
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.
Builds and works in VSCode. 🚀
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.
Thanks for testing!
pkgs/applications/editors/vscode/extensions/vadimcn.vscode-lldb/default.nix
Show resolved
Hide resolved
de36c25
to
66ca0c0
Compare
pkgs/applications/editors/vscode/extensions/vadimcn.vscode-lldb/default.nix
Outdated
Show resolved
Hide resolved
Result of 1 package built:
|
Result of 1 package failed to build:
|
Result of 1 package built:
|
Result of 1 package built:
|
Description of changes
Fixes #160874.
See this comment: #160874 (comment)
To me this feels like a dirty hack, but it seems to work; and I can run
...where before it would complain about missing libraries.
The same hack is applied in the
installPhase
of the VSCode extension. (Maybe there's a cleaner way to do this?)Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)