It will also set it up for compilation using a 圆4 processor set up and compile it for windows. This will instruct vcpkg to search for raylib and download it. vcpkg/vcpkg.exe install raylib:圆4-windows To install a library for use with cmake you would then need to run the following command from the root of your project: >. I will use the raylib project as an example. If you are using git you can do the following command: git clone -b "2020.11" Install a package Note: When downloading vcpkg make sure to use a stable version of vcpkg by going to tags and selecting a corresponding tag commit. This would install everything needed for us to start doing package management for C++ on the current project. Then extract it relative to the project in a folder called “vcpkg” so that we produce the following structure.įollowing the instructions in the vcpkg github repository then we would need to execute this command from the root of our project: >. To start you can download vcpkg from its github repository here. Sounds like magic so lets begin! Install VCPKG The vcpkg tool will download C++ code compile it into libraries and will take care to copy the needed file to our end directory when we build our project. It nicely integrates when used directly for Visual C++ development (without CMake) and could as easily be integrated into a CMake project. My choice when doing package management for C++ is VCPKG which is an open-source tool created by Microsoft. Start from this post that explains the basics of C++. You can start from this post that explains the basics of cmake To completely understand the contents of this article you should know: If you like this content consider checking out my course on CMake where I cover this and much more. When creating games for example raylib is a nice library that adds a lot of coding functionality that you wouldn’t have to worry about and just use straight on. Package manager would usually download for you some external code that already implements functionality that you want. C++ is an old language and doesn’t have some concepts that the more modern languages have like a package manager. Managing dependencies for C++ has been pretty hard for years.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |