This guide provides detailed instructions for setting up MeshLib for C++ development across Windows, Linux, and macOS. It covers all prerequisites as well as specific setup steps for each platform.
Git
Install Git to manage repositories and submodules, which is also required to install vcpkg.
Visual Studio 2019 or 2022
Download and install either Visual Studio 2019 or 2022. During installation, make sure to:
vcpkg).CUDA Toolkit
Choose the appropriate version based on your Visual Studio installation.
vcpkg
vcpkg, follow these steps:
Open a command prompt (CMD) or PowerShell window.
Navigate to a directory where you want to install vcpkg:
cd C:\path\to\your\desired\directory
Clone the vcpkg repository:
git clone <https://github.com/microsoft/vcpkg.git>
Navigate to the vcpkg directory:
cd vcpkg
git checkout 2024.07.12
Run the bootstrap script to build the vcpkg executable:
.\bootstrap-vcpkg.bat
Integrate vcpkg with Visual Studio (requires Administrator access):
.\vcpkg integrate install
Note: The following steps will require approximately 40 GB of disk space.
Clone the MeshLib Repository:
git clone <https://github.com/MeshInspector/MeshLib.git>
cd MeshLib
git submodule update --init --recursive
(Optional) Speed Up with AWS CLI
Install MeshLib Third-Party Dependencies
Execute the following commands to run the MeshLib third-party installation script:
cd vcpkg
../MeshLib/thirdparty/install.bat
This script automates the installation of necessary third-party dependencies.
Build and Run:
MeshLib/source/MeshLib.sln in Visual Studio.1. Download and Extract the Built Version
Visit the MeshLib GitHub Releases.
Download the latest Windows built version archive (E.g. MeshLibDist_v3.0.0.40.zip).
Extract it to a directory, e.g., C:\meshlib-built\.
Directory Structure After Extraction
install/
├── include/ # Header files
├── lib/ # Static and shared libraries
├── bin/ # Executables