linux 安装 eclipse 的靠谱步骤

本人java菜鸟,百度了无数linux安装eclipse的帖子就是不靠谱,终于在谷歌找了一篇英文帖子尝试并成功安装,相信对很多和我一样的初学者有用,原帖+翻译如下。

200 down vote accepted

If you've downloaded Eclipse from their official website, follow these steps for the installation.//从官网下eclipse压缩包

  1. Extract the eclipse.XX.YY.tar.gz using//解压eclipse 文件

    tar -zxvf eclipse.XX.YY.tar.gz
    
  2. Become root and Copy the extracted folder to /opt//移动eclipse至/opt文件夹中

    sudo mv eclipse.XX.YY /opt
    
  3. Create a desktop file and install it://创建eclipse.desktop

    gedit eclipse.desktop
    

    and copy the following to the eclipse.desktop file.//粘贴下述代码到创建的文件中

    [Desktop Entry]
    Name=Eclipse 
    Type=Application
    Exec=env UBUNTU_MENUPROXY=0 eclipse44
    Terminal=false
    Icon=eclipse
    Comment=Integrated Development Environment
    NoDisplay=false
    Categories=Development;IDE;
    Name[en]=Eclipse
    

    then execute the following command to automatically install it in the unity://使用下述命令安装eclipse.desktop

    sudo desktop-file-install eclipse.desktop
    
  4. Create a symlink in /usr/local/bin using//建立symlink 我也不懂这是个啥文件 如遇大神 请指教  拜谢

    sudo ln -s /opt/eclipse/eclipse /usr/local/bin/eclipse44
    
  5. For eclipse icon to be displayed in dash, eclipse icon can be added as

    sudo cp /opt/eclipse/icon.xpm /usr/share/pixmaps/eclipse.xpm
    
  6. Don't forget that you need to have either OpenJDK or Sun Java installed to be able to run eclipse. Check this question for more information about Java installation.Here is a simple example of installing Open JDK 1.6://不要忘记装jdk

  7. sudo apt-get install openjdk-6-jdk
    
  8. Launch eclipse and then give it the required permissions to modify the osgi file:

    sudo chown -R $USER:$USER /opt/eclipse/configuration/org.eclipse.osg  
    


结束啦!

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值