Respect LD_LIBRARY_PATH when forking on Linux#545
Merged
Conversation
code-asher
requested changes
Apr 22, 2019
Member
There was a problem hiding this comment.
Ahh, interesting, normally when something forks we preserve the environment: https://github.com/codercom/code-server/blob/5f40ebb8457380aa1e9955302d9e41a6b042ef14/packages/protocol/src/node/modules/child_process.ts#L86
But, since the shared process is forked directly it doesn't get the environment preserved. I think it might make sense to edit: https://github.com/codercom/code-server/blob/5f40ebb8457380aa1e9955302d9e41a6b042ef14/packages/server/src/vscode/sharedProcess.ts#L91
Then import preserveEnv from @coder/protocol and call it there before forking the shared process.
a28784b to
79f8fd1
Compare
79f8fd1 to
5149ad1
Compare
Contributor
Author
|
Updated the PR to use |
andreimc
added a commit
to devonlineco/code-server
that referenced
this pull request
May 14, 2019
* upstream/master: (68 commits) Fix docker oneliner in README.md Fix macOS release Rename codercom/code-server to cdr/code-server Expose Terminal Service in API Make preserveEnv return a new object Preserve environment when forking shared process (coder#545) codercom -> cdr Package only on darwin Include version with target env Add docker service Add support for musl and centos Remove reveal in finder/explorer option from the context menu (coder#586) Fix open dialog crash when there is a broken link Only output password if it was generated Fix full screen detection for Chromium Fix toggling full screen Improve size column in dialogs Fix typo DigitalOcean (coder#595) Fix coder#587 (coder#588) Fix protocol fs test ...
code-asher
pushed a commit
that referenced
this pull request
Jun 19, 2019
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Describe in detail the problem you had and how this PR fixes it
Currently there is no easy way to run
code-serverif disto's "stock"libstdc++package is too old becausecode-serverdoes not respectLD_LIBRARY_PATHon Linux.Even if I set
LD_LIBRARY_PATHI get this error:In some environments there is newer
libstdc++available that isn't installed to default location. This Pull Request makes it possible to use customlibstdc++.Is there an open issue you can link to?
#347
#239