简体   繁体   English

Manjaro Linux上的netbeans 9.0问题

[英]Problem with netbeans 9.0 on Manjaro Linux

I've been using Netbeans 8.2 on Manjaro Linux for a while with no problem at all. 我已经在Manjaro Linux上使用Netbeans 8.2一段时间了,一点问题都没有。 Today I made an update of my system and I found that it installed the new Netbeans 9.0 but since that I can't use my old 8.2 version. 今天,我对系统进行了更新,发现它安装了新的Netbeans 9.0,但是由于该原因,我无法使用旧的8.2版本。 I tried to uninstall and re-install it with no results. 我尝试卸载并重新安装,但没有结果。 So I decided to try to use the new version but everytime I try to open it by my desktop or menu icon nothing happen. 因此,我决定尝试使用新版本,但是每次尝试通过桌面或菜单图标打开它时,都不会发生任何事情。 So I tried to open it by command line and I get this message: 因此,我尝试通过命令行打开它,并得到以下消息:

Cannot read cluster file: //etc/netbeans.clusters

I'm just using Netbeans for my thesis work so I'm not an expert at all, so I would really appreciate any help. 我只是使用Netbeans进行论文研究,所以我根本不是专家,因此,我将非常感谢您的帮助。

Had same problem with freshly updated netbeans. 刚更新的Netbeans也有同样的问题。 I noticed that I had netbeans.clusters file in /usr/etc/netbeans.clusters Just copied them to etc and netbeans started... 我注意到我在/usr/etc/netbeans.clusters中netbeans.clusters文件,只是将它们复制到etc并启动了netbeans ...

cp /usr/etc/netbeans.clusters /etc/netbeans.clusters

...but it recommended me to install nb-javac library and also it had some negative effect on my home directory (got all config files in there), so this might be only temporary solution. ...但是它建议我安装nb-javac库,并且它对我的主目录也有一些负面影响(在此存在所有配置文件),因此这可能只是临时解决方案。

This same issue was recently opened on the Arch Linux bugtracker, so I know why you have this problem: https://bugs.archlinux.org/task/60533 最近在Arch Linux Bugtracker上打开了相同的问题,因此我知道您为什么会遇到此问题: https : //bugs.archlinux.org/task/60533

The doubled // is sort of suspicious, and furthermore, the file as installed by the package is in fact /usr/etc/netbeans.clusters -- which is identical except for the missing "usr" component. 翻倍的//有点可疑,此外,程序包安装的文件实际上是/usr/etc/netbeans.clusters -除了缺少“ usr”组件外,该文件是相同的。 It turns out that this is set by the netbeans startup shell script by parsing the location of the shell script (using the dirname for $0 ) and considering that to be the root of your netbeans install. 事实证明,这是由netbeans 启动shell脚本通过解析shell脚本的位置(使用$0 )并将其视为netbeans安装的根目录来设置的。 This needs to be equal to /usr in order to work properly. 为了正常工作,它必须等于/usr For reasons obvious to anyone who really groks shell, this shell script is terrible (as are most on the internet), but the important factor for you to consider is that it depends on how you ran it. 出于对真正了解shell的人显而易见的原因,该shell脚本很糟糕(与Internet上的大多数情况一样),但您要考虑的重要因素是它取决于您如何运行它。

For some reason, you're running the program via /bin/netbeans instead of /usr/bin/netbeans . 由于某些原因,您通过/bin/netbeans而不是/usr/bin/netbeans运行程序。 Probably because /bin is in your system $PATH , which is wrong and is a bug in your system. 可能是因为/bin在系统$PATH ,这是错误的,并且是系统中的错误。

The result is that the terrible netbeans shell script miscalculates the netbeans basedir as / instead of /usr , and miscalculates all resource files relative to the wrong location. 结果是可怕的netbeans shell脚本错误地将netbeans basedir计算为/而不是/usr ,并且错误地计算了相对于错误位置的所有资源文件。

Yes it can be problem of update center you need to register NetBeans 8.2 update registry: 是的,这可能是更新中心的问题,您需要注册NetBeans 8.2更新注册表:
Ref 1 , Ref 2 , Ref 3 参考1参考2参考3

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM