Ubuntu安装参见:http://www.gem5.org/documentation/learning_gem5/part1/building/
Centos安装如下:
-
git (Git):
The gem5 project uses Git for version control. Git is a distributed version control system. More information about Git can be found by following the link. Git should be installed by default on most platforms. However, to install Git in Ubuntu usesudo yum install git
-
gcc 5+
You may need to use environment variables to point to a non-default version of gcc.On Ubuntu, you can install a development environment with
sudo yum install kernel-devel kernel-headers
We support GCC Versions >=5, up to GCC 10
- gem5 uses SCons as its build environment. SCons is like make on steroids and uses Python scripts for all aspects of the build process. This allows for a very flexible (if slow) build system.
To get SCons on Ubuntu use
wget https://sourceforge.net/projects/scons/files/scons/3.1.2/scons-3.1.2.tar.gz tar -zxvf scons-3.1.2.tar.gz cd scons-3.1.2 python setup.py install sudo ln -s /usr/local/bin/scons /bin/scons
-
Python 3.9 ( https://www.jb51.net/article/197461.htm)
gem5 relies on the Python development libraries. To install these on Ubuntu usesudo yum install python3-devel sudo pip3 install m5
-
protobuf 2.1+
“Protocol buffers are a language-neutral, platform-neutral extensible mechanism for serializing structured data.” In gem5, the protobuflibrary is used for trace generation and playback. protobuf is not a required package, unless you plan on using it for trace generation and playback.sudo yum install protobuf protobuf-devel protobuf-compiler google-perftools-devel
-
Boost (Optional) : The Boost library is a set of general purpose C++ libraries. It is a necessary dependency if you wish to use the SystemC implementation.
```
sudo yum install boost boost-devel
```
7.