2

I am new to C++ and needed to download a package, so I thought I would use vcpkg. The problem is vcpkg was slower than I expected. Here is my syntax:

vcpkg install <PACKAGE>

Vcpkg takes a lot of time, which makes me wonder if there is a flag to speed up the vcpkg download speed.

xilpex
  • 3,097
  • 2
  • 14
  • 45
  • 1
    There is no flag to speedup the download. – drescherjm Mar 02 '19 at 05:53
  • I don't have a problem with the download speed. Seems fast enough. But installing packages involves referenced libraries and all the source has to be compiled. That takes longer than downloading. But it's a one time thing then it's easily referenceable in your code. – doug Mar 02 '19 at 06:01
  • "*Vcpkg takes a lot of time, which makes me wonder if there is a flag to speed up the vcpkg download speed.*" If there was a flag to speed up download speed... why would you *not* always use it? – Nicol Bolas Jun 02 '19 at 23:06
  • @NicolBolas Well I wouldn't dismiss this question entirely. Perhaps as an example, to enable a multi-connection, downloading multiple packages at once (which people may or may not wish to use). :) (I also understand the poster most likely isn't aware that vcpkg compiles, different than say: conan) – Raid Apr 18 '21 at 21:50

1 Answers1

7

vcpkg does not download pre-built binaries; it downloads source files and does the builds on your machine.

Therefore, it is most likely not the download that is taking up a lot of time, but the build itself. There is no flag that can speed up the builds, but it is possible to export binaries, so you really only have to build a specific set of libraries only once.

If you are interested in why vcpkg chooses to be source-based as opposed to binary-based, you can consult this

jacky la mouette
  • 523
  • 4
  • 17