运行java而不安装jre? [英] Running java without installing jre?

查看:24
本文介绍了运行java而不安装jre?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

此处询问和回答,python有一种无需安装程序的有用部署方式.Java可以做同样的事情吗?

As asked and answered here, python has a useful way of deployment without installers. Can Java do the same thing?

  • 有没有什么方法可以在不安装jre的情况下运行Java的jar文件?
  • 是否有类似 java2exe (win32)、java2bin (linux) 或 java2app (mac) 之类的工具?

推荐答案

您可以为此使用 Launch4j.有据可查且易于使用.虽然生成的程序仍需要 JRE 才能运行,但您不必在目标系统上安装 JRE.您可以将它与您的应用程序一起复制,然后告诉 Launch4j 找到它,或者将它与其他所有内容一起打包.

You can use Launch4j for this. Well documented and easy to use. While the resulting program still needs a JRE to run, you don't have to install the JRE on the target system. You can just copy it with your application and tell Launch4j were to find it or just wrap it up with everything else.

这篇关于运行java而不安装jre?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆