Better support for third-party JREs
Hallo all, from time to time I got the complaints from the users want to use our Java packages, but not the JVM itself. As Oracle retired the permission to distribute their own JVM, most of the users want to manually install the Oracle JVM instead of openjdk we distribute. In a past, we have changed a logic of alljava.sh, so it search for jvm in /usr/java/latest and /usr/java as well, so can setup the proper JAVA_HOME for third-party JVM. The next unsolved problem are dependencies. In a bug#776951 I've got an proposal to introduce the fake package with java, but I do not like that approach. We don't need to deal with a dependencies at all, if we intentionally break them. https://bugzilla.novell.com/show_bug.cgi?id=776951 Instead of it, I propose following - change all Requires: java in openSUSE:Factory to Recommends: java. For default openSUSE setup, it won't make any difference. For people wanting to have third-party java installed, they can add lock for distributed JVMs and put their preffered JVM. There is only one problem - users can turn the recommends off, but I don't see that as a probable case for Java software, so I would go forward. Any objections, or other ways to go? Regards Michal Vyskocil
On 19 September 2012 15:09, Michal Vyskocil <mvyskocil@suse.cz> wrote:
Instead of it, I propose following - change all Requires: java in openSUSE:Factory to Recommends: java. For default openSUSE setup, it won't make any difference. For people wanting to have third-party java installed, they can add lock for distributed JVMs and put their preffered JVM.
There is only one problem - users can turn the recommends off, but I don't see that as a probable case for Java software, so I would go forward.
Any objections, or other ways to go?
So third-party JREs RPM's don't provide "java"? What about Requires: %{_bindir}/java ? -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Content-ID: <alpine.LNX.2.00.1209191645491.10915@Telcontar.valinor> On Wednesday, 2012-09-19 at 16:09 +0200, Michal Vyskocil wrote:
Any objections, or other ways to go?
Allow me to explain the problem from my point of view. We can not get updates for the "java-1_6_0-sun" package. Instead, we can install "jre-6u33-linux-amd64.rpm", which rpm lists as "jre-1.6.0_33-fcs.x86_64". The problem is that the system (yast) does not recognize this package as a valid java, and insists on installing java-1_6_0-openjdk or others, and we have to keep and update two versions of java that I do not want or need. What I want is simply an empty rpm in place of the original (12.1, 11.4) java-1_6_0-sun, with the appropriate requires, provides, etc fields (which I know nothing about) so that yast is fooled. And I can install jre from oracle and use it. That would be enough. If you feel interested, you could instead provide a package like the one that fetches the MS fonts, fetching java instead. (the point of why we want jre is not the issue now) - -- Cheers, Carlos E. R. (from 12.1 x86_64 "Asparagus" at Telcontar) -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.18 (GNU/Linux) iEYEARECAAYFAlBZ3fcACgkQtTMYHG2NR9UAeACghtZA+2UfHLKRaXMokJOAHWo5 m3YAoIL7f+UNP2tnwSPvIgi3VFhZkL+f =n+mv -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 2012-09-19 17:00, Carlos E. R. wrote:
Content-ID: <alpine.LNX.2.00.1209191645491.10915@Telcontar.valinor>
On Wednesday, 2012-09-19 at 16:09 +0200, Michal Vyskocil wrote:
Any objections, or other ways to go?
Allow me to explain the problem from my point of view.
Let me point again that the problem is not installing and running the java from oracle, not at all, contrary to what posters so far suggest. The problem is making yast, zypper, etc, accept the JRE rpm from oracle as a valid java and stop proposing install another java instead. - -- Cheers / Saludos, Carlos E. R. (from 12.1 x86_64 "Asparagus" at Telcontar) -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.18 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://www.enigmail.net/ iEYEARECAAYFAlBZ+0AACgkQIvFNjefEBxrt6wCgsY+OFeIxAN+2iZe1cDynz0c/ mhoAn06r2I9u5JOExVOESbNcI0MiCtW1 =exNw -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
On Wed, Sep 19, 2012 at 11:00 AM, Carlos E. R. <carlos.e.r@opensuse.org> wrote:
If you feel interested, you could instead provide a package like the one that fetches the MS fonts, fetching java instead.
(the point of why we want jre is not the issue now)
Other distributions are doing this. I have been in touch with Marcus Meissner about it and he said he was going to ask the legal folks if it was OK, although I never saw a response. -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
Dude the only thing you need to do to use the Sun JVM is to export the JAVA_HOME... how hard can that be ? for example: echo "export JAVA_HOME=\"/usr/lib/default\"" > /etc/profile.d/java-sun.sh That .sh file is sourced so it doesn't need to be 0755. There's nothing you can do to suppor the stuff from sun... It's not even packaged according to jpackage... and worst... it comes with Epoch set to 2000, while historically jpackage is set to 1. People who want to user vendor stuff should learn to use it. (my opinion) There's almost 3000 lines of scripts in Oracle/Sun check them out: rpm -q(p) --scripts jdk*.rpm 2012/9/19 Michal Vyskocil <mvyskocil@suse.cz>:
Hallo all,
from time to time I got the complaints from the users want to use our Java packages, but not the JVM itself. As Oracle retired the permission to distribute their own JVM, most of the users want to manually install the Oracle JVM instead of openjdk we distribute.
In a past, we have changed a logic of alljava.sh, so it search for jvm in /usr/java/latest and /usr/java as well, so can setup the proper JAVA_HOME for third-party JVM.
The next unsolved problem are dependencies. In a bug#776951 I've got an proposal to introduce the fake package with java, but I do not like that approach. We don't need to deal with a dependencies at all, if we intentionally break them.
https://bugzilla.novell.com/show_bug.cgi?id=776951
Instead of it, I propose following - change all Requires: java in openSUSE:Factory to Recommends: java. For default openSUSE setup, it won't make any difference. For people wanting to have third-party java installed, they can add lock for distributed JVMs and put their preffered JVM.
There is only one problem - users can turn the recommends off, but I don't see that as a probable case for Java software, so I would go forward.
Any objections, or other ways to go?
Regards Michal Vyskocil
-- --- Artigo 21 - Direito à Resistência Todos têm o direito de resistir a qualquer ordem que ofensa os seus direitos, liberdades e garantias e de repelir pela força qualquer agressão, quando não seja possível recorrer à autoridade pública. Constituição da Républica Portuguesa -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
Check the path I'm not sure if it's /usr/lib/java or /usr/share/java, but the default link is managed by %post scripts. I'll report the good values in a few minutes when I get back home. 2012/9/19 Nelson Marques <nmo.marques@gmail.com>:
Dude the only thing you need to do to use the Sun JVM is to export the JAVA_HOME... how hard can that be ?
for example:
echo "export JAVA_HOME=\"/usr/lib/default\"" > /etc/profile.d/java-sun.sh
That .sh file is sourced so it doesn't need to be 0755.
There's nothing you can do to suppor the stuff from sun... It's not even packaged according to jpackage... and worst... it comes with Epoch set to 2000, while historically jpackage is set to 1.
People who want to user vendor stuff should learn to use it. (my opinion)
There's almost 3000 lines of scripts in Oracle/Sun check them out: rpm -q(p) --scripts jdk*.rpm
2012/9/19 Michal Vyskocil <mvyskocil@suse.cz>:
Hallo all,
from time to time I got the complaints from the users want to use our Java packages, but not the JVM itself. As Oracle retired the permission to distribute their own JVM, most of the users want to manually install the Oracle JVM instead of openjdk we distribute.
In a past, we have changed a logic of alljava.sh, so it search for jvm in /usr/java/latest and /usr/java as well, so can setup the proper JAVA_HOME for third-party JVM.
The next unsolved problem are dependencies. In a bug#776951 I've got an proposal to introduce the fake package with java, but I do not like that approach. We don't need to deal with a dependencies at all, if we intentionally break them.
https://bugzilla.novell.com/show_bug.cgi?id=776951
Instead of it, I propose following - change all Requires: java in openSUSE:Factory to Recommends: java. For default openSUSE setup, it won't make any difference. For people wanting to have third-party java installed, they can add lock for distributed JVMs and put their preffered JVM.
There is only one problem - users can turn the recommends off, but I don't see that as a probable case for Java software, so I would go forward.
Any objections, or other ways to go?
Regards Michal Vyskocil
-- --- Artigo 21 - Direito à Resistência
Todos têm o direito de resistir a qualquer ordem que ofensa os seus direitos, liberdades e garantias e de repelir pela força qualquer agressão, quando não seja possível recorrer à autoridade pública.
Constituição da Républica Portuguesa
-- --- Artigo 21 - Direito à Resistência Todos têm o direito de resistir a qualquer ordem que ofensa os seus direitos, liberdades e garantias e de repelir pela força qualquer agressão, quando não seja possível recorrer à autoridade pública. Constituição da Républica Portuguesa -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 2012-09-19 18:31, Nelson Marques wrote:
Dude the only thing you need to do to use the Sun JVM is to export the JAVA_HOME... how hard can that be ?
Have you tried? I will repeat here the post where I related what happened: +++····················· As we know, openSUSE no longer provides updates for Java from Sun. We can install the JRE rpm from them, and remove the java-1_6 rpm, because JRE is an update of that one - but yast does not recognizes it as an update, and wants to install icetea-web. I had to taboo it. Then yast insisted and tried to install java-1_6_0_opnjdk. Again I said no and tabooed it. Then Yast insisted and wanted to install gcc-ijj - more or less in that order. I also tabooed it. Then YaST got mad at me and wanted to remove openoffice, and I told it to &&%%·$ itself and break dependencies. ·····················++- - -- Cheers / Saludos, Carlos E. R. (from 12.1 x86_64 "Asparagus" at Telcontar) -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.18 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://www.enigmail.net/ iEYEARECAAYFAlBZ9mgACgkQIvFNjefEBxqH1gCdGSoW1K0onAbm6AIyLxorCsDj VMwAn2F1Qm90Wczxqc+Ex566ZxCPD8by =q0Ea -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
On Wed, Sep 19, 2012 at 05:31:25PM +0100, Nelson Marques wrote:
Dude the only thing you need to do to use the Sun JVM is to export the JAVA_HOME... how hard can that be ?
Well, from openSUSE 12.2 /etc/profile.d/alljava.sh already check jvm at /usr/java/latest and /usr/java, which is the default path of Oracle JVM.
for example:
echo "export JAVA_HOME=\"/usr/lib/default\"" > /etc/profile.d/java-sun.sh
That .sh file is sourced so it doesn't need to be 0755.
There's nothing you can do to suppor the stuff from sun... It's not even packaged according to jpackage... and worst... it comes with Epoch set to 2000, while historically jpackage is set to 1.
I am thinking about allowing end-users to have our little Java stack (ant, tomcat, ...) installed together with any proprietary JVM. But considering all consequences of others things, maybe the fake package - java-7-null??? to satisfy the dependencies does not sounds that bad ... Regards Michal Vyskocil -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
2012/9/24 Michal Vyskocil <mvyskocil@suse.cz>:
On Wed, Sep 19, 2012 at 05:31:25PM +0100, Nelson Marques wrote:
Dude the only thing you need to do to use the Sun JVM is to export the JAVA_HOME... how hard can that be ?
Well, from openSUSE 12.2 /etc/profile.d/alljava.sh already check jvm at /usr/java/latest and /usr/java, which is the default path of Oracle JVM.
for example:
echo "export JAVA_HOME=\"/usr/lib/default\"" > /etc/profile.d/java-sun.sh
That .sh file is sourced so it doesn't need to be 0755.
There's nothing you can do to suppor the stuff from sun... It's not even packaged according to jpackage... and worst... it comes with Epoch set to 2000, while historically jpackage is set to 1.
I am thinking about allowing end-users to have our little Java stack (ant, tomcat, ...) installed together with any proprietary JVM.
But considering all consequences of others things, maybe the fake package - java-7-null??? to satisfy the dependencies does not sounds that bad ...
Check how Sun JDK and JRE act together, specially at scripting level and how they manage the symlinks :) Yes I know that JDK also provides JRE but users will be able to install both packages also, and in that case you should contemplate that scenario and make sure your dummy packages and scriptage can handle that particular situation :) -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
On Mon, Sep 24, 2012 at 8:34 AM, Nelson Marques <nmo.marques@gmail.com> wrote:
Check how Sun JDK and JRE act together, specially at scripting level and how they manage the symlinks :) Yes I know that JDK also provides JRE but users will be able to install both packages also, and in that case you should contemplate that scenario and make sure your dummy packages and scriptage can handle that particular situation :)
Conflicts? -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
2012/9/24 Claudio Freire <klaussfreire@gmail.com>:
On Mon, Sep 24, 2012 at 8:34 AM, Nelson Marques <nmo.marques@gmail.com> wrote:
Check how Sun JDK and JRE act together, specially at scripting level and how they manage the symlinks :) Yes I know that JDK also provides JRE but users will be able to install both packages also, and in that case you should contemplate that scenario and make sure your dummy packages and scriptage can handle that particular situation :)
Conflicts?
Conflicts where? You can't change Oracle packages man; So from that point of view, users will always be able to install both oracle packages... Where do you want to insert the Conflicts? :) Furthermore... Which version of Oracle are you going to support? 1.7.0 with those nasty bugs and a few zero day exploits in the wilderness ?... What about if users dont want 1.7.0 and something else ? Really, I honestly want to see how a distribution fixes this kind of issue... -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
2012/9/24 Nelson Marques <nmo.marques@gmail.com>:
2012/9/24 Claudio Freire <klaussfreire@gmail.com>:
On Mon, Sep 24, 2012 at 8:34 AM, Nelson Marques <nmo.marques@gmail.com> wrote:
Check how Sun JDK and JRE act together, specially at scripting level and how they manage the symlinks :) Yes I know that JDK also provides JRE but users will be able to install both packages also, and in that case you should contemplate that scenario and make sure your dummy packages and scriptage can handle that particular situation :)
Conflicts?
Conflicts where? You can't change Oracle packages man; So from that point of view, users will always be able to install both oracle packages... Where do you want to insert the Conflicts? :) Furthermore... Which version of Oracle are you going to support? 1.7.0 with those nasty bugs and a few zero day exploits in the wilderness ?... What about if users dont want 1.7.0 and something else ?
Really, I honestly want to see how a distribution fixes this kind of issue...
I'm specially eager to see people who might want to build stuff against JNI from Oracle packages and how it goes after on dependency resolution. I look forward to see how people can fix all the potential trouble and how long it will take :) -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
On Mon, Sep 24, 2012 at 1:32 PM, Nelson Marques <nmo.marques@gmail.com> wrote:
On Mon, Sep 24, 2012 at 8:34 AM, Nelson Marques <nmo.marques@gmail.com> wrote:
Check how Sun JDK and JRE act together, specially at scripting level and how they manage the symlinks :) Yes I know that JDK also provides JRE but users will be able to install both packages also, and in that case you should contemplate that scenario and make sure your dummy packages and scriptage can handle that particular situation :)
Conflicts?
Conflicts where? You can't change Oracle packages man; So from that point of view, users will always be able to install both oracle packages... Where do you want to insert the Conflicts? :)
The dummy package. You have the jdk-dummy and the jre-dummy, you can make them conflict with each other. jdk-dummy provides what Oracle's jdk doesn't for openSUSE packages, and requires Oracle's jdk, making it a bridge between the two packages. You cannot install both bridges, because they conflict. You *can* install both of Oracle's rpms, but you cannot do so as a replacement to the distribution's packages (which is what the dummy packages do). About the JNI stuff... I don't know about that. The only JNI stuff I used were gtk bindings with eclipse, and I've never had any trouble switching VMs at will. That doesn't rule out problems though. But, presumably, he who replaces the JVM/JDK "knows what he's doing". -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
The dummy package. You have the jdk-dummy and the jre-dummy, you can make them conflict with each other. jdk-dummy provides what Oracle's jdk doesn't for openSUSE packages, and requires Oracle's jdk, making it a bridge between the two packages. You cannot install both bridges, because they conflict.
This is where the problem starts, because Oracle rpms don't provide anything; I'll show a quick example... You build a piece of software (lets say a library) that links on JNI; for every single package you will have a lot of pre/post streaming filtering to do... Else they won't resolve (something the dummy packages will fix?)... Now the dummy packages insert all this dependencies; Then you will have dependencies overlapping, ones from openJDK, others from your dummy packages (e.g. the JNI shared objects). So you are duplicating dependencies, from which one of the packages (your dummy one) won't be able to resolve properly because you don't have Oracle stuff in repository (are you allowed to re-distribute the Oracle RPMs ?. If you support that stuff and you actually have a lot of develpors, they will create a (like Linus says) unholy mess; which you will have to support... And you can never support Oracle RPMs (and why should we? it's really OSI friendly).
You *can* install both of Oracle's rpms, but you cannot do so as a replacement to the distribution's packages (which is what the dummy packages do).
Install them from where ? :)
About the JNI stuff... I don't know about that. The only JNI stuff I used were gtk bindings with eclipse, and I've never had any trouble switching VMs at will. That doesn't rule out problems though. But, presumably, he who replaces the JVM/JDK "knows what he's doing".
That's what JNI is there to; to make sure that you have some sort of compatibility layer to use any vendor JVM (so far it's working properly, I would risk to say (blindly) that 95% of the stuff will work OK). But the problem is... When you build an RPM, it's internal dependency generator will most likely add dependencies to the JNI shared objects, which the Oracle rpm doesn't provide... This has some solutions... being one of them that the dependency is offered by your dummy package, and the other is post/pre streaming filtering. Neither of this seems reasonable to me for a wide environment like a distribution (while in a corporate environment you can twist and bend all the rules to your needs). Like I said, I would love to see this working (maybe I can learn something from it), but I think it's going to be a nightmare to maintain in a Linux distribution as Oracle hasn't really made life easier for people. Also you might have to deal with the Epochs on JDK, which is nice enough :)... I have to say one thing, I like people with determination and crazy thoughts, so I'll help testing in any way I can :) NM -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
On Mon, Sep 24, 2012 at 3:27 PM, Nelson Marques <nmo.marques@gmail.com> wrote:
But the problem is... When you build an RPM, it's internal dependency generator will most likely add dependencies to the JNI shared objects, which the Oracle rpm doesn't provide...
Ah, I see... and we certainly don't want to break our packages to support Oracle's. -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
2012/9/24 Claudio Freire <klaussfreire@gmail.com>:
On Mon, Sep 24, 2012 at 3:27 PM, Nelson Marques <nmo.marques@gmail.com> wrote:
But the problem is... When you build an RPM, it's internal dependency generator will most likely add dependencies to the JNI shared objects, which the Oracle rpm doesn't provide...
Ah, I see... and we certainly don't want to break our packages to support Oracle's.
Well I have faith it can be done, but I think it's hard to do it without generating turmoil here and there. Lets just wait and see :) -- To unsubscribe, e-mail: opensuse-java+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-java+owner@opensuse.org
participants (7)
-
Andrew Joakimsen
-
Carlos E. R.
-
Carlos E. R.
-
Claudio Freire
-
Cristian Morales Vega
-
Michal Vyskocil
-
Nelson Marques