På den här sidan

Redigera vcpkg-manifestfiler

När du öppnar en vcpkg.json -fil öppnas den i vcpkg -manifestfilsredigeraren:

Filen vcpkg.json i redigeraren för manifestfiler

Lägg till paket att hantera

Så här lägger du till ett paket i ditt projekt:

  1. Välj Lägg till vcpkg-paketet (Add vcpkg Package) i verktygsfältet i manifestredigeraren.

    Dialogrutan ”Lägg till vcpkg-paket”

  2. Välj det paket som ska läggas till i projektet.
  3. Välj OK för att återgå till redigeraren.
  4. Upprepa för att lägga till fler paket.

Skapa kod för CMake-konfigurationsfiler

Så här genererar du exempelkod för CMake som du kan kopiera till filen CMakeLists.txt:

  1. Välj " CMake-kod " (CMake Code) i verktygsfältet i manifestredigeraren.

    Dialogrutan ”CMake-kod”

  2. Välj den exempelkod du behöver och kopiera och klistra in den i filen CMakeLists.txt.

Ange sökvägen till vcpkg

För att ange sökvägen till den katalog där du har installerat vcpkg väljer du knappen ”Inställningar” (Configure) i redigeringsverktygsfältet.

Se även Konfigurera vcpkg-pakethanteraren och Skapa vcpkg-manifestfiler.

Copyright © The Qt Company Ltd. and other contributors. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.