我正在尝试安装不和谐应用程序在 Opensuse 42.3 上。
我下载了压缩包并提取其内容。然后,我discord.desktop
通过运行命令使该文件可执行sudo chmod +x ./Discord/discord.desktop
。
然后我双击该discord.desktop
文件,但它没有成功运行。下面是打开后的窗口截图:
我尝试从命令行启动 Discord,但收到以下错误:
:~> sudo chmod +x Downloads/Discord/discord.desktop
[sudo] password for root:
:~> ./Downloads/Discord/discord.desktop
./Downloads/Discord/discord.desktop: line 1: [Desktop: command not found
./Downloads/Discord/discord.desktop: line 4: unexpected EOF while looking for matching `''
./Downloads/Discord/discord.desktop: line 10: syntax error: unexpected end of file
Discord.desktop 的内容是 -
rajkumar@linux-7owj:~> cat Downloads/Discord/discord.desktop
[Desktop Entry]
Name=Discord
StartupWMClass=discord
Comment=All-in-one voice and text chat for gamers that's free, secure, and works on both your desktop and phone.
GenericName=Internet Messenger
Exec=/usr/share/discord/Discord
Icon=discord
Type=Application
Categories=Network;InstantMessaging;
X-Session Errors 不会给出任何有用的结果。我在执行discord之前和之后尝试过
rajkumar@linux-7owj:~> tail -f ~/.xsession-errors
tail: cannot open '/home/rajkumar/.xsession-errors' for reading: No such file or directory
tail: no files remaining
以下是我的操作系统详细信息:
:~> lsb_release
LSB Version: core-2.0-noarch:core-3.2-noarch:core-4.0-noarch:core-2.0-x86_64:core-3.2-x86_64:core-4.0-x86_64:desktop-4.0-amd64:desktop-4.0-noarch:graphics-2.0-amd64:graphics-2.0-noarch:graphics-3.2-amd64:graphics-3.2-noarch:graphics-4.0-amd64:graphics-4.0-noarch
当通过使用 snap 安装 Opensuse 来启动 Discord 时,出现以下错误:
Gtk-Message: Failed to load module "canberra-gtk-module"
Discord 0.0.4
Starting updater.
[Modules] Modules initializing
[Modules] Distribution: remote
[Modules] Host updates: enabled
[Modules] Module updates: enabled
[Modules] Module install path: /home/tjiho/snap/discord/52/.config/discord/0.0.4/modules
[Modules] Module installed file path: /home/tjiho/snap/discord/52/.config/discord/0.0.4/modules/installed.json
[Modules] Module download path: /home/tjiho/snap/discord/52/.config/discord/0.0.4/modules/pending
[11045:0219/154734.826940:FATAL:platform_font_linux.cc(63)] Check failed: typeface. Could not find any font: Noto Sans, sans
#0 0x000001e57c8e <unknown>
#1 0x000001e6a80b <unknown>
#2 0x00000198780d <unknown>
#3 0x00000198744f <unknown>
#4 0x000001988106 <unknown>
#5 0x000001972469 <unknown>
#6 0x000000b3271e <unknown>
#7 0x000000d87a03 <unknown>
#8 0x000003c22106 atom::api::WebContents::InitWithSessionAndOptions()
#9 0x000003c2298f atom::api::WebContents::WebContents()
#10 0x000003c2d886 atom::api::WebContents::Create()
#11 0x000003c3fb35 atom::api::Window::Window()
#12 0x000003c4164c atom::api::Window::New()
#13 0x000003be75f0 mate::internal::InvokeNew<>()
#14 0x000003be7780 mate::internal::Dispatcher<>::DispatchToCallback()
#15 0x7f388e3e6e6f <unknown>
#16 0x7f388e7f637b <unknown>
#17 0x7f388e7f5e39 <unknown>
#18 0x0c816f2843a7 <unknown>
Aborted (core dumped)
我可以做什么来解决这个问题?
答案1
你可以使用 flatpack 安装它:
$ sudo zypper install flatpak
$ sudo flatpak remote-add --if-not-exists flathub https://dl.flathub.org/repo/flathub.flatpakrepo
$ sudo flatpak install --from https://flathub.org/repo/appstream/com.discordapp.Discord.flatpakref
然后注销并登录,您将安装 dicord
答案2
对于其他可能不想使用 flatpak 的人来说,您可能只是缺少 libc++1 软件包。我在 Ubuntu 上遇到了同样的问题。
- 完全退出 Discord(从系统托盘退出)。
安装 libc++1:
须藤 zypper 安装
这是我在 Ask Ubuntu 上提供的答案:
使用 gzip 包(Discord 0.0.4)的 XUbuntu 16.04 上也存在同样的问题。安装“libc++1”包并且 Discord 成功启动——不再有空窗口:
sudo aptitude 安装 libc++1
注意:我发现论坛帖子表明需要“libc++”并安装应包含 libc++ 的 clang 工具链包。这不起作用,所以我怀疑较新版本的 Discord 需要 libc++1 提供的较新的 libc++