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

Search for compilerPath in the PATH environment variable #5908

Closed
bobbrow opened this issue Aug 5, 2020 · 4 comments
Closed

Search for compilerPath in the PATH environment variable #5908

bobbrow opened this issue Aug 5, 2020 · 4 comments
Assignees
Labels
Feature Request fixed Check the Milestone for the release in which the fix is or will be available. Language Service quick fix
Milestone

Comments

@bobbrow
Copy link
Member

bobbrow commented Aug 5, 2020

A customer suggested this feature in an extension review. If compilerPath is not an absolute path to a compiler, we could see if it is in the PATH and determine the absolute path ourselves.

@robokamran
Copy link

Thank you for creating this issue 🙏🏻 many other VSCODE extensions that work with CPPTools have a problem with this and cannot create independent extensions. e.g. take a look at here
I believe it could be better that all paths in the json config have access to the PATH environment variable.

@Colengms
Copy link
Contributor

@bobbrow Should the env path also be checked for a default compiler? That may have an impact on launch time, as checking for N different names in path could be slow for some users.

@bobbrow
Copy link
Member Author

bobbrow commented Aug 14, 2020

We already check the env path during the search for default compilers on linux/mac. This issue is just about resolving compilerPath in c_cpp_properties.json so that if you put 'g++' in there, we call 'which' on it and get the absolute path before sending the configuration across to the language server.

@Colengms Colengms added the fixed Check the Milestone for the release in which the fix is or will be available. label Aug 15, 2020
@sean-mcmanus
Copy link
Contributor

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Feature Request fixed Check the Milestone for the release in which the fix is or will be available. Language Service quick fix
Projects
None yet
Development

No branches or pull requests

4 participants