Gentoo Archives: gentoo-java

From: Wiktor Wandachowicz <siryes@×××××.com>
To: gentoo-java@l.g.o
Subject: Re: [gentoo-java] migration-overlay entering main tree
Date: Wed, 28 Jun 2006 22:44:05
Message-Id: 254054bc0606281542u70501ce0u13f468b6fdfc77a4@mail.gmail.com
In Reply to: Re: [gentoo-java] migration-overlay entering main tree by Joshua Nichols
1 Here are my experiences with Java upgrade on a second machine, done step
2 after step like in the Java Upgrade Guide. Sorry for the length, but I wanted
3 to be as specific as possible.
4
5 After unmasking packages, I removed sun-jdk-1.4*, sun-jdk-1.5* and java-config.
6 Then I emerged java-config-1* and java-config-2*. All was fine. After emerging
7 the first JVM I've noticed an error:
8
9 # emerge -av =sun-jdk-1.4*
10 ...
11 !!! ERROR: The active vm could not be found
12 * After installing sun-jdk-1.4.2.12 this
13 * was set as the default JVM to run.
14 * No valid generation-1 system-vm set, setting to sun-jdk-1.4.2.12
15
16 Nothing serious that a simple "/usr/sbin/env-update && source /etc/profile"
17 couldn't resolve. And only after two last commands the "java-check-environment"
18 was able to report success with generation_1_system_vm. I double checked
19 via "java-config-1 -L" and "java-config-2 -L" that only one JVM was present at
20 the moment. All was fine.
21
22 Then I emerged sun-jdk-1.5 and run the "java-1.5-fixer". Now it became
23 interesting, because the tool reported *twice* missing packages:
24
25 # java-1.5-fixer
26 * You need to emerge portage-utils.
27 # emerge -av portage-utils
28 * You need to emerge >=javatoolkit-0.1.6
29 # emerge -av javatoolkit
30 # java-1.5-fixer
31
32 Well, that's was a little surprise, because the Guide didn't mention these
33 two packages at all. Not actually confusing for me, but the Guide could at
34 least explain that need. Less fluent Gentooers can be surprised and
35 completely unnecessary topics on the forums may arise.
36
37 Another intriguing thing was the output while emerging javatoolkit. I've seen:
38 ...
39 >>> /usr/share/doc/javatoolkit-9.9.9/
40 >>> /usr/share/doc/javatoolkit-9.9.9/sun-fetch/
41 >>> /usr/share/doc/javatoolkit-9.9.9/sun-fetch/AUTHORS
42 >>> /usr/share/doc/javatoolkit-9.9.9/sun-fetch/README
43 >>> /usr/share/doc/javatoolkit-9.9.9/COPYING
44 >>> /usr/share/doc/javatoolkit-9.9.9/NEWS
45 >>> /usr/share/doc/javatoolkit-9.9.9/findclass/
46 >>> /usr/share/doc/javatoolkit-9.9.9/findclass/AUTHORS
47 >>> /usr/share/doc/javatoolkit-9.9.9/findclass/README
48 >>> /usr/share/doc/javatoolkit-9.9.9/AUTHORS
49 >>> /usr/share/doc/javatoolkit-9.9.9/README
50 >>> /usr/share/doc/javatoolkit-9.9.9/ChangeLog
51 >>> /usr/share/doc/javatoolkit-9.9.9/TODO
52
53 even though I installed javatoolkit-0.1.9 and not -0.9.9
54
55 Last problematic thing I've noticed was the number and order of
56 packages java-fixer was about to repair:
57
58 # java-1.5-fixer
59 * Generating a list of jars which ant uses ... [ ok ]
60 * Checking for > 1.4 bytecode in ant jars ... [ ok ]
61 * Generating a list of jars in the system ... [ ok ]
62 * Checking for > 1.4 bytecode in system jars ... [ ok ]
63 * Attempting to fix broken packages ...
64 * Packages to fix this run:
65 =dev-db/hsqldb-1.7.3.1-r2 =dev-db/hsqldb-1.7.3.1-r2
66 =dev-db/hsqldb-1.7.3.1-r2 =dev-java/servletapi-2.3-r2
67 =sys-libs/db-4.3.29
68
69 I turned out that even though hsqldb was listed three times, it still
70 depended on servletapi, which was scheduled fourth. So it broke:
71
72 classes:
73 [javac] Compiling 111 source files to
74 /var/tmp/portage/hsqldb-1.7.3.1-r2/work/hsqldb/classes
75 [javac] /var/tmp/portage/hsqldb-1.7.3.1-r2/work/hsqldb/src/org/hsqldb/Servlet.java:73:
76 cannot access javax.servlet.ServletConfig
77 [javac] bad class file:
78 /var/tmp/portage/hsqldb-1.7.3.1-r2/work/hsqldb/lib/servlet.jar(javax/servlet/ServletConfig.class)
79 [javac] class file has wrong version 49.0, should be 48.0
80 [javac] Please remove or make sure it appears in the correct
81 subdirectory of the classpath.
82 [javac] import javax.servlet.ServletConfig;
83 [javac] ^
84 [javac] 1 error
85
86 I needed to remerge servletapi manually and restart java-1.5-fixer. Which,
87 of course, built hsqldb three times :-( Which was, of course, unnecessary.
88 How about at least making the packages that java-1.5-fixer is going to fix
89 unique? And how about figuring a better ordering of packages?
90
91 After all the above I think I've finally migrated my machine to Generation-2.
92 Whoopiee!
93
94 In general all was fun and problems were minor IMHO. But migration was
95 not automatic, like some users would like it to see. Maybe some things
96 coul dbe improved before stabilization?
97
98 HTH,
99 Wiktor Wandachowicz
100
101 --
102 Registered Linux user #390131 (http://counter.li.org)
103 --
104 gentoo-java@g.o mailing list

Replies

Subject Author
Re: [gentoo-java] migration-overlay entering main tree Joshua Nichols <nichoj@g.o>