Ubuntu 20.04.2 LTS安装 最新版 微信(wine):Ubuntu 20.04.2 LTS 使用 Wine 安装最新版微信 全流程指南

本文详细指导了在Ubuntu系统上通过wine安装微信的过程,包括wine版本检查、软件安装、winetricks修复输入问题,以及下载并安装微信官方包。

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

Ubuntu 20.04.2 LTS 使用 Wine 安装最新版微信 全流程指南 🚀

适用人群:Ubuntu 桌面版用户
目标:在 Ubuntu 20.04.2 LTS 上通过 Wine 环境,安装并运行最新 Windows 版微信客户端


引言

微信 PC 版官方尚未提供 Linux 安装包,但借助 Wine(Windows 兼容层)和 Winetricks,我们依然可以在 Ubuntu 上畅享微信的全部功能。本篇超详细指南,手把手带你从 环境检测依赖安装补丁修复,到 微信安装与调试,完全覆盖所有坑点与优化技巧。无论你是 Linux 新手,还是老鸟,这篇文章都能帮你快速完成 Ubuntu 微信环境搭建。

在这里插入图片描述


一、检测与安装 Wine

1. 查看本机 Wine 版本

打开终端,执行:

wine --version

示例输出(表示已安装 Wine 5.0):

libin@oak:~$ wine --version
wine-5.0 (Ubuntu 5.0-3ubuntu1)
libin@oak:~$

如果提示 command not found 或版本过低,请继续下面步骤。

2. 安装 Wine 正式版

sudo apt update
sudo apt install wine

安装完成后,再次运行 wine --version,应看到类似 wine-5.0 的输出。


二、安装 Winetricks 并修复 RichEdit

有时微信在 Wine 下无法正确显示输入框内容,需要借助 Winetricks 安装 riched20 补丁。

1. 安装 Winetricks

sudo apt install winetricks

2. 执行 RichEdit 组件安装

winetricks riched20
  • 若出现 404 错误,需手动下载以下两个文件到 Winetricks 缓存目录,然后重试:

    文件名目标路径
    W2KSP4_EN.EXE~/.cache/winetricks/win2ksp4/W2KSP4_EN.EXE
    InstMsiW.exe~/.cache/winetricks/msls31/InstMsiW.exe
# 下载示例(请根据实际 URL 替换)
wget -O ~/.cache/winetricks/win2ksp4/W2KSP4_EN.EXE https://example.com/W2KSP4_EN.EXE
wget -O ~/.cache/winetricks/msls31/InstMsiW.exe   https://example.com/InstMsiW.exe

# 重新执行
winetricks riched20

三、下载并安装微信 PC 客户端

1. 获取微信安装包

前往微信官网,下载 PC 版安装程序 WeChatSetup.exe
微信 PC 版下载

2. 运行安装程序

wine WeChatSetup.exe
  1. 选择默认安装路径,按提示完成安装。
  2. 安装完成后,可在 Wine 应用菜单或 ~/.wine/drive_c/Program Files/Tencent/WeChat 目录下找到 微信 程序。

四、验证与调试

1. 启动微信并查看版本

wine "C:\Program Files\Tencent\WeChat\WeChat.exe"

启动后,在“关于微信”中可查看版本号(示例:3.4.5.123)。

安装完成,查看版本号

2. 系统信息确认

确保你的 Ubuntu 系统版本与本文匹配:

lsb_release -a

示例输出:

No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 20.04.2 LTS
Release:        20.04
Codename:       focal

Ubuntu 系统信息


五、常见问题与优化

  1. 输入框不可见

    • 确保已正确安装 riched20

      winetricks riched20
      
  2. 字体渲染模糊

    • 安装 Windows 默认字体:

      winetricks corefonts
      
  3. 无法接收声音通知

    • 安装音频支持:

      winetricks quartz
      
  4. 微信闪退或 UI 异常

    • 尝试切换 Wine Windows 版本:

      winecfg
      # 在“Applications”标签页,将 Windows 版本设置为 Windows 7 或 Windows 10
      

安装日志:


<pre><font color="#4E9A06"><b>libin@oak</b></font>:<font color="#3465A4"><b>~/clash/mysql</b></font>$ sudo apt install winetricks
[sudo] libin 的密码: 
正在读取软件包列表... 完成
正在分析软件包的依赖关系树       
正在读取状态信息... 完成       
将会同时安装下列软件:
  cabextract fuseiso libmspack0
建议安装:
  tor unrar-free | unrar
下列【新】软件包将被安装:
  cabextract fuseiso libmspack0 winetricks
升级了 0 个软件包,新安装了 4 个软件包,要卸载 0 个软件包,有 3 个软件包未被升级。
需要下载 245 kB 的归档。
解压缩后会消耗 1,323 kB 的额外空间。
您希望继续执行吗? [Y/n] y
获取:1 http://cn.archive.ubuntu.com/ubuntu focal/main amd64 libmspack0 amd64 0.10.1-2 [38.0 kB]
获取:2 http://cn.archive.ubuntu.com/ubuntu focal/universe amd64 cabextract amd64 1.9-3 [23.4 kB]
获取:3 http://cn.archive.ubuntu.com/ubuntu focal/universe amd64 fuseiso amd64 20070708-3.2build1 [19.5 kB]
获取:4 http://cn.archive.ubuntu.com/ubuntu focal/universe amd64 winetricks all 0.0+20200412-1 [164 kB]
已下载 245 kB,耗时 2(108 kB/s)<font color="#C4A000">  </font>
正在选中未选择的软件包 libmspack0:amd64。
(正在读取数据库 ... 系统当前共安装有 221476 个文件和目录。)
准备解压 .../libmspack0_0.10.1-2_amd64.deb  ...
正在解压 libmspack0:amd64 (0.10.1-2) ...
正在选中未选择的软件包 cabextract。
准备解压 .../cabextract_1.9-3_amd64.deb  ...
正在解压 cabextract (1.9-3) ...
正在选中未选择的软件包 fuseiso。
准备解压 .../fuseiso_20070708-3.2build1_amd64.deb  ...
正在解压 fuseiso (20070708-3.2build1) ...
正在选中未选择的软件包 winetricks。
准备解压 .../winetricks_0.0+20200412-1_all.deb  ...
正在解压 winetricks (0.0+20200412-1) ...
正在设置 libmspack0:amd64 (0.10.1-2) ...
正在设置 fuseiso (20070708-3.2build1) ...
正在设置 winetricks (0.0+20200412-1) ...
正在设置 cabextract (1.9-3) ...
正在处理用于 gnome-menus (3.36.0-1ubuntu1) 的触发器 ...
正在处理用于 libc-bin (2.31-0ubuntu9.2) 的触发器 ...
正在处理用于 man-db (2.9.1-1) 的触发器 ...
正在处理用于 desktop-file-utils (0.24-1ubuntu3) 的触发器 ...
正在处理用于 mime-support (3.64ubuntu1) 的触发器 ...
正在处理用于 hicolor-icon-theme (0.17-2) 的触发器 ...
<font color="#4E9A06"><b>libin@oak</b></font>:<font color="#3465A4"><b>~/clash/mysql</b></font>$ sudo apt install wine
正在读取软件包列表... 完成
正在分析软件包的依赖关系树       
正在读取状态信息... 完成       
wine 已经是最新版 (5.0-3ubuntu1)。
wine 已设置为手动安装。
升级了 0 个软件包,新安装了 0 个软件包,要卸载 0 个软件包,有 3 个软件包未被升级。
<font color="#4E9A06"><b>libin@oak</b></font>:<font color="#3465A4"><b>~/clash/mysql</b></font>$ winetricks riched20
Executing mkdir -p /home/libin
------------------------------------------------------
You are using a 64-bit WINEPREFIX. Note that many verbs only install 32-bit versions of packages. If you encounter problems, please retest in a clean 32-bit WINEPREFIX before reporting a bug.
------------------------------------------------------
Using winetricks 20200412 - sha256sum: 7651c93e39fcb080483c38836513bf912273a87ea97d137f6b958ed3d9628c3d with wine-5.0 (Ubuntu 5.0-3ubuntu1) and WINEARCH=win64
Executing w_do_call riched20
Executing mkdir -p /home/libin
------------------------------------------------------
You are using a 64-bit WINEPREFIX. Note that many verbs only install 32-bit versions of packages. If you encounter problems, please retest in a clean 32-bit WINEPREFIX before reporting a bug.
------------------------------------------------------
Executing load_riched20 
Executing mkdir -p /home/libin/.cache/winetricks/win2ksp4
Executing cd /home/libin/.cache/winetricks/win2ksp4
Downloading https://ftp.gnome.org/mirror/archive/ftp.sunet.se/pub/security/vendor/microsoft/win2000/Service_Packs/usa/W2KSP4_EN.EXE to /home/libin/.cache/winetricks/win2ksp4
--2021-10-29 15:32:50--  https://ftp.gnome.org/mirror/archive/ftp.sunet.se/pub/security/vendor/microsoft/win2000/Service_Packs/usa/W2KSP4_EN.EXE
正在连接 127.0.0.1:7890... 已连接。
已发出 Proxy 请求,正在等待回应... 404 Not Found
2021-10-29 15:32:52 错误 404:Not Found。

Executing cd /home/libin/.cache/winetricks/win2ksp4
Downloading https://web.archive.org/web/2000/https://ftp.gnome.org/mirror/archive/ftp.sunet.se/pub/security/vendor/microsoft/win2000/Service_Packs/usa/W2KSP4_EN.EXE to /home/libin/.cache/winetricks/win2ksp4
--2021-10-29 15:32:53--  https://web.archive.org/web/2000/https://ftp.gnome.org/mirror/archive/ftp.sunet.se/pub/security/vendor/microsoft/win2000/Service_Packs/usa/W2KSP4_EN.EXE
正在连接 127.0.0.1:7890... 已连接。
已发出 Proxy 请求,正在等待回应... 302 FOUND
位置:https://web.archive.org/web/20180613014937/https://ftp.gnome.org/mirror/archive/ftp.sunet.se/pub/security/vendor/microsoft/win2000/Service_Packs/usa/W2KSP4_EN.EXE [跟随至新的 URL]
--2021-10-29 15:32:56--  https://web.archive.org/web/20180613014937/https://ftp.gnome.org/mirror/archive/ftp.sunet.se/pub/security/vendor/microsoft/win2000/Service_Packs/usa/W2KSP4_EN.EXE
再次使用存在的到 web.archive.org:443 的连接。
已发出 Proxy 请求,正在等待回应... 302 Found
位置:https://web.archive.org/web/20180613014937/https://saimei.ftp.acc.umu.se/mirror/archive/ftp.sunet.se/pub/security/vendor/microsoft/win2000/Service_Packs/usa/W2KSP4_EN.EXE [跟随至新的 URL]
--2021-10-29 15:32:56--  https://web.archive.org/web/20180613014937/https://saimei.ftp.acc.umu.se/mirror/archive/ftp.sunet.se/pub/security/vendor/microsoft/win2000/Service_Packs/usa/W2KSP4_EN.EXE
再次使用存在的到 web.archive.org:443 的连接。
已发出 Proxy 请求,正在等待回应... 302 FOUND
位置:https://web.archive.org/web/20180613014941/https://saimei.ftp.acc.umu.se/mirror/archive/ftp.sunet.se/pub/security/vendor/microsoft/win2000/Service_Packs/usa/W2KSP4_EN.EXE [跟随至新的 URL]
--2021-10-29 15:32:57--  https://web.archive.org/web/20180613014941/https://saimei.ftp.acc.umu.se/mirror/archive/ftp.sunet.se/pub/security/vendor/microsoft/win2000/Service_Packs/usa/W2KSP4_EN.EXE
再次使用存在的到 web.archive.org:443 的连接。
已发出 Proxy 请求,正在等待回应... 200 OK
长度: 未指定 [application/x-msdownload]
正在保存至: “W2KSP4_EN.EXE”

W2KSP4_EN.EXE           [                &lt;=&gt; ] 129.20M   564KB/s    用时 3m 23s

2021-10-29 15:36:21 (652 KB/s) - “W2KSP4_EN.EXE” 已保存 [135477136]

Executing cd /home/libin/clash/mysql
Executing cabextract -q -d /home/libin/.wine/dosdevices/c:/windows/temp -L -F i386/riched20.dl_ /home/libin/.cache/winetricks/win2ksp4/W2KSP4_EN.EXE
Executing cabextract -q --directory=/home/libin/.wine/dosdevices/c:/windows/syswow64 /home/libin/.wine/dosdevices/c:/windows/temp/i386/riched20.dl_
Using native,builtin override for following DLLs: riched20
Executing wine regedit C:\windows\Temp\override-dll.reg
Executing wine64 regedit C:\windows\Temp\override-dll.reg
Executing w_do_call msls31
Executing mkdir -p /home/libin
------------------------------------------------------
You are using a 64-bit WINEPREFIX. Note that many verbs only install 32-bit versions of packages. If you encounter problems, please retest in a clean 32-bit WINEPREFIX before reporting a bug.
------------------------------------------------------
Executing load_msls31 
Executing mkdir -p /home/libin/.cache/winetricks/msls31
Executing cd /home/libin/.cache/winetricks/msls31
Downloading https://ftp.hp.com/pub/softlib/software/msi/InstMsiW.exe to /home/libin/.cache/winetricks/msls31
--2021-10-29 15:36:24--  https://ftp.hp.com/pub/softlib/software/msi/InstMsiW.exe
正在连接 127.0.0.1:7890... 已连接。
已发出 Proxy 请求,正在等待回应... 301 Moved Permanently
位置:https://ftp.ext.hp.com/pub/softlib/software/msi/InstMsiW.exe [跟随至新的 URL]
--2021-10-29 15:36:26--  https://ftp.ext.hp.com/pub/softlib/software/msi/InstMsiW.exe
正在连接 127.0.0.1:7890... 已连接。
已发出 Proxy 请求,正在等待回应... 404 Not Found
2021-10-29 15:36:27 错误 404:Not Found。

Executing cd /home/libin/.cache/winetricks/msls31
Downloading https://web.archive.org/web/2000/https://ftp.hp.com/pub/softlib/software/msi/InstMsiW.exe to /home/libin/.cache/winetricks/msls31
--2021-10-29 15:36:27--  https://web.archive.org/web/2000/https://ftp.hp.com/pub/softlib/software/msi/InstMsiW.exe
正在连接 127.0.0.1:7890... 已连接。
已发出 Proxy 请求,正在等待回应... 302 FOUND
位置:https://web.archive.org/web/20180612201004/http://ftp.hp.com/pub/softlib/software/msi/InstMsiW.exe [跟随至新的 URL]
--2021-10-29 15:36:28--  https://web.archive.org/web/20180612201004/http://ftp.hp.com/pub/softlib/software/msi/InstMsiW.exe
再次使用存在的到 web.archive.org:443 的连接。
已发出 Proxy 请求,正在等待回应... 301 Moved Permanently
位置:https://web.archive.org/web/20180612201004/http://whp-aus2.cold.extweb.hp.com/pub/softlib/software/msi/InstMsiW.exe [跟随至新的 URL]
--2021-10-29 15:36:29--  https://web.archive.org/web/20180612201004/http://whp-aus2.cold.extweb.hp.com/pub/softlib/software/msi/InstMsiW.exe
再次使用存在的到 web.archive.org:443 的连接。
已发出 Proxy 请求,正在等待回应... 302 FOUND
位置:https://web.archive.org/web/20180612201007/http://whp-aus2.cold.extweb.hp.com/pub/softlib/software/msi/InstMsiW.exe [跟随至新的 URL]
--2021-10-29 15:36:29--  https://web.archive.org/web/20180612201007/http://whp-aus2.cold.extweb.hp.com/pub/softlib/software/msi/InstMsiW.exe
再次使用存在的到 web.archive.org:443 的连接。
已发出 Proxy 请求,正在等待回应... 200 OK
长度: 未指定 [application/octet-stream]
正在保存至: “InstMsiW.exe”

InstMsiW.exe            [            &lt;=&gt;     ]   1.74M   636KB/s    用时 2.8s  

2021-10-29 15:36:33 (636 KB/s) - “InstMsiW.exe” 已保存 [1822848]

Executing cd /home/libin/clash/mysql
Executing cabextract -q --directory=/home/libin/.wine/dosdevices/c:/windows/temp /home/libin/.cache/winetricks/msls31/InstMsiW.exe
Executing cp -f /home/libin/.wine/dosdevices/c:/windows/temp/msls31.dll /home/libin/.wine/dosdevices/c:/windows/syswow64
<font color="#4E9A06"><b>libin@oak</b></font>:<font color="#3465A4"><b>~/clash/mysql</b></font>$ winetricks riched20
Executing mkdir -p /home/libin
------------------------------------------------------
You are using a 64-bit WINEPREFIX. Note that many verbs only install 32-bit versions of packages. If you encounter problems, please retest in a clean 32-bit WINEPREFIX before reporting a bug.
------------------------------------------------------
Using winetricks 20200412 - sha256sum: 7651c93e39fcb080483c38836513bf912273a87ea97d137f6b958ed3d9628c3d with wine-5.0 (Ubuntu 5.0-3ubuntu1) and WINEARCH=win64
Executing w_do_call riched20
Executing mkdir -p /home/libin
------------------------------------------------------
You are using a 64-bit WINEPREFIX. Note that many verbs only install 32-bit versions of packages. If you encounter problems, please retest in a clean 32-bit WINEPREFIX before reporting a bug.
------------------------------------------------------
riched20 already installed, skipping
<font color="#4E9A06"><b>libin@oak</b></font>:<font color="#3465A4"><b>~/clash/mysql</b></font>$ 
</pre>

解决问题

若出现中文显示未乱码方块的问题,解决方式如下

Windows 支持字体链接:当一种字体中不存在某个字时,可以尝试从另一个字体文件中寻找相应的字形。所以只要把当前系统中的中文字体设为"fallback"字体,汉字通常就能正确显示了。方法也很简单,只需创建一个文本文件 chn_font.reg,内容如下:

REGEDIT4

[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\FontLink\SystemLink]
“Lucida Sans Unicode”=“wqy-microhei.ttc”
“Microsoft Sans Serif”=“wqy-microhei.ttc”
“MS Sans Serif”=“wqy-microhei.ttc”
“Tahoma”=“wqy-microhei.ttc”
“Tahoma Bold”=“wqy-microhei.ttc”
“SimSun”=“wqy-microhei.ttc”
“Arial”=“wqy-microhei.ttc”
“Arial Black”=“wqy-microhei.ttc”
regedit chn_font.reg
————————————————

六、总结

通过以上步骤,你已在 Ubuntu 20.04.2 LTS 上成功搭建微信 PC 版运行环境:

  1. 检测并安装 Wine
  2. 安装 Winetricks 并修复 RichEdit
  3. 下载并执行 WeChat 安装包
  4. 验证版本并做基础优化

希望这篇超详细全流程指南,能让你在 Linux 世界中也能畅快使用微信。如有更多问题,欢迎留言讨论!🎉

### 如何在 Ubuntu 20.04安装微信 #### 使用 Ukylin WeChat 安装包 对于希望使用由 UKylin 提供的 WeChat 版本,可以按照如下方法操作: 通过命令行下载并安装依赖项以及 WeChat 的 DEB 文件。这涉及到两个主要组件:`ukylin-wine` 和 `ukylin-wechat`。 ```bash sudo apt-get install -f -y ./ukylin-wine_70.6.3.25_amd64.deb sudo apt-get install -f -y ./ukylin-wechat_3.0.0_amd64.deb ``` 上述命令会自动处理所有必要的依赖关系,并完成 WeChat 的安装过程[^1]。 #### 利用 AtzLinux 方法部署官方版本 另一种更为推荐的方式是采用 AtzLinux 所提供的方案来获取最新版的官方微信客户端。此流程涉及几个额外步骤以确保系统的兼容性和软件源的安全更新。 首先,需导入 AtzLinux 的 GPG 密钥环文件以便验证后续下载的内容真实性: ```bash wget -c -O atzlinux-v12-archive-keyring_latest_all.deb https://www.atzlinux.com/atzlinux/pool/main/a/atzlinux-archive-keyring/atzlinux-v12-archive-keyring_latest_all.deb sudo apt -y install ./atzlinux-v12-archive-keyring_latest_all.deb ``` 接着刷新本地仓库缓存并将当前发行版信息备份到特定位置用于区分配置环境: ```bash sudo apt update sudo cp /etc/lsb-release /etc/lsb-release.Ubuntu ``` 最后依次执行以下指令来安装图标集和支持库,最终实现 WeChat 应用程序本身的安装: ```bash sudo apt -y install electronic-wechat-icons-atzlinux sudo apt -y install com.tencent.wechat sudo cp /etc/lsb-release /etc/lsb-release.wechat ``` 这种方法不仅简化了安装步骤还保证了应用能够跟随系统正常升级而不出现问题[^3]。 #### 可选路径——GitHub 发布页面上的 Deb 包 如果倾向于直接从开发者处获得资源,则可以从 GitHub 获取预编译好的 `.deb` 文件来进行手动安装。这种方式适合那些想要测试新功能或是偏好于保持独立性的用户群体。 访问 [lovechoudoufu/wechat_for_linux](https://github.com/lovechoudoufu/wechat_for_linux/releases) 并找到适用于 Linux x86_64 架构下的最新稳定版本链接(例如 `weixin_2.1.1_amd64.deb`),之后利用浏览器或命令行工具将其保存至本地磁盘再进行常规方式的双击打开或者通过终端运行下面这条语句完成整个设置工作: ```bash sudo dpkg -i weixin_2.1.1_amd64.deb; sudo apt --fix-broken install ``` 以上就是三种不同的途径让用户能够在基于 Debian 的操作系统如 Ubuntu 20.04 LTS 中成功架设起腾讯公司的即时通讯产品—WeChat[^4]。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

猫头虎

一分也是爱,打赏博主成就未来!

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值