First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 143246
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Java team <java@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Massimo Fantin <massimo.fantin@alice.it>
Add CC:
CC:
Remove selected CCs
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
sun-javamail-1.4.ebuild.diff Diff for fixing compiler version, slot and blocking against the -bin version text/plain Peter Ansell 2006-08-13 19:05 0000 593 bytes Details
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 143246 depends on: Show dependency tree
Bug 143246 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2006-08-08 13:20 0000
I can't compile sun-javamail-1.4

For now i'm using bin version of 1.4 for working with new jaf in my tomcat 
application...(http://java.sun.com/products/javamail/downloads/index.html)

Thanks .
Massimo
--------------------------------------------------------------------------

Calculating dependencies... done!
>>> Emerging (1 of 1) dev-java/sun-javamail-1.4 to /
>>> checking ebuild checksums ;-)
>>> checking auxfile checksums ;-)
>>> checking miscfile checksums ;-)
>>> checking sun-javamail-1.4.tar.bz2 ;-)
 * Using: sun-jdk-1.5
>>> Unpacking source...
>>> Unpacking sun-javamail-1.4.tar.bz2 to /var/tmp/portage/sun-javamail-1.4/work
>>> Source unpacked.
Rewriting ./build.xml
>>> Compiling source in /var/tmp/portage/sun-javamail-1.4/work/mail ...
Buildfile: build.xml

init:
     [echo] Building component mail
    [mkdir] Created dir: /var/tmp/portage/sun-javamail-1.4/work/mail/build

compile:
    [javac] Compiling 185 source files to
/var/tmp/portage/sun-javamail-1.4/work/mail/build
    [javac]
/var/tmp/portage/sun-javamail-1.4/work/mail/src/java/com/sun/mail/imap/IMAPFolder.java:1889:
setQuota(javax.mail.Quota) in com.sun.mail.imap.protocol.IMAPProtocol cannot be
applied to (com.sun.mail.imap.Quota)
    [javac]                 p.setQuota(quota);
    [javac]                      ^
    [javac]
/var/tmp/portage/sun-javamail-1.4/work/mail/src/java/com/sun/mail/imap/IMAPStore.java:120:
com.sun.mail.imap.IMAPStore is not abstract and does not override abstract
method setQuota(javax.mail.Quota) in javax.mail.QuotaAwareStore
    [javac] public class IMAPStore extends Store
    [javac]        ^
    [javac]
/var/tmp/portage/sun-javamail-1.4/work/mail/src/java/com/sun/mail/imap/IMAPStore.java:1310:
getQuota(java.lang.String) in com.sun.mail.imap.IMAPStore cannot implement
getQuota(java.lang.String) in javax.mail.QuotaAwareStore; attempting to use
incompatible return type
    [javac] found   : com.sun.mail.imap.Quota[]
    [javac] required: javax.mail.Quota[]
    [javac]     public Quota[] getQuota(String root) throws MessagingException
{
    [javac]                    ^
    [javac]
/var/tmp/portage/sun-javamail-1.4/work/mail/src/java/com/sun/mail/imap/IMAPStore.java:1316:
incompatible types
    [javac] found   : javax.mail.Quota[]
    [javac] required: com.sun.mail.imap.Quota[]
    [javac]         qa = p.getQuotaRoot(root);
    [javac]                                ^
    [javac]
/var/tmp/portage/sun-javamail-1.4/work/mail/src/java/com/sun/mail/imap/IMAPStore.java:1346:
setQuota(javax.mail.Quota) in com.sun.mail.imap.protocol.IMAPProtocol cannot be
applied to (com.sun.mail.imap.Quota)
    [javac]         p.setQuota(quota);
    [javac]              ^
    [javac] Note: Some input files use or override a deprecated API.
    [javac] Note: Recompile with -Xlint:deprecation for details.
    [javac] 5 errors

BUILD FAILED
/var/tmp/portage/sun-javamail-1.4/work/mail/build.xml:55: Compile failed; see
the compiler error output for details.

Total time: 3 seconds

!!! ERROR: dev-java/sun-javamail-1.4 failed.
Call stack:
  ebuild.sh, line 1539:   Called dyn_compile
  ebuild.sh, line 939:   Called src_compile
  sun-javamail-1.4.ebuild, line 32:   Called eant 'jar'
'-Djavaee.jar=activation.jar'
  java-utils-2.eclass, line 1267:   Called die

!!! eant failed
!!! If you need support, post the topmost build error, and the call stack if
relevant.

!!! When you file a bug report, please include the following information:
GENTOO_VM=sun-jdk-1.5  CLASSPATH="" JAVA_HOME="/opt/sun-jdk-1.5.0.07"
JAVACFLAGS="-source 1.4 -target 1.4" COMPILER="javac"
and of course, the output of emerge --info
!!! This ebuild is from an overlay:
'/usr/portage/local/layman/java-experimental'

------- Comment #1 From Massimo Fantin 2006-08-09 04:01:24 0000 -------
solved with last ant-core-1.6.5-r14 and ant-tasks-1.6.5-r3 ebuild

Thanks
Bye

------- Comment #2 From Vlastimil Babka (Caster) 2006-08-09 05:04:36 0000 -------
Weird. For the record, I don't see how the changes in those ant-* revisions
would fix this. Yesterday there was someone on IRC with the same problem, and
it got fixed when he stopped using migration-overlay and gcj-overlay. I
couldn't reproduce it (all that was with previous ant revisions).

------- Comment #3 From Massimo Fantin 2006-08-11 13:18:11 0000 -------
you are right is not related to ant* !!  (my bad assumption)

but in other machine i found that i have to 
emerge -C sun-javamail-bin 
before 
emerge sun-javamail
else i have the error reported...

I have also find that the compilation go OK but the jar is not compatible with
the old 1.3 because of getQuota setQuota method are not implemented (as the
first error show) 
Infact i have an installed openexchange webapps the use the sun-jaf and
sun-javamail jars and with this new 1.4 version don't work: in tomcat logging i
have :

-----------------------------------------------------------------------
Exception in thread "ComfireThread 0" java.lang.NoSuchMethodError:
com.sun.mail.imap.IMAPFolder.getQuota()[Lcom/sun/mail/imap
        at
com.openexchange.webmail.FolderSettings.loadFolder(FolderSettings.java:181)
        at
com.openexchange.webmail.Management.onBeforeHtmlLoad(Management.java:314)
        at
com.openexchange.thread.ComfireThread.validateSession(ComfireThread.java:407)
        at com.openexchange.thread.ComfireThread.run(ComfireThread.java:162)
        at java.lang.Thread.run(Thread.java:595)
--------------------------------------------------------------

It suspect that getQuote e setQuote are not compiled right on the new 
sun-javamail.jar 

------- Comment #4 From Vlastimil Babka (Caster) 2006-08-11 16:38:48 0000 -------
Ahh so that's it! Because ant loads sun-javamail-bin classpath if it's in your
system, it affects the compilation of sun-javamail (unless you have
JAVA_PKG_STRICT=true). I've already suspected and tried to reproduce it, but it
happens only if sun-javamail-bin is version 1.3.*! (tested with 1.3.1 here,
because it's the stable one so I suppose you have that one). I was trying only
with 1.4 version of the -bin. Seems they are indeed incompatible and need to be
slotted.

------- Comment #5 From Massimo Fantin 2006-08-12 03:01:20 0000 -------
>>  (tested with 1.3.1 here, because it's the stable one so I suppose you have that one)


True, your supposition is right !! 

So the 2 version are not compatible ?
(well maybe i have to upgrade my version of openexchange to the last one )

Thanks 



------- Comment #6 From Peter Ansell 2006-08-13 19:00:54 0000 -------
The problem would be fixed for the compilation of the package if
sun-javamail-bin was set as a blocker for this package. Attaching an svn diff
file for the change.

Also changed in the file so that it will not use my java 6 compiler without me
explicitly changing it to do so in the future.

------- Comment #7 From Peter Ansell 2006-08-13 19:05:51 0000 -------
Created an attachment (id=94189) [edit]
Diff for fixing compiler version, slot and blocking against the -bin version

------- Comment #8 From Peter Ansell 2006-08-13 19:08:35 0000 -------
Note: Someone needs to block the binary version against this to make it work
out.

------- Comment #9 From Vlastimil Babka (Caster) 2006-08-13 22:05:07 0000 -------
(In reply to comment #6)
> The problem would be fixed for the compilation of the package if
> sun-javamail-bin was set as a blocker for this package. Attaching an svn diff
> file for the change.

Yeah it used to be blocking but it was causing problems because now some
packages dep on sun-javamail-bin and some on sun-javamail... they can well
coexist on the system. It should ultimately replace -bin, though. And bulding
with ant is being changed so that its runtime classpath doesn't affect the
source being compiled.

> Also changed in the file so that it will not use my java 6 compiler without me
> explicitly changing it to do so in the future.

Hm why? It's building well with sun-jdk-1.6 here.

------- Comment #10 From Peter Ansell 2006-08-13 23:13:00 0000 -------
(In reply to comment #9)
> (In reply to comment #6)
> > The problem would be fixed for the compilation of the package if
> > sun-javamail-bin was set as a blocker for this package. Attaching an svn diff
> > file for the change.
> 
> Yeah it used to be blocking but it was causing problems because now some
> packages dep on sun-javamail-bin and some on sun-javamail... they can well
> coexist on the system. It should ultimately replace -bin, though. And bulding
> with ant is being changed so that its runtime classpath doesn't affect the
> source being compiled.

Thats a nice change if it can be done. How exactly is that possible?

> Hm why? It's building well with sun-jdk-1.6 here.

I think it was only the 1.3 -bin version that gave me problems with
sun-jdk-1.6. Apologies for that!

------- Comment #11 From Vlastimil Babka (Caster) 2006-08-14 08:41:13 0000 -------
(In reply to comment #10)
> > with ant is being changed so that its runtime classpath doesn't affect the
> > source being compiled.
> 
> Thats a nice change if it can be done. How exactly is that possible?

See bug 142538 comments upto 4 (note the java-strict had changed from FEATURE
to settin variable JAVA_PKG_STRICT=true in make.conf).

------- Comment #12 From Josh Nichols (RETIRED) 2006-08-15 23:59:29 0000 -------
For the sun-javamail ebuild, we could do:

JAVA_PKG_STRICT=true eant .....

this way, we can force the strict behavior for this particular package. Or
perhaps, some function to enable it for a particular command, ie

java-pkg_one-time-strict eant ......

------- Comment #13 From Vlastimil Babka (Caster) 2006-09-27 15:43:15 0000 -------
Fixed with JAVA_PKG_STRICT=true eant .....

------- Comment #14 From Vlastimil Babka (Caster) 2006-09-28 03:25:12 0000 -------
Ropening for doing it with some function instead of setting a variable as
nichoj suggested, needs eclass changes.

------- Comment #15 From Alon Bar-Lev (RETIRED) 2006-09-28 05:34:08 0000 -------
Here too.
Just need to unmerge the sun-javamail-bin to make it work...

------- Comment #16 From Vlastimil Babka (Caster) 2007-04-02 18:33:52 0000 -------
Changed from JAVA_PKG_STRICT to passing -Dbuild.sysclasspath=ignore since
JAVA_PKG_STRICT has more features and can change etc.

First Last Prev Next    No search results available      Search page      Enter new bug