当前位置: 首页 > news >正文

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版本。然后把下面这里的内容全部复制!!!

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进行编辑

这里是已经替换成清华镜像的内容了

: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开发中都是很有用的,因为后续如果要安装其他的包,都会很方便,而不用再愁一直访问失败了。

相关文章:

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

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

关于vue.config.js

关于vue.config.js 简述 vue.config.js是一个可选的配置文件,如果项目的根目录中存在这个文件,那么它就会被vue/cli-service自动加载。你也可以使用package.json中的vue字段,但是注意这种写法需要你严格遵守JSON的格式来写。 这个文件应该…...

Jupyter NoteBook 中使用 cv2.imshow 显示图片

Jupyter NoteBook 中使用 cv2.imshow 显示图片 有两种办法: 用 cv2.imshow时加入cv2.destroyAllWindows() 用 plt.imshow() 代替 cv2.imshowhttps://blog.csdn.net/kuweicai/article/details/103359299...

gpt扣款失败,openai扣款失败无法使用-如何解决gpt扣款失败的问题?

gpt扣款失败,openai扣款失败无法使用。毕竟你花了钱却无法使用你所期待的服务,这种情况确实令人不快。但是, 为什么gpt扣款失败? 可能是由于支付问题导致的扣款失败。这包括信用卡额度不足、支付信息错误等等。如果你的支付信息…...

OJ练习第180题——颠倒二进制位

颠倒二进制位 力扣链接:190. 颠倒二进制位 题目描述 颠倒给定的 32 位无符号整数的二进制位。 提示: 请注意,在某些语言(如 Java)中,没有无符号整数类型。在这种情况下,输入和输出都将被指…...

SpringSecurity授权--前端进行访问控制

目录 &#xff08;1&#xff09;引入依赖 &#xff08;2&#xff09;页面 SpringSecurity可以在一些视图技术中进行控制显示效果。例如Thymeleaf中&#xff0c;只有登录用户拥有某些权限才会展示一些菜单 &#xff08;1&#xff09;引入依赖 <!--Spring Security整合Thyme…...

如何看待Unity新的收费模式?

文章目录 背景Unity的论点开发者的担忧如何看待Unity新的收费模式&#xff1f;1. 理解Unity的立场2. 考虑小型开发者3. 探索替代方案4. 对市场变化保持敏感5. 提高游戏质量 结论 &#x1f389; 如何看待Unity新的收费模式&#xff1f; ☆* o(≧▽≦)o *☆嗨~我是IT陈寒&#x1…...

WebRTC系列--sdp协商中的answer编解码协商过程

关于createAnswer的流程在前面的文章WebRTC系列-SDP之CreateAnswer这篇文章中有详细的分析。 这篇文章主要对于MediaSessionDescriptionFactory的AddAudioContentForAnswer做详细的分析,也就是说对于音频编码的匹配也是在这个方法里实现: 首先主要的函数调用如下图: 这篇文…...

WeCanStudio工具套件介绍

直接上视频,在超燃的《天马座幻想》的背景音乐下&#xff0c;再次了解一下该工具套件吧。 WeCanStudio开发套件介绍...

图形化思维:Graphviz和DOT语言的艺术与实践

前言 Graphviz和DOT语言是一对强大的工具&#xff0c;用于创建各种类型的图形&#xff0c;从流程图和组织结构图到网络拓扑图&#xff0c;无所不能。它们的灵活性和自定义性使得它们在数据可视化、系统设计、项目规划等各个领域都备受欢迎。然而&#xff0c;要想真正掌握Graph…...

如何查看电脑详细配置、型号?这4个技巧 yyds!

知道自己电脑的配置和型号&#xff0c;可以更合理合适的去安装软件&#xff0c;避免出现电脑系统和软件不兼容问题。 了解详细配置信息可以检测一下电脑组件是否是二手的。 从解决实际问题的角度&#xff0c;推荐这4个技巧&#xff1a; 1、右键“此电脑” 2、设备管理器查看…...

安卓机型固件系统分区的基础组成 手机启动规律初步常识 各分区的基本含义与说明

此贴为基本常识。感兴趣的友友可以了解手机的启动顺序和各模式的基本操作与意义。另外了解手机系统分区各文件夹的含义 分区说明对应贴&#xff1a;安卓机型固件中分区对应说明 手机开机基本启动顺序 当我们按下手机开机键的时候。基本的启动顺序为 注意&#xff1a;该结构图…...

php如何把数组元素反转-array_reverse使用要点

在PHP中&#xff0c;你可以使用array_reverse()函数来反转数组的元素顺序。该函数会返回一个新的数组&#xff0c;其中的元素顺序与原始数组相反。 以下是使用array_reverse()函数反转数组的示例代码&#xff1a; <?php $originalArray array(a, b, c, d); $reversedArr…...

【CV学习笔记】tensorrtx-yolov5 逐行代码解析

1、前言 TensorRTx(下文简称为trtx)是一个十分流行的利用API来搭建网络结构实现trt加速的开源库&#xff0c;作者提到为什么不用ONNX parser的方式来进行trt加速&#xff0c;而用最底层的API来搭建trt加速的方式有如下原因: Flexible 很容易修改模型的任意一层&#xff0c;删…...

微信管理系统可以解决什么问题?

微信作为一款社交通讯软件&#xff0c;已经成为人们日常生活中不可缺少的工具。不仅个人&#xff0c;很多企业都用微信来联系客户、维护客户和营销&#xff0c;这自然而然就会有很多微信账号、手机也多&#xff0c;那管理起来就会带来很多的不便&#xff0c;而微信管理系统正好…...

mysql事务测试

mysql的事务处理主要有两种方法1、用begin,rollback,commit来实现 begin; -- 开始一个事务 rollback; -- 事务回滚 commit; -- 事务提交 2、直接用set来改变mysql的自动提交模式 mysql默认是自动提交的&#xff0c;也就是你提交一个sql&#xff0c;它就直接执行&#xff01;我…...

Spring面试题14:Spring中什么是Spring Beans? 包含哪些?Spring容器提供几种方式配置元数据?Spring中怎样定义类的作用域?

该文章专注于面试,面试只要回答关键点即可,不需要对框架有非常深入的回答,如果你想应付面试,是足够了,抓住关键点 面试官:Spring中什么是Spring Beans? 包含哪些? 在Spring中,Spring Beans是指由Spring容器管理的对象。Spring Beans包含以下内容: 类定义(Class De…...

Tomcat部署、优化、以及操作练习

一.Tomcat的基本介绍 1.1.Tomcat是什么&#xff1f; Tomcat服务器是一个免费的开放源代码的Web应用服务器&#xff0c;属于轻量级应用服务器&#xff0c;在中小型系统和并发访问用户不是很多的场合下被普遍使用&#xff0c;是开发和调试JSP程序的首选。一般来说&#xff0c;T…...

服务器假死日志按时间统计排查

文章目录 场景解决方案排查过程根据cost时间来筛选 场景 服务器假死&#xff0c;进程还在&#xff0c;但是已经接不到请求了。因此有客户报事&#xff0c;发现服务假死了。 解决方案 这种假死问题一般不太好排查&#xff0c;常规来说有几种可能。 1、慢sql导致卡死。 2、大数…...

CSS——grid网格布局的基本使用

网格布局在实现页面自适应&#xff0c;大屏可视化中常常使用&#xff0c;在这篇博客里&#xff0c;记录一下网格布局的基本使用。 参考文档&#xff1a;网格布局_菜鸟教程 文章目录 1. 体会grid的自适应性2. grid-template-arr配置网格行列3. 网格单位fr与repeat()简写属性值4…...

Unity3D中Gfx.WaitForPresent优化方案

前言 在Unity中&#xff0c;Gfx.WaitForPresent占用CPU过高通常表示主线程在等待GPU完成渲染&#xff08;即CPU被阻塞&#xff09;&#xff0c;这表明存在GPU瓶颈或垂直同步/帧率设置问题。以下是系统的优化方案&#xff1a; 对惹&#xff0c;这里有一个游戏开发交流小组&…...

STM32标准库-DMA直接存储器存取

文章目录 一、DMA1.1简介1.2存储器映像1.3DMA框图1.4DMA基本结构1.5DMA请求1.6数据宽度与对齐1.7数据转运DMA1.8ADC扫描模式DMA 二、数据转运DMA2.1接线图2.2代码2.3相关API 一、DMA 1.1简介 DMA&#xff08;Direct Memory Access&#xff09;直接存储器存取 DMA可以提供外设…...

Qt Http Server模块功能及架构

Qt Http Server 是 Qt 6.0 中引入的一个新模块&#xff0c;它提供了一个轻量级的 HTTP 服务器实现&#xff0c;主要用于构建基于 HTTP 的应用程序和服务。 功能介绍&#xff1a; 主要功能 HTTP服务器功能&#xff1a; 支持 HTTP/1.1 协议 简单的请求/响应处理模型 支持 GET…...

Mac软件卸载指南,简单易懂!

刚和Adobe分手&#xff0c;它却总在Library里给你写"回忆录"&#xff1f;卸载的Final Cut Pro像电子幽灵般阴魂不散&#xff1f;总是会有残留文件&#xff0c;别慌&#xff01;这份Mac软件卸载指南&#xff0c;将用最硬核的方式教你"数字分手术"&#xff0…...

深入解析C++中的extern关键字:跨文件共享变量与函数的终极指南

&#x1f680; C extern 关键字深度解析&#xff1a;跨文件编程的终极指南 &#x1f4c5; 更新时间&#xff1a;2025年6月5日 &#x1f3f7;️ 标签&#xff1a;C | extern关键字 | 多文件编程 | 链接与声明 | 现代C 文章目录 前言&#x1f525;一、extern 是什么&#xff1f;&…...

华为云Flexus+DeepSeek征文|DeepSeek-V3/R1 商用服务开通全流程与本地部署搭建

华为云FlexusDeepSeek征文&#xff5c;DeepSeek-V3/R1 商用服务开通全流程与本地部署搭建 前言 如今大模型其性能出色&#xff0c;华为云 ModelArts Studio_MaaS大模型即服务平台华为云内置了大模型&#xff0c;能助力我们轻松驾驭 DeepSeek-V3/R1&#xff0c;本文中将分享如何…...

算法笔记2

1.字符串拼接最好用StringBuilder&#xff0c;不用String 2.创建List<>类型的数组并创建内存 List arr[] new ArrayList[26]; Arrays.setAll(arr, i -> new ArrayList<>()); 3.去掉首尾空格...

深度学习水论文:mamba+图像增强

&#x1f9c0;当前视觉领域对高效长序列建模需求激增&#xff0c;对Mamba图像增强这方向的研究自然也逐渐火热。原因在于其高效长程建模&#xff0c;以及动态计算优势&#xff0c;在图像质量提升和细节恢复方面有难以替代的作用。 &#x1f9c0;因此短时间内&#xff0c;就有不…...

深入浅出WebGL:在浏览器中解锁3D世界的魔法钥匙

WebGL&#xff1a;在浏览器中解锁3D世界的魔法钥匙 引言&#xff1a;网页的边界正在消失 在数字化浪潮的推动下&#xff0c;网页早已不再是静态信息的展示窗口。如今&#xff0c;我们可以在浏览器中体验逼真的3D游戏、交互式数据可视化、虚拟实验室&#xff0c;甚至沉浸式的V…...

Docker、Wsl 打包迁移环境

电脑需要开启wsl2 可以使用wsl -v 查看当前的版本 wsl -v WSL 版本&#xff1a; 2.2.4.0 内核版本&#xff1a; 5.15.153.1-2 WSLg 版本&#xff1a; 1.0.61 MSRDC 版本&#xff1a; 1.2.5326 Direct3D 版本&#xff1a; 1.611.1-81528511 DXCore 版本&#xff1a; 10.0.2609…...