common_util
Loading...
Searching...
No Matches
1. Software Environment

When compiling this project locally, the following software needs to be installed:

  1. A compiler that supports C++11 and later standards (Visual Studio 2015 or later, GCC 4.8.1 or later, Clang 3.3 or later)
  2. CMake 3.28.3 or later.

1.1. Windows

1.1.1. Download Visual Studio

  1. Download Visual Studio 2015 or later. https://msdn.itellyou.cn/
  2. Install Visual Studio The only thing you need to care about is to choose "Custom" installation and only install the "Visual C++" related modules (if you are only using it for developing C++ projects), otherwise the installation time will be very long.

  3. Test and verify

Create a Console Application project, write some code to print "Hello World". Then compile and run it, if "Hello World" is printed correctly, the installation is successful.

1.1.2. Install CMake

  1. Download CMake 3.28.3 or later. https://cmake.org/download/
  2. Install CMake

    Here are some things to note:

  • Choose "Add CMake to the system PATH" to add CMake to the system environment variables, otherwise you need to add CMake to the PATH environment mannually.

  • t is recommended to customize the installation directory, and the directory name should not contain spaces or special characters, otherwise there may be path-related issues when executing from the command line.

  1. Test and verify

    Open the command line and enter cmake --version , If the version number is displayed correctly, the installation is successful.

1.2. Linux(Ubuntu)

1.2.1. Install GCC Compile

  1. Install GCC 4.8.1
sudo apt update
sudo apt install gcc
  1. Test and verify

Open the command line and enter cmake --version , If the version number is displayed correctly, the installation is successful.

1.2.2. Install CMake

  1. Install CMake 3.28.3 or later
sudo apt install cmake
  1. Test and verify

Open the command line and enter gcc --version , If the version number is displayed correctly, the installation is successful.

1.3. MacOS

1.3.1. Install GCC Compiler

  1. Install GCC
brew install gcc

If Homebrew is not installed, please install Homebrew first:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
  1. Test and verify

Open the command line and enter gcc --version , If the version number is displayed correctly, the installation is successful.

1.3.2. Install CMake

  1. Install CMake 3.28.3 or later
brew install cmake
  1. Test and verify

Open the command line and enter cmake --version , If the version number is displayed correctly, the installation is successful.