microsoft / microsoft/vcpkg

Python2 port is missing git information and uses the wrong platform toolset

Open
#6,005 1 comment 0 reactions 1 assignee Claimed by @PhoebeHui View on GitHub
category:port-bug
Dominant language
CMake
Stars
27.5k
Forks
7.7k
Avg merge
2d 19h
Merged PRs (30d)
321

Description

When installing the python2 port, a few calls to `git` are made within the build:

```
git name-rev --name-only HEAD
git rev-parse --short HEAD
git describe --all --always --dirty
```

Since the port is downloaded as a zip file without additional git information (concretely, the `.git` directory), `git` will start traversing directories up in the tree looking for `.git`. In an environment with restricted access, this will hit `vcpkg`'s `.git` and attempt to write the `index.lock`, leading to a restricted write.

It also attempts to build using `PLATFORM_TOOLSET` set to the default of `VCPKG_PLATFORM_TOOLSET`, which could be `v141`. The officially supported value is `v140`.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.