This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
we say that the compiler of java for all operating systems is the same and that only jvm differs from OS to OS . pick a bytecode from windows and execute it on linux - easy . but i had this trivial question in mind . is the compiler of java 'exactly' same for linux and windows ? i mean to say that the windows java compiler is called javac.exe , right ? but .exe don't run on linux . so maybe there is some catch involved . what say ?
By the way: note that "javac.exe" is just a little wrapper application that fires up a JVM and invokes the Sun Java compiler, which is written in Java. So in fact, they do ship the same compiler for every platform; it's just the little launcher app that must be platform-specific.
I did not know that Ernest and it is indeed interesting. Thanks.
Joined: Feb 24, 2008
oh thank you so much Ernest . i was also thinking on the same lines - the compiler code remains the same , its just the change in application that invokes the compiler ( which is needed to be platform specific ) . thank you again . javaranch is a great place to be in .