ubuntu18.04在安装pintos时遇到的问题

本文记录了在Ubuntu环境下配置过程中遇到的问题及解决方案,包括安装特定依赖包时找不到包的问题,运行Pintos时出现的字符识别错误,以及编译utils时的链接错误等。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

一、ubuntu环境配置时遇到的问题

配置环境的这一步:

$ sudo apt-get install libc6:i386 libgcc1:i386 gcc-4.6-base:i386 libstdc++5:i386 libstdc++6:i386

遇到的问题:

E: Unable to locate package gcc-4.6-base:i386
E: Couldn't find any package by glob 'gcc-4.6-base'
E: Couldn't find any package by regex 'gcc-4.6-base'

我是在云服务器上操作的,使用阿里云的sources.list软件源,参考这篇博客

https://blog.csdn.net/qq_46015650/article/details/121567601

二、运行pintos时遇到的问题

在这一步时:

$ ../../utils/pintos -- run alarm-multiple

出现了以下问题:

Unrecognized character \x16; marked by <-- HERE after    if ($<-- HERE near column 7 at ../../utils/pintos line 911.

原因:下载了旧版本的pintos
解决:到git公共库里重新下个新的(tree-snapshot)

三、编译utils时遇到的问题

在这一步时:

$ cd maker/pintos/src/utils
$ vim Makefile     *//Modify the 5th line:  LDFLAGS -> LDLIBS*
$ make

出现的问题:

gcc -Wall -W     -c  -o setitimer-helper.o setitimer-helper.c
gcc     setitimer-helper.o     -o setitimer-helper
setitimer-helper.o: In function 'main':
setitimer-helper.c:(.text+0xcb): undefined reference to 'floor'
collect2: error: ld returned 1 exit status
<builtin>: recipe for target 'setitimer-helper' failed
make: *** [setitimer-helper] Error 1

Makefile文件打开之后进入编辑,将第三行LDFLAGS改成LDLIBS,然后再执行make,参考这一篇

http://hk.voidcc.com/question/p-hsdjgrmm-ve.html

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值