简体   繁体   English

JDK x64和JRE x86应用程序打开

[英]JDK x64 and JRE x86 application open

If I have JDK x64 installed and I make application, can I run it with JRE x86, or it just compiles application to be x64? 如果我安装了JDK x64并制作了应用程序,那么我可以在JRE x86上运行它,还是仅将应用程序编译为x64? Also can I run eclipse x64 with JDK x86, or eclipse x86 with JDK x64? 我还可以在JDK x86上运行eclipse x64,或者在JDK x64上运行eclipse x86吗?

Java bytecode is platform-independent. Java字节码与平台无关。 Java code compiled with a 64-bit JDK works on a 32-bit JRE and vice versa - there is no difference in the bytecode. 用64位JDK编译的Java代码可以在32位JRE上运行,反之亦然-字节码没有区别。

You do not need to compile your Java code for 32-bit or 64-bit. 您无需为32位或64位编译Java代码。

You don't need to download and install JDK and JRE together, JDK installation package has it's own JRE installation inside. 您无需一起下载并安装JDK和JRE,JDK安装包内部具有它自己的JRE安装。 So you need to install JDK only so things won't get messy talking compatibility wise. 因此,您只需要安装JDK,这样就不会出现混乱的兼容性问题。

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

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