We are delighted to announce the availability of Vcpkg on GitHub https://github.com/Microsoft/vcpkg . Vcpkg simplifies acquiring and building open source libraries on Windows.
Acquiring native libraries on Windows is a critical part of the application development process; in our surveys, you told us that 80% of your C++ projects depend on two or more libraries. Despite this, we’ve heard that the current process for acquiring native libraries falls below C++ developers’ expectations when compared to other platforms such as Mac (Homebrew) and Linux (apt-get, yum, etc.)
After examining successes across all platforms, we’ve created Vcpkg with these set of principles:
- Open-source tools
- No installation needed
- Repeatable builds, from source
- Customizable builds
- Open to contributions from community
- Ports collection approach
We created a document that goes into more details on these topics.
Getting Started
Prerequisites:
- Visual Studio 2015
- Windows 7 (or up)
To acquire the tool:
- Clone from GitHub:
git clone https://github.com/Microsoft/vcpkg
- Run the bootstrap script in the vcpkg folder:
powershell -exec bypass scripts\bootstrap.ps1
- Now vcpkg.exe is in the root of the repository
You are now all set (no installation, no registry… the tool and the associated “lib folder” are xcopy-able)
List of libraries
To see the list of available libraries, use vcpkg search
:
boost | 1.60 | Peer-reviewed portable C++ source libraries |
cpprestsdk | 2.8 | C++11 JSON, REST, and OAuth library The C++ RES… |
curl | 7.48.0 | A library for transferring data with URLs |
expat | 2.1.1 | XML parser library written in C |
freetype | 2.6.3 | A library to render fonts. |
glew | 1.13.0 | The OpenGL Extension Wrangler Library (GLEW) is a… |
glfw3 | 3.1.2 | GLFW is a free, Open Source, multi-platform libra… |
libjpeg-turbo | 1.4.90-1 | libjpeg-turbo is a JPEG image codec that uses SIM… |
libpng | 1.6.24-1 | libpng is a library implementing an interface for… |
libuv | 1.9.1 | libuv is a multi-platform support library with a … |
libwebsockets | 2.0.0 | Libwebsockets is a lightweight pure C library bui… |
mpg123 | 1.23.3 | mpg123 is a real time MPEG 1.0/2.0/2.5 audio play… |
openal-soft | 1.17.2 | OpenAL Soft is an LGPL-licensed, cross-platform, … |
opencv | 3.1.0 | computer vision library |
opengl | 10.0.10240.0 | Open Graphics Library (OpenGL)[3][4][5] is a cros… |
openssl | 1.0.2h | OpenSSL is an open source project that provides a… |
range-v3 | 0.0.0-1 | Range library for C++11/14/17. |
rapidjson | 1.0.2-1 | A fast JSON parser/generator for C++ with both SA… |
sdl2 | 2.0.4 | Simple DirectMedia Layer is a cross-platform deve… |
sqlite3 | 3120200 | SQLite is a software library that implements a se… |
tiff | 4.0.6 | A library that supports the manipulation of TIFF … |
tinyxml2 | 3.0.0 | A simple, small, efficient, C++ XML parser |
zlib | 1.2.8 | A compression library |
This is just the beginning; we’ll accept contributions for new libraries, updates and improvements. See example 2 in examples.md on how to create your own port file in the catalog.
Use Vcpkg with your projects
The easiest way to use Vcpkg from Visual Studio is through the user-wide integration, making the system available to all VS projects you build.
vcpkg integrate install
This will require administrator access the first time it is used on a given machine. After the first use, administrator access is no longer required and the integration is on a per-user basis.
In addition to the VS integration, Vcpkg also supports CMake and other build systems. For more information, see docs/EXAMPLES.md.
We want to hear from you!
This tool is now available for you to try. Please share your feedback and suggestions! The best place to provide them is in the GitHub repo: create new issues or vote on existing ones. We would love to accept pull requests for more open-source libraries — see docs/CONTRIBUTING.md.
You can also contact us at vcpkg@microsoft.com
Repo doesn’t seem to exist
github repo: page not found?
404s all the way… Did you pull it or not actually publish yet?
There was a hiccup in the publishing! Please try again — the repository should be live now.
A slight bit rushed out the door ?
1. powershell -exec bypass scripts\bootstrap.ps
– Incorrect filename, it’s .ps1 as noted in the README as well
2. Download the binary distribution, containing the exe here and unzip it in the folder of your choice.
– The release does not have a pre-compiled binary
3. The bootstrap.ps1 is somewhat janky on line 7. Not sure what version of PS you were targetting.
4. Release\vcpkg.exe search returns zero items
Hello Christian,
Thanks for pointing out these issues!
– Modified the “Getting It Started” section. Removed the pre-compiled binary; currently you need to build vcpkg.exe from source.
To do so, please run scripts\bootstrap.ps1 (fixed the filename typo)
– Replaced line 7 of bootstrap.ps1 with older-powershell-friendly code. It should work in the powershell versions found in Win7+ now.
Great stuff! Don’t see the integration/sysroot.cmake file in my install, though…
For libraries that expose a C++ API (like OpenCV and Boost) – any plans on how you’ll support multiple compiler versions (and thus ABIs)? 2015 won’t be king forever (and some haven’t migrated…)
Ah, I see in the docs that integration\sysroot.cmake has been replaced by scripts\buildsystems\vcpkg.cmake (or an incomplete vice-versa?)