What is the difference between OpenJDK and Oracle JDK?
I was building Android apps on Android Studio when it asked me to remove OpenJDK and install Oracle JDK. Now, I was using OpenJDK for building Cyanogenmod.
If I wipe off OpenJDK and install Oracle JDK, would CM builds break?
java android jdk
add a comment |
I was building Android apps on Android Studio when it asked me to remove OpenJDK and install Oracle JDK. Now, I was using OpenJDK for building Cyanogenmod.
If I wipe off OpenJDK and install Oracle JDK, would CM builds break?
java android jdk
2
Possible duplicate of How can I install Sun/Oracle's proprietary Java JDK 6/7/8 or JRE?
– user364819
Oct 25 '15 at 9:56
add a comment |
I was building Android apps on Android Studio when it asked me to remove OpenJDK and install Oracle JDK. Now, I was using OpenJDK for building Cyanogenmod.
If I wipe off OpenJDK and install Oracle JDK, would CM builds break?
java android jdk
I was building Android apps on Android Studio when it asked me to remove OpenJDK and install Oracle JDK. Now, I was using OpenJDK for building Cyanogenmod.
If I wipe off OpenJDK and install Oracle JDK, would CM builds break?
java android jdk
java android jdk
edited Dec 12 at 9:40
asked Oct 25 '15 at 9:47
ideaman924
21119
21119
2
Possible duplicate of How can I install Sun/Oracle's proprietary Java JDK 6/7/8 or JRE?
– user364819
Oct 25 '15 at 9:56
add a comment |
2
Possible duplicate of How can I install Sun/Oracle's proprietary Java JDK 6/7/8 or JRE?
– user364819
Oct 25 '15 at 9:56
2
2
Possible duplicate of How can I install Sun/Oracle's proprietary Java JDK 6/7/8 or JRE?
– user364819
Oct 25 '15 at 9:56
Possible duplicate of How can I install Sun/Oracle's proprietary Java JDK 6/7/8 or JRE?
– user364819
Oct 25 '15 at 9:56
add a comment |
1 Answer
1
active
oldest
votes
Look at this answer to understand the key differences between OpenJDK
and Oracle JDK
.
If you want to use Oracle Java, you have to install it as Paranoid Panda has suggested. Then you have to set your Java
environment variables by adding the following two lines to ~/.bashrc
export JAVA_HOME=/usr/lib/jvm/java-7-oracle
export PATH=$JAVA_HOME/bin:$PATH
If you want, you could also uninstall OpenJDK
from your machine at all. Take a look at this answer for the steps to execute to correctly delete it.
Java and Android build system are two different things. When you build an Android app, at some point it calls the Java compiler you have installed on your machine; it doesn't matter the exact type of compiler, you should only have one installed. So, when you installOracle Java
and addJAVA_HOME
to the$PATH
list, you are telling the system where to locate your Java compiler. Once done the above step, you can executewhich javac
andjavac -version
to know if the process has gone well.
– tigerjack89
Oct 26 '15 at 9:57
That being said, you can safely uninstall OpenJDK if you don't want to use it without affecting the build system used by Android.
– tigerjack89
Oct 26 '15 at 10:02
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f689642%2fwhat-is-the-difference-between-openjdk-and-oracle-jdk%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
Look at this answer to understand the key differences between OpenJDK
and Oracle JDK
.
If you want to use Oracle Java, you have to install it as Paranoid Panda has suggested. Then you have to set your Java
environment variables by adding the following two lines to ~/.bashrc
export JAVA_HOME=/usr/lib/jvm/java-7-oracle
export PATH=$JAVA_HOME/bin:$PATH
If you want, you could also uninstall OpenJDK
from your machine at all. Take a look at this answer for the steps to execute to correctly delete it.
Java and Android build system are two different things. When you build an Android app, at some point it calls the Java compiler you have installed on your machine; it doesn't matter the exact type of compiler, you should only have one installed. So, when you installOracle Java
and addJAVA_HOME
to the$PATH
list, you are telling the system where to locate your Java compiler. Once done the above step, you can executewhich javac
andjavac -version
to know if the process has gone well.
– tigerjack89
Oct 26 '15 at 9:57
That being said, you can safely uninstall OpenJDK if you don't want to use it without affecting the build system used by Android.
– tigerjack89
Oct 26 '15 at 10:02
add a comment |
Look at this answer to understand the key differences between OpenJDK
and Oracle JDK
.
If you want to use Oracle Java, you have to install it as Paranoid Panda has suggested. Then you have to set your Java
environment variables by adding the following two lines to ~/.bashrc
export JAVA_HOME=/usr/lib/jvm/java-7-oracle
export PATH=$JAVA_HOME/bin:$PATH
If you want, you could also uninstall OpenJDK
from your machine at all. Take a look at this answer for the steps to execute to correctly delete it.
Java and Android build system are two different things. When you build an Android app, at some point it calls the Java compiler you have installed on your machine; it doesn't matter the exact type of compiler, you should only have one installed. So, when you installOracle Java
and addJAVA_HOME
to the$PATH
list, you are telling the system where to locate your Java compiler. Once done the above step, you can executewhich javac
andjavac -version
to know if the process has gone well.
– tigerjack89
Oct 26 '15 at 9:57
That being said, you can safely uninstall OpenJDK if you don't want to use it without affecting the build system used by Android.
– tigerjack89
Oct 26 '15 at 10:02
add a comment |
Look at this answer to understand the key differences between OpenJDK
and Oracle JDK
.
If you want to use Oracle Java, you have to install it as Paranoid Panda has suggested. Then you have to set your Java
environment variables by adding the following two lines to ~/.bashrc
export JAVA_HOME=/usr/lib/jvm/java-7-oracle
export PATH=$JAVA_HOME/bin:$PATH
If you want, you could also uninstall OpenJDK
from your machine at all. Take a look at this answer for the steps to execute to correctly delete it.
Look at this answer to understand the key differences between OpenJDK
and Oracle JDK
.
If you want to use Oracle Java, you have to install it as Paranoid Panda has suggested. Then you have to set your Java
environment variables by adding the following two lines to ~/.bashrc
export JAVA_HOME=/usr/lib/jvm/java-7-oracle
export PATH=$JAVA_HOME/bin:$PATH
If you want, you could also uninstall OpenJDK
from your machine at all. Take a look at this answer for the steps to execute to correctly delete it.
edited May 23 '17 at 12:39
Community♦
1
1
answered Oct 25 '15 at 10:15
tigerjack89
1,72541833
1,72541833
Java and Android build system are two different things. When you build an Android app, at some point it calls the Java compiler you have installed on your machine; it doesn't matter the exact type of compiler, you should only have one installed. So, when you installOracle Java
and addJAVA_HOME
to the$PATH
list, you are telling the system where to locate your Java compiler. Once done the above step, you can executewhich javac
andjavac -version
to know if the process has gone well.
– tigerjack89
Oct 26 '15 at 9:57
That being said, you can safely uninstall OpenJDK if you don't want to use it without affecting the build system used by Android.
– tigerjack89
Oct 26 '15 at 10:02
add a comment |
Java and Android build system are two different things. When you build an Android app, at some point it calls the Java compiler you have installed on your machine; it doesn't matter the exact type of compiler, you should only have one installed. So, when you installOracle Java
and addJAVA_HOME
to the$PATH
list, you are telling the system where to locate your Java compiler. Once done the above step, you can executewhich javac
andjavac -version
to know if the process has gone well.
– tigerjack89
Oct 26 '15 at 9:57
That being said, you can safely uninstall OpenJDK if you don't want to use it without affecting the build system used by Android.
– tigerjack89
Oct 26 '15 at 10:02
Java and Android build system are two different things. When you build an Android app, at some point it calls the Java compiler you have installed on your machine; it doesn't matter the exact type of compiler, you should only have one installed. So, when you install
Oracle Java
and add JAVA_HOME
to the $PATH
list, you are telling the system where to locate your Java compiler. Once done the above step, you can execute which javac
and javac -version
to know if the process has gone well.– tigerjack89
Oct 26 '15 at 9:57
Java and Android build system are two different things. When you build an Android app, at some point it calls the Java compiler you have installed on your machine; it doesn't matter the exact type of compiler, you should only have one installed. So, when you install
Oracle Java
and add JAVA_HOME
to the $PATH
list, you are telling the system where to locate your Java compiler. Once done the above step, you can execute which javac
and javac -version
to know if the process has gone well.– tigerjack89
Oct 26 '15 at 9:57
That being said, you can safely uninstall OpenJDK if you don't want to use it without affecting the build system used by Android.
– tigerjack89
Oct 26 '15 at 10:02
That being said, you can safely uninstall OpenJDK if you don't want to use it without affecting the build system used by Android.
– tigerjack89
Oct 26 '15 at 10:02
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f689642%2fwhat-is-the-difference-between-openjdk-and-oracle-jdk%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
2
Possible duplicate of How can I install Sun/Oracle's proprietary Java JDK 6/7/8 or JRE?
– user364819
Oct 25 '15 at 9:56