microsoft / microsoft/vscode-cmake-tools

Linux: Add support for snaps of CMake

Open
#838 24 comments 25 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement Feature: configure
Dominant language
TypeScript
Stars
1.7k
Forks
546
Avg merge
2d 16h
Merged PRs (30d)
32

Description

I have just installed Ubuntu 19.10 and used the Software installer application to install Visual Studio Code and CMake 3.15. I cloned my repository from GitHub and whenever I try to call CMake configure in Visual Studio code I get an error message: Bad CMake executable `/snap/bin/cmake`. CMake seems to run fine in a terminal.

VS Code/CMake extension used to run just fine out-of-the-box in previous version of Ubuntu.

When I try to enter the path manually I get error messages like these:

> [rollbar] Unhandled exception: Unhandled Promise rejection: configure TypeError: Cannot read property 'on' of undefined {}
> [rollbar] Unhandled exception: Error during CMake upgrade TypeError: Cannot read property 'on' of undefined {"version":"3.13.2","linuxURL":"https://github.com/Kitware/CMake/releases/download/v3.13.2/cmake-3.13.2-Linux-x86_64.sh","windowsURL":"https://github.com/Kitware/CMake/releases/download/v3.13.2/cmake-3.13.2-win64-x64.msi"}

Actually `/snap/bin/cmake` is not an executable but a link if I recall correctly.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the configure and CMake upgrade paths in the VS Code/CMake extension on Ubuntu with `/snap/bin/cmake`, noting that it is a link rather than a regular executable. Trace how the extension validates and invokes that path; done means snap-installed CMake configures successfully without the reported errors.

Written by the indexing model from the issue text.

Assessment

Tech stack
cmake, typescript, ubuntu, vscode
Domain
build-system, devtools, operating-systems
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.