NVMain和Gem5环境搭建(三)
程序员文章站
2022-06-03 22:47:04
...
Gem5环境搭建
- hg的搭建
HG(Mercurial)介绍:
Mercurial是一款非常优秀的分布式版本控制系统(DCVS),具有高效率、跨平台、可扩展、使用简便且开源等优点,是目前最为流行的版本控制工具之一。Mercurial英文意为水银,所以常被缩写为Hg。
sudo pip install mercurial
[email protected]-0-5-ubuntu:~$ sudo pip install mercurial
DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
WARNING: The directory '/home/ubuntu/.cache/pip' or its parent directory is not owned or is not writable by the current user. The cache has been disabled. Check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Looking in indexes: https://pypi.doubanio.com/simple
Collecting mercurial
Downloading https://pypi.doubanio.com/packages/91/3b/e531b6845dda605b3bb9835f2c260ed6917f2cbda1a999feb8da6632a697/mercurial-5.3.tar.gz (7.5 MB)
|████████████████████████████████| 7.5 MB 44.5 MB/s
Building wheels for collected packages: mercurial
Building wheel for mercurial (setup.py) ... done
Created wheel for mercurial: filename=mercurial-5.3-cp27-cp27mu-linux_x86_64.whl size=5704813 sha256=ab87798541834f527f6dba50f24eadf8302a3c7631573fc26b80e4fa4dbf314f
Stored in directory: /tmp/pip-ephem-wheel-cache-GA_eP6/wheels/61/4c/55/e641cbb43bdaf6c272b1debf480f33c825830acd14729521dd
Successfully built mercurial
Installing collected packages: mercurial
Successfully installed mercurial-5.3
- 然后我们hg clone一下
[email protected]-0-5-ubuntu:~$ hg clone http://repo.gem5.org/gem5
abort: error: Name or service not known
发现问题很大,解决不了。我在tokyo的服务器也是一样的情况,看来只能git了。
然而腾讯云怎么挂代理翻我就没研究过了,这肯定卡死啊
git clone https://gem5.googlesource.com/public/gem5
- 那就github下载下来再ftp传进去吧
github链接
sudo git clone https://github.com/gem5/gem5.git
不挂代理速度40-100k左右,忍忍就好了
remote: Enumerating objects: 207051, done.
remote: Total 207051 (delta 0), reused 0 (delta 0), pack-reused 207051
Receiving objects: 100% (207051/207051), 226.20 MiB | 70.00 KiB/s, done.
Resolving deltas: 100% (100210/100210), done.
Checking connectivity... done.
安装依赖库protobuf-compiler
sudo apt-get install protobuf-compiler
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
libprotobuf9v5 libprotoc9v5
The following NEW packages will be installed:
libprotobuf9v5 libprotoc9v5 protobuf-compiler
0 upgraded, 3 newly installed, 0 to remove and 183 not upgraded.
Need to get 620 kB of archives.
After this operation, 2,321 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://mirrors.tencentyun.com/ubuntu xenial/main amd64 libprotobuf9v5 amd64 2.6.1-1.3 [326 kB]
Get:2 http://mirrors.tencentyun.com/ubuntu xenial/main amd64 libprotoc9v5 amd64 2.6.1-1.3 [273 kB]
Get:3 http://mirrors.tencentyun.com/ubuntu xenial/main amd64 protobuf-compiler amd64 2.6.1-1.3 [20.4 kB]
Fetched 620 kB in 0s (859 kB/s)
Selecting previously unselected package libprotobuf9v5:amd64.
(Reading database ... 112537 files and directories currently installed.)
Preparing to unpack .../libprotobuf9v5_2.6.1-1.3_amd64.deb ...
Unpacking libprotobuf9v5:amd64 (2.6.1-1.3) ...
Selecting previously unselected package libprotoc9v5:amd64.
Preparing to unpack .../libprotoc9v5_2.6.1-1.3_amd64.deb ...
Unpacking libprotoc9v5:amd64 (2.6.1-1.3) ...
Selecting previously unselected package protobuf-compiler.
Preparing to unpack .../protobuf-compiler_2.6.1-1.3_amd64.deb ...
Unpacking protobuf-compiler (2.6.1-1.3) ...
Processing triggers for libc-bin (2.23-0ubuntu10) ...
Processing triggers for man-db (2.7.5-1) ...
Setting up libprotobuf9v5:amd64 (2.6.1-1.3) ...
Setting up libprotoc9v5:amd64 (2.6.1-1.3) ...
Setting up protobuf-compiler (2.6.1-1.3) ...
Processing triggers for libc-bin (2.23-0ubuntu10) ...
然后开始编译
scons build/X86/gem5.opt
这里选择x86,其他的我也不会啊
发现事情不太对劲,怎么用了这么久,于是乎打开了官网看看这里面有什么,结果被告知要编译1-2小时。我一想到自己是垃圾佬的乞丐机,就有点泪目
官方教程
scons build/X86/gem5.opt
此处等待安装的过程中去吃个晚饭
好吧我弄完了它还没完,感觉要很久很久了八点了,腾讯终端挂了
{standard input}: Assembler messages:
{standard input}:4788317: Warning: end of file not at end of a line; newline inserted
{standard input}:4789146: Warning: zero assumed for missing expression
g++: internal compiler error: Killed (program cc1plus)
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-5/README.Bugs> for instructions.
scons: *** [build/X86/arch/x86/generated/inst-constrs.o] Error 4
scons: building terminated because of errors.
挂了终端以后重新来就不行了,看来得重新装
重装着我才想起为什么不用快照呢?无论如何这次都要先快照下来
推荐阅读
-
最简单的nginx+ftp搭建图片服务器(Windows Server服务器环境下和本机都可以用)
-
利用GLFW和GLEW搭建OpenGL开发环境
-
Eclipse和PyDev搭建完美Python开发环境教程(Windows篇)
-
搭建Python的Django框架环境并建立和运行第一个App的教程
-
android环境搭建教程详解,android环境搭建教程步骤和方法
-
android环境搭建教程详解,android环境搭建教程步骤和方法
-
搭建Python的Django框架环境并建立和运行第一个App的教程
-
editplus和mingw一起搭建c/c++开发环境的详细步骤
-
搭建java WEB开发环境和应用
-
Windows系统下使用flup搭建Nginx和Python环境的方法