1 |
Am Mittwoch, 19. April 2006 18:15 schrieb Joshua Nichols: |
2 |
> Ivan Yosifov wrote: |
3 |
> > Am Dienstag, 18. April 2006 19:36 schrieb Joshua Nichols: |
4 |
> >> Ivan Yosifov wrote: |
5 |
> >>> Hello, |
6 |
> >>> |
7 |
> >>> Happens while emergeing eclipse: |
8 |
> >>> |
9 |
> >>> home ~ # emerge -1 eclipse-sdk |
10 |
> >>> Calculating dependencies... done! |
11 |
> >>> |
12 |
> >>>>>> Emerging (1 of 1) dev-util/eclipse-sdk-3.1.2 to / |
13 |
> >>>>>> checksums files .... |
14 |
> >>>>>> checksums src_uri ;-) eclipse-sourceBuild-srcIncluded-3.1.2.zip |
15 |
> >>> |
16 |
> >>> * Checking for sufficient physical RAM |
17 |
> >>> * Checking for bad CFLAGS |
18 |
> >>> * Found offending option -fomit-frame-pointer in your CFLAGS |
19 |
> >>> .... |
20 |
> >>> * Tip: use equery depgraph "=eclipse-sdk-3.1.2" to list all |
21 |
> >>> dependencies. |
22 |
> >>> |
23 |
> >>> /usr/local/portage/migration/migration/eclass/java-utils.eclass: line |
24 |
> >>> 97: [: -ge: unary operator expected |
25 |
> >>> Detected a JDK < 1.5.0 |
26 |
> >>> Detected a JDK >= 1.4.2 |
27 |
> >>> |
28 |
> >>>>>> Unpacking source... |
29 |
> >>> |
30 |
> >>> /usr/local/portage/migration/migration/ is where I've put the migration |
31 |
> >>> overlay revision 2114. Bash is 3.1_p17. Is this an eclass bug or |
32 |
> >>> something else ? |
33 |
> >> |
34 |
> >> Something else, I think. I've been working on the eclipse ebuilds (while |
35 |
> >> using migration-overlay, obviously), and hadn't noticed any problems. |
36 |
> >> |
37 |
> >> It might have something to do with the ebuild itself. Someone went and |
38 |
> >> committed a bump to 3.1.2 without consulting with us Java folks, so I'm |
39 |
> >> not sure what condition it is. Expect to see a new revision in a day or |
40 |
> >> so... |
41 |
> >> |
42 |
> >> Josh |
43 |
> > |
44 |
> > I am getting the same with the new eclipse-sdk-3.1.2-r1. I added some |
45 |
> > debugging output to the eclass in java-utils_is-vm-version-ge(): |
46 |
> > |
47 |
> > --- ./java-utils.eclass 2006-04-19 10:58:43.000000000 +0300 |
48 |
> > +++ /usr/local/portage/migration/migration/eclass/java-utils.eclass |
49 |
> > 2006-04-19 11:00:25.000000000 +0300 |
50 |
> > @@ -91,6 +91,12 @@ |
51 |
> > local vm_patch=$(echo ${vm_version} | cut -d. -f3) |
52 |
> > local vm_extra=$(echo ${vm_version} | cut -d. -f4) |
53 |
> > |
54 |
> > + echo ${vm_major} |
55 |
> > + echo ${vm_minor} |
56 |
> > + echo ${user_major} |
57 |
> > + echo ${user_minor} |
58 |
> > + echo ${vm_patch} |
59 |
> > + echo ${user_patch} |
60 |
> > if [ ${vm_major} -ge ${user_major} ] && [ ${vm_minor} -gt |
61 |
> > ${user_minor} ] ; then |
62 |
> > echo "Detected a JDK >= ${user_version}" |
63 |
> > return 0 |
64 |
> > |
65 |
> > and the output is: |
66 |
> > |
67 |
> > * Tip: use equery depgraph "=eclipse-sdk-3.1.2-r1" to list all |
68 |
> > dependencies. |
69 |
> > |
70 |
> > 1 |
71 |
> > 5 |
72 |
> > 1 |
73 |
> > 5 |
74 |
> > |
75 |
> > 0 |
76 |
> > /usr/local/portage/migration/migration/eclass/java-utils.eclass: line |
77 |
> > 103: [: -ge: unary operator expected |
78 |
> > Detected a JDK < 1.5.0 |
79 |
> > 1 |
80 |
> > 5 |
81 |
> > 1 |
82 |
> > 4 |
83 |
> > |
84 |
> > 2 |
85 |
> > Detected a JDK >= 1.4.2 |
86 |
> > |
87 |
> >>>> Unpacking source... |
88 |
> > |
89 |
> > ,meaning that vm_patch is ending up empty and that seems to confuse -ge |
90 |
> > conditionals using it. |
91 |
> |
92 |
> I'll have to look into this, but it probably just needs to sanity |
93 |
> checking for the vm_extra and company. |
94 |
> |
95 |
> Aside from that, what is the original of the ebuild for eclipse that you |
96 |
> are using? Also, which VM are you using? I haven't been able to quite |
97 |
> reproduce this problem... |
98 |
> |
99 |
> Josh |
100 |
|
101 |
I am using the eclipse-sdk-3.1.2-r1 ebuild from the main tree, attached here |
102 |
for reference. I have sun-jdk 1.4.2.10-r13 and 1.5.0.06-r13 installed. The |
103 |
problem with vm_patch seems to be that |
104 |
|
105 |
java-config -f | sed -e "s/.*-\([0-9.]\+\).*/\1/" ( in |
106 |
java-utils_get-vm-version ) |
107 |
|
108 |
returns just "1.5" and so |
109 |
|
110 |
vm_patch=$(echo ${vm_version} | cut -d. -f3) ( in |
111 |
java-utils_is-vm-version-ge ) ends up being an empty string. There is no |
112 |
third field to cut. |
113 |
|
114 |
-- |
115 |
Cheers, |
116 |
Ivan Yosifov. |