Cannot debug Java on the mac!

Discussion in 'Mac Programming' started by Mork, Feb 8, 2011.

  1. Mork macrumors 6502

    Joined:
    Jan 9, 2009
    #1
    Not sure this is the correct forum for this type of posting, but the problem I'm having is that when I try to debug a Web app in Eclipse, I get the error from the URLClassLoader that...

    "The JAR file /System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/classes.jar has no source attachment."

    I'm trying to work with the support people there, but haven't heard anything back.

    Since Apple controls, for the moment anyway, the Java VM/JDK, I'm wondering if anyone else has had this debugging problem and knows a workaround.

    Thanks in advance.

    - M
     
  2. wilsonlaidlaw macrumors 6502

    wilsonlaidlaw

    Joined:
    Oct 29, 2008
    #2
    General Javascript issues since 10.6.4/Java 3

    I and a number of other Mac users have been having general Java issues since 10.6.4 and Java 3. As a developer I have been in touch with Apple on this and sent them lots of syslogs, details, screen prints etc. Two of our 3 Intel Macs have this issue with only the MacAir behaving well. None of our PowerPC Macs have the issues. Every time I run file permissions repair, I am getting screeds of corrections on Java files. The symptom is that Javascript buttons don't work on certain websites and like you I cannot de-bug. Apple say after 2 months of correspondence that they cannot duplicate the issue so have closed the file. A real 'head in the sand' attitude. I just hope that Lion will cure it but I am not too optimistic. After all, two years on and at least 4 Airport updates and the "connection timeout" issue is only part cured.

    Wilson
     
  3. Mork thread starter macrumors 6502

    Joined:
    Jan 9, 2009
    #3
    WOW!

    I'm tempted to ditch the Mac and just head back to Windows where, although I won't enjoy "being there", at least I can get my job done!

    Perhaps I should remain calm and just run my Java stuff in a (Mac) VM session (XP or Linux)?

    The strange thing is that I can debug fine using Intelij IDEA on the Mac, but not Eclipse.

    I'm very disappointed with Apple and their stance, and support, with Java (the #1 programming language on the planet)!

    Thanks very much for your reply.

    - M
     
  4. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #4
    The problem occurs only in Eclipse, right?


    You may need to download the appropriate "Java for Mac OS X 10.N Update M Developer Package" which can be obtained by logging into Apple Developer Connection. You will need an Apple ID, but the free one is entirely adequate. You should also be cognizant of the appropriate N and M values of your system in choosing what to download.

    Once you're logged in, a list of links is presented on the right side of the page. Click the "Java" link and you'll see a number of downloads. Pick the correct Developer Package, download, install.
     
  5. Mork thread starter macrumors 6502

    Joined:
    Jan 9, 2009
    #5
    Actually, the problem is worse than that.

    Nothing debugs. Not even for source code I wrote.

    -- M
     
  6. Hansr macrumors 6502a

    Joined:
    Apr 1, 2007
    #6
    Which OS are you running on, which Eclipse and which java framework is set as default in the java prefs?

    I can debug fine with Eclipse on my machine.
     
  7. Mork thread starter macrumors 6502

    Joined:
    Jan 9, 2009
    #7
    I am using MyEclipse.

    After reading your note, I downloaded the regular Eclipse and it debugged fine too.

    I'm working with the company there to try to resolve.

    Thanks for your note.

    - M
     
  8. balamw Moderator

    balamw

    Staff Member

    Joined:
    Aug 16, 2005
    Location:
    New England
    #8
    Still going to take it out on Apple though, aren't you. ;)

    B
     
  9. Mork thread starter macrumors 6502

    Joined:
    Jan 9, 2009
    #9
    Funny. Actually, I love Apple, as much as possible, though....the overall part about Java still stands. I have no idea if Java, now depreciated by Apple, will be in 10.7, or if I'll have to go back to Windows for Java development.

    As I stated before, I love my Mac and absolutely cannot believe that Java, the #1 language is treated like this -- or that there is even doubt that it would be supported.

    With Windows, there are tons (TONS) of other problems to deal with that I'v never even considered on the Mac. However, getting work done with the JDK of my choice (or even installing multiple JDKs) isn't one of them.

    I certainly hope it all works out since Apple's products work so very wonderfully.

    There are lots of other threads on this issue.

    Thanks for your note.

    - M
     
  10. balamw Moderator

    balamw

    Staff Member

    Joined:
    Aug 16, 2005
    Location:
    New England
    #10
    Microsoft doesn't provide or support Java for Windows either, since they abandoned their JVM in 2001. Sun/Oracle does. Same as they can on the Mac and Linux, if they choose to.

    I know the history, but still don't get why this is Apple's problem and not Oracle's.

    B
     
  11. Mork thread starter macrumors 6502

    Joined:
    Jan 9, 2009
    #11
    Yeah, I see your point.

    But, so far, nobody, including "Sunacle", has stepped up to say they will support it on the Mac.

    IMHO, Windows implementation for installing JDKs is far superior to Mac's: You can install as many as you want and they don't get overwritten if/when you install another one (if your Windows machine is ... working that day, that is. ;))

    In my experience, when I've "found" the old JDK 5 install for the Mac (and the magic unix commands to use to install it), the next time Apple came out with a new Java 6 version, it always zeroed out my JDK 5 and just turned the JDK 5 folders into links pointing to their current (and, of course) only version.

    I really don't care who supports the JDK, but right now, nobody has stepped up.

    Do you have zero concerns about these issues or do you think they'll just all get worked out?

    Appreciate your replies. :)

    - M
     
  12. balamw Moderator

    balamw

    Staff Member

    Joined:
    Aug 16, 2005
    Location:
    New England
    #12
    Ball's in Oracle's court. We'll see what they choose to do.

    B
     
  13. Cromulent macrumors 603

    Cromulent

    Joined:
    Oct 2, 2006
    Location:
    The Land of Hope and Glory
    #13
    Actually both Apple and Oracle have stated that OpenJDK will be the new Java runtime on the Mac. Apple gave most of their source code to the project and they are currently working on a Java 7 implementation.
     
  14. chown33 macrumors 604

    Joined:
    Aug 9, 2009
    #14
    False.

    http://www.macrumors.com/2010/11/12/apple-and-oracle-announce-plans-for-openjdk-java-implementation/

    http://www.apple.com/pr/library/2010/11/12openjdk.html
    Apple also confirmed that Java SE 6 will continue to be available from Apple for Mac OS X Snow Leopard® and the upcoming release of Mac OS X Lion.​

    You can read more articles by googling: apple java oracle
     
  15. Hansr macrumors 6502a

    Joined:
    Apr 1, 2007
    #15
    Was it really necessary to call him out on it explicitly using a re-iteration of a prior post?
     

Share This Page