64位Ubuntu20.04.5 LTS系统安装32位运行库

这篇具有很好参考价值的文章主要介绍了64位Ubuntu20.04.5 LTS系统安装32位运行库。希望对大家有所帮助。如果存在错误或未考虑完全的地方,请大家不吝赐教,您也可以点击"举报违法"按钮提交疑问。

背景:
在ubutu(版本为20.04.5 LTS)中运行./arm-none-linux-gnueabi-gcc -v 后提示“no such device”。
经多方查证,是ubutu的版本是64位的,而需要运行的编译工具链是32位的,因此会不兼容。
解决方法就是在ubuntu中安装32位的运行环境

如何安装32位的运行环境:
执行以下3条命令:

sudo apt-get install libc6:i386
sudo apt-get install lib32z1
sudo apt-get install libncurses5:i386

但是问题就来了,当你在执行上面3条命令中的任意一条时,你大概率会出现各种404的错误,就是你无法访问到下载的网站!!
那么就要先进行下面的操作。

Ubuntu 配置国内源

1.找到替换的镜像源

该操作就是将ubuntu自己链接的镜像源更新,重新链接到国内的镜像源,这样下载就会快很多啦。依然选择使用人数比较多的清华的。
镜像源网站链接:
清华大学开源软件镜像站

ubuntu安装32位库,ubuntu,linux
打开之后就是上面这个样子,只需要在这里选择你安装的ubuntu版本。然后把下面这里的内容全部复制!!!

2.替换ubuntu自带的源为清华的源
接下来回到ubuntu中。
首先将ubuntu自带的源备份

root@ubuntu:/home/jian# cd /
root@ubuntu:/# cd /etc/apt
root@ubuntu:/etc/apt# sudo cp sources.list sources.list.bak//备份源文件

完成备份后就可以修改原来的文件的了,就是这里的sources.list

vim sources.list//使用vim编辑器打开sources.list进行编辑

ubuntu安装32位库,ubuntu,linux

:wq//退出vim编辑器

3.更新替换好的镜像源,让系统生效

root@ubuntu:/etc/apt# sudo apt-get update//更新镜像源
命中:1 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal InRelease
获取:2 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates InRelease [114 kB]
获取:3 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports InRelease [108 kB]
获取:4 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/main Translation-zh_CN [113 kB]
获取:5 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/restricted Translation-zh_CN [1,324 B]
获取:6 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/universe Translation-zh_CN [388 kB]
获取:7 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]
获取:8 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/multiverse Translation-zh_CN [4,612 B]
获取:9 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main i386 Packages [883 kB]
获取:10 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main amd64 Packages [2,851 kB]
获取:11 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main Translation-en [468 kB]
获取:12 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main amd64 DEP-11 Metadata [275 kB]
获取:13 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main DEP-11 48x48 Icons [60.8 kB]
获取:14 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main DEP-11 64x64 Icons [98.3 kB]
获取:15 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/main amd64 c-n-f Metadata [17.1 kB]
获取:16 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/restricted amd64 Packages [2,327 kB]
获取:17 http://security.ubuntu.com/ubuntu focal-security/main amd64 Packages [2,435 kB]
获取:18 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/restricted i386 Packages [33.7 kB]
获取:19 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/restricted Translation-en [325 kB]
获取:20 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/restricted amd64 c-n-f Metadata [576 B]
获取:21 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe amd64 Packages [1,115 kB]
获取:22 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe i386 Packages [747 kB]
获取:23 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe Translation-en [266 kB]
获取:24 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe amd64 DEP-11 Metadata [410 kB]
获取:25 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe DEP-11 48x48 Icons [280 kB]
获取:26 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe DEP-11 64x64 Icons [493 kB]
获取:27 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/universe amd64 c-n-f Metadata [25.5 kB]
获取:28 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse i386 Packages [8,436 B]
获取:29 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse amd64 Packages [25.8 kB]
获取:30 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse Translation-en [7,484 B]
获取:31 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse amd64 DEP-11 Metadata [940 B]
获取:32 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates/multiverse amd64 c-n-f Metadata [620 B]
获取:33 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main amd64 Packages [45.7 kB]
获取:34 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main i386 Packages [36.1 kB]
获取:35 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main amd64 DEP-11 Metadata [8,008 B]
获取:36 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main DEP-11 48x48 Icons [7,156 B]
获取:37 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main DEP-11 64x64 Icons [10.7 kB]
获取:38 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/main amd64 c-n-f Metadata [1,420 B]
获取:39 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe i386 Packages [13.8 kB]
获取:40 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe amd64 Packages [25.0 kB]
获取:41 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe Translation-en [16.3 kB]
获取:42 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe amd64 DEP-11 Metadata [30.5 kB]
获取:43 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe DEP-11 48x48 Icons [13.3 kB]
获取:44 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe DEP-11 64x64 Icons [22.7 kB]
获取:45 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports/universe amd64 c-n-f Metadata [880 B]
获取:46 http://security.ubuntu.com/ubuntu focal-security/main i386 Packages [646 kB]
获取:47 http://security.ubuntu.com/ubuntu focal-security/main Translation-en [382 kB]
获取:48 http://security.ubuntu.com/ubuntu focal-security/main amd64 DEP-11 Metadata [59.9 kB]
获取:49 http://security.ubuntu.com/ubuntu focal-security/main DEP-11 48x48 Icons [18.9 kB]
获取:50 http://security.ubuntu.com/ubuntu focal-security/main DEP-11 64x64 Icons [36.0 kB]
获取:51 http://security.ubuntu.com/ubuntu focal-security/main DEP-11 64x64@2 Icons [29 B]
获取:52 http://security.ubuntu.com/ubuntu focal-security/main amd64 c-n-f Metadata [13.1 kB]
获取:53 http://security.ubuntu.com/ubuntu focal-security/restricted i386 Packages [32.3 kB]
获取:54 http://security.ubuntu.com/ubuntu focal-security/restricted amd64 Packages [2,173 kB]
获取:55 http://security.ubuntu.com/ubuntu focal-security/restricted Translation-en [304 kB]
获取:56 http://security.ubuntu.com/ubuntu focal-security/restricted amd64 c-n-f Metadata [580 B]
获取:57 http://security.ubuntu.com/ubuntu focal-security/universe i386 Packages [613 kB]
获取:58 http://security.ubuntu.com/ubuntu focal-security/universe amd64 Packages [881 kB]
获取:59 http://security.ubuntu.com/ubuntu focal-security/universe Translation-en [185 kB]
获取:60 http://security.ubuntu.com/ubuntu focal-security/universe amd64 DEP-11 Metadata [96.3 kB]
获取:61 http://security.ubuntu.com/ubuntu focal-security/universe DEP-11 48x48 Icons [52.0 kB]
获取:62 http://security.ubuntu.com/ubuntu focal-security/universe DEP-11 64x64 Icons [101 kB]
获取:63 http://security.ubuntu.com/ubuntu focal-security/universe DEP-11 64x64@2 Icons [29 B]
获取:64 http://security.ubuntu.com/ubuntu focal-security/universe amd64 c-n-f Metadata [19.1 kB]
获取:65 http://security.ubuntu.com/ubuntu focal-security/multiverse i386 Packages [7,196 B]
获取:66 http://security.ubuntu.com/ubuntu focal-security/multiverse amd64 Packages [23.6 kB]
获取:67 http://security.ubuntu.com/ubuntu focal-security/multiverse Translation-en [5,504 B]
获取:68 http://security.ubuntu.com/ubuntu focal-security/multiverse amd64 DEP-11 Metadata [940 B]
获取:69 http://security.ubuntu.com/ubuntu focal-security/multiverse DEP-11 48x48 Icons [1,867 B]
获取:70 http://security.ubuntu.com/ubuntu focal-security/multiverse DEP-11 64x64 Icons [2,497 B]
获取:71 http://security.ubuntu.com/ubuntu focal-security/multiverse DEP-11 64x64@2 Icons [29 B]
获取:72 http://security.ubuntu.com/ubuntu focal-security/multiverse amd64 c-n-f Metadata [548 B]
已下载 19.9 MB,耗时 9(2,289 kB/s)                                          
正在读取软件包列表... 完成

4.测试源是否可以使用
安装一个好玩的包,安装完成sl包后运行一下,会有惊喜,如果你笑了,那就证明源起作用了。

root@ubuntu:/etc/apt# sudo apt-get install sl//安装sl包
正在读取软件包列表... 完成
正在分析软件包的依赖关系树       
正在读取状态信息... 完成       
下列【新】软件包将被安装:
  sl
升级了 0 个软件包,新安装了 1 个软件包,要卸载 0 个软件包,有 323 个软件包未被升级。
需要下载 12.7 kB 的归档。
解压缩后会消耗 60.4 kB 的额外空间。
获取:1 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal/universe amd64 sl amd64 5.02-1 [12.7 kB]
已下载 12.7 kB,耗时 0(29.9 kB/s)
正在选中未选择的软件包 sl。
(正在读取数据库 ... 系统当前共安装有 179299 个文件和目录。)
准备解压 .../archives/sl_5.02-1_amd64.deb  ...
正在解压 sl (5.02-1) ...
正在设置 sl (5.02-1) ...
正在处理用于 man-db (2.9.1-1) 的触发器 ...
root@ubuntu:/etc/apt# sl//运行sl


好了,现在再到上面安装32位的系统运行环境,应该就没问题了。这里更新了镜像源,在整个linux开发中都是很有用的,因为后续如果要安装其他的包,都会很方便,而不用再愁一直访问失败了。文章来源地址https://www.toymoban.com/news/detail-731097.html

到了这里,关于64位Ubuntu20.04.5 LTS系统安装32位运行库的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处: 如若内容造成侵权/违法违规/事实不符,请点击违法举报进行投诉反馈,一经查实,立即删除!

领支付宝红包 赞助服务器费用

相关文章

  • Ubuntu 20.04 LTS 安装教程

    官方桌面版下载:https://cn.ubuntu.com/download/desktop,进入下载页面后,通常我们并不想安装最新的Ubuntu版本,那么需要找到其它版本的下载链接,如下图的红色框。如果要安装最新版,直接点击下载下图中的绿色框即可   由于该教程主要是安装 Ubuntu 20.04 版本,所以点击【上图

    2024年02月17日
    浏览(58)
  • Ubuntu 20.04 LTS 系统下 安装Nvidia 显卡驱动、CUDA、cuDNN, 并可进行CUDA版本切换

    因为做深度学习的研究项目,为全新机器在Ubuntu 20.04 LTS 系统下 安装Nvidia 显卡驱动、Cuda、Cudnn。并进行CUDA版本切换 成功安装完成了,写个记录。 步骤一: 安装更新软件列表和依赖项 在安装Nvidia显卡驱动之前,需要更新软件列表和必要的依赖项。 步骤二: 查看GPU型号,并

    2024年02月13日
    浏览(50)
  • Ubuntu 20.04 安装 mysql8 LTS

    Ubuntu 20.04 安装 mysql8 LTS sudo apt-get update sudo apt-get install mysql-server -y mysql --version mysql Ver 8.0.35-0ubuntu0.20.04.1 for Linux on x86_64 ((Ubuntu)) Ubuntu20.04 是自带了 MySQL8. 几版本的,低于 20.04 则默认安装是 MySQL5.7.33 systemctl status mysql.service sudo netstat -tap | grep mysql sudo service mysql start sudo service

    2024年02月04日
    浏览(34)
  • Ubuntu 20.04 LTS 安装Kubernetes 1.26

    1、环境配置 (1)添加主机名称解析记录 (2)禁止K8s使用虚拟内存 (3)开启内核ipv4转发 (4) 安装ipvsadm,加载ipvs模块 cat /etc/modules-load.d/ipvs.conf EOF ip_vs ip_vs_rr ip_vs_wrr ip_vs_sh nf_conntrack EOF 加载模块,并进行检查 modprobe --all ip_vs ip_vs_rr ip_vs_wrr  ip_vs_sh  nf_conntrack lsmod|grep -e ip_vs -e nf

    2024年02月09日
    浏览(35)
  • AI画图 Ubuntu 20.04.5 LTS x86_64 Docker stable diffusion webui 及 http api接口

    Docker镜像 参考地址: docker一键运行stable diffusion webui,常用插件和功能完备,获得镜像后可打包带走 - 哔哩哔哩 nvidia cuda 驱动 ​​​​​​​Linux x64 (AMD64/EM64T) Display Driver | 525.116.04 | Linux 64-bit | NVIDIA lora模型下载 热门Civitai LoRA模型下载第一批合集 Stable Diffusion WebUI - openAI 注

    2024年02月08日
    浏览(39)
  • Ubuntu20.04LTS安装CUDA并支持多版本切换

    如果Ubuntu系统还没有安装显卡驱动,参考这篇文章:Ubuntu20.04LTS安装RTX-3060显卡驱动 当显卡驱动安装完成后,需要使用 nvidia-smi 命令查看英伟达显卡驱动版本。 如上图所示,英伟达驱动版本为520.61.05,CUDA最高支持的版本为11.8。 点击该链接:https://docs.nvidia.com/cuda/cuda-toolkit-

    2024年02月13日
    浏览(48)
  • 英特尔13代桌面CPU平台安装ubuntu20.04LTS记录

    安装环境一: i7-13700K  华硕Z790-P  16X2GB内存   华硕 TUF 3070 O8G 安装环境二: i5-13400    华硕B760M-A D4 8x2GB内存   UHD730核显 安装系统: ubuntu20.04LTS(首先用光驱安装失败,后面用U盘更换ubuntu22.04.2LTS成功) 因为特殊原因,先用光驱安装ubuntu20.04LTS,首先安装很慢很慢,要等半小时进

    2024年02月06日
    浏览(58)
  • Ubuntu 20.04 LTS 安装ttf-mscorefonts-installer的方法

    试了如下两种方法,都不行。对方法1修改了一下OK了。 安装ttf-mscorefonts-installer中出错的原因是需要的文件无法下载 安装ttf-mscorefonts-installer中出错的原因是需要的文件无法下载。我们可以事先下载好,在安装ttf-mscorefonts-installer1. 下载所需的所有的字体,到http://sourceforge.net

    2024年02月04日
    浏览(41)
  • Ubuntu 22.04.2 LTS LTS x86_64 安装 stable-diffusion-webui 【2】基本版本完结。

    前篇 Ubuntu 20.04 LTS x86_64 安装 stable-diffusion-webui_hkNaruto的博客-CSDN博客 内容太多,分第二篇继续 中途重装了机器,20.04 ,apt upgrade后自动升级到22.04.2 现状:起来了,又没完全起来 启动日志 界面 获得阶段性成果了。 参考故障处理1. 下载资源,再次启动 成果启动,测试1girl看看

    2024年02月16日
    浏览(24)
  • Linux(7)Ubuntu20.04 arm64安装Docker

    vi /etc/apt/sources.list 这个命令后面跟了几个软件包的名字,它们分别是: apt-transport-https:这个软件包允许apt使用HTTPS协议来访问软件源。 ca-certificates:这个软件包提供了一些受信任的证书颁发机构的证书,用来验证HTTPS连接的安全性。 curl:这个软件包提供了一个命令行工具,

    2024年02月10日
    浏览(46)

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

博客赞助

微信扫一扫打赏

请作者喝杯咖啡吧~博客赞助

支付宝扫一扫领取红包,优惠每天领

二维码1

领取红包

二维码2

领红包