[英]Convert Windows Java Commands to Linux Java Commands?
I have the following text in a BAT files so I java program in windows. 我在BAT文件中有以下文本,所以我在Windows中编写java程序。 I was wondering how you can do this in linux.
我想知道如何在linux中做到这一点。
File 1: 档案1:
"C:\Program Files (x86)\Java\jdk1.6.0_23\bin\javac.exe" -sourcepath src -classpath bin;deps\jml-1.0b3-full.jar;deps\mail.jar -d bin src/*.java
File 2: 文件2:
"C:\Program Files (x86)\Java\jdk1.6.0_23\bin\java.exe" -Xmx1536m -classpath bin;deps\jml-1.0b3-full.jar;deps\mail.jar HelloWorld
Id really appreciate it if someone would convert those to linux commands. 如果有人将这些转换为linux命令,我真的很感激。
Thanks :D 感谢:D
;
;
to :
as classpath separator :
作为classpath分隔符 /
/
.sh
.sh
that should be it. 那应该是它。
The options to java
and javac
are the same on all platforms. java
和javac
的选项在所有平台上都是相同的。 The only things that will change are the file path, for eg. 唯一会改变的是文件路径,例如。
deps\\mail.jar
might become deps/mail.jar
; deps\\mail.jar
可能会成为deps/mail.jar
; and the classpath separator, :
(colon) instead of ;
和classpath分隔符,
:
冒号)而不是;
(semicolon). (分号)。
check if java SDK (java-1.6.0-openjdk-devel or Sun) exists and in the PATH 检查java SDK(java-1.6.0-openjdk-devel或Sun)是否存在并且在PATH中
which javac
Next put the same options 接下来放相同的选项
javac -sourcepath .. javac -sourcepath ..
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.