Ubuntu安裝微信(Ubuntu install Wechat)
微信官方沒有直接提供Linux系統客戶端,Wine的微信不喜歡,麒麟軟件與騰訊公司聯手推動了基於Linux平臺的原生微信適配工作,提供了個deb包,不是wine的,勉強可以使用
1. 下載deb包 (download deb package)
去優麒麟的下載頁 https://www.ubuntukylin.com/applications/106-cn.html,右鍵打開瀏覽器的調試工具,找到deb包的下載地址:https://archive.ubuntukylin.com/software/pool/partner/weixin_2.1.1_amd64.deb 下載,直接點按鈕下載不了(只是刷新網頁,至少我的情況是這樣,想辦法下載下來即可)
2. 命令行安裝
-
備份/etc/lsb-release文件,該deb包會更改這個文件的內容 (backup lsb-release file)
sudo cp /etc/lsb-release /etc/lsb-release_bak
-
安裝(install)
➜ sudo dpkg -i weixin_2.1.1_amd64.deb Selecting previously unselected package weixin. (Reading database ... 294966 files and directories currently installed.) Preparing to unpack weixin_2.1.1_amd64.deb ... Unpacking weixin (2.1.1) ... Setting up weixin (2.1.1) ... Processing triggers for bamfdaemon (0.5.6+22.04.20220217-0ubuntu1) ... Rebuilding /usr/share/applications/bamf-2.index... Processing triggers for mailcap (3.70+nmu1ubuntu1) ... Processing triggers for gnome-menus (3.36.0-1ubuntu3) ... Processing triggers for desktop-file-utils (0.26-1ubuntu3) ... Processing triggers for hicolor-icon-theme (0.17-2) ...
-
還原/etc/lsb-release 文件(09/03/2023日更新:如果要使用該版本微信,請不要還原該文件,具體原因見文末
)➜ cat /etc/lsb-release DISTRIB_ID=Kylin DISTRIB_RELEASE=V10 DISTRIB_CODENAME=kylin DISTRIB_DESCRIPTION="Kylin V10 SP1" DISTRIB_KYLIN_RELEASE=V10 DISTRIB_VERSION_TYPE=enterprise DISTRIB_VERSION_MODE=normal ➜ sudo cp /etc/lsb-release_bak /etc/lsb-release ➜ cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=22.04 DISTRIB_CODENAME=jammy DISTRIB_DESCRIPTION="Ubuntu 22.04 LTS"
3. 添加英文環境軟件名 (add en name at weixin.desktop)
➜ cat /usr/share/applications/weixin.desktop
[Desktop Entry]
Name[tr]=weixin
Name[en]=Wechat # add en name if you need
Name[zh_CN]=微信
Exec=/opt/weixin/weixin %U
Terminal=false
Type=Application
Icon=weixin
StartupWMClass=weixin
Comment=微信桌面版
Categories=Utility;
添加這一行(add this line if you are english user),如果是英文環境: Name[en]=Wechat
4. 更新圖標信息 update-desktop-database (option)
➜ update-desktop-database
5. 查看結果 (Let me see see ^_^)
09/03/2023日更新:最近有讀者反饋,掃描二維碼後軟件無法登錄,經測試情況屬實,解決方式是卸載重新安裝,重新安裝後正常登錄使用, 重新安裝爲什麼可以使用呢?原來這個版本的微信會驗證 /etc/lsb-release
這文件是否爲統信,重新安裝會更改爲符合要求的內容,手動滑稽啊,這格局小了點!參見Arch wiki WeChat
1. sudo apt remove weixin
2. sudo dpkg -i weixin_2.1.1_amd64.deb
md5覈對:d6827fc8a0a86ac88a3fd0068700095e weixin_2.1.1_amd64.deb