This week's book giveaway is in the Spring forum.
We're giving away four copies of Spring in Action (5th edition) and have Craig Walls on-line!
See this thread for details.
Win a copy of Spring in Action (5th edition) this week in the Spring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Devaka Cooray
  • Liutauras Vilda
  • Jeanne Boyarsky
Sheriffs:
  • Knute Snortum
  • Junilu Lacar
  • paul wheaton
Saloon Keepers:
  • Ganesh Patekar
  • Frits Walraven
  • Tim Moores
  • Ron McLeod
  • Carey Brown
Bartenders:
  • Stephan van Hulst
  • salvin francis
  • Tim Holloway

So I bit the bullet and installed Mountain Lion. Trying to install Java 7  RSS feed

 
ranger
Posts: 17314
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yep, I know in other threads I said I just wasn't going to install Mountain Lion because I loved Spaces. The good thing I see with Mountain Lion as opposed to Lion, is that when you create new Desktops it automatically assigns CTRL-# for each desktop, so it works exactly like spaces for me. I had to get Java 7, that is why I installed it last night. Still getting used to scroll direction, but I was familiar with all the other new stuff, and it doesn't take long to get used to them. Especially since I would play with Mountain Lion at the Apple Stores so I was already used to those.

While installing Java 7 was really easy. Getting it to show me java -version or javac -version still shows me Java 6 though. I went to the Java Utilities app and unchecked the 2 Java 6 listed there and moved Java 7 to the top, but that didn't help.

I also do have a

export JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home

in my .profile. But I thought that after installing and moving it up in the utile that that was the type of change that would be made, making the CurrentJDK… stuff now point to the Java 7 directory.

I even commented out the export and re sourced my .profile but that didn't work.

Thanks

Mark
 
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I bet you need Java 7 for Vert.x.

I opted for the linux in a VM route to play around with Java 7 because I still need 6 to do my other work.
 
Mark Spritzler
ranger
Posts: 17314
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Gregg Bolinger wrote:I bet you need Java 7 for Vert.x.

I opted for the linux in a VM route to play around with Java 7 because I still need 6 to do my other work.



You know it.

I have been using ftp to copy my Groovy scripts for vertx to a Centos VM, still coding on my Mac in IntelliJ with Java6. I also have Mint and Ubuntu VMs in VMWare Fusion and did that for a little bit, but I would much rather have it right on the Mac directly. Just downloaded LibreOffice to replace Open Office since OO doesn't work with Java 7.

Mark
 
Mark Spritzler
ranger
Posts: 17314
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
By the way. vertx is amazing. I created a chat server with rooms and direct messaging in 140 lines of Groovy code. I am now in the middle of writing a whole game server with vertx

Mark
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Getting slightly off topic here, but IntelliJ doesn't care of OpenJDK 7. It prefers Oracle's 7. Not sure which you're using.
 
Mark Spritzler
ranger
Posts: 17314
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Gregg Bolinger wrote:Getting slightly off topic here, but IntelliJ doesn't care of OpenJDK 7. It prefers Oracle's 7. Not sure which you're using.



Oracle's 7u7

Mark
 
Mark Spritzler
ranger
Posts: 17314
11
IntelliJ IDE Mac Spring
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Got Java 7 working now. Had to run

/usr/libexec/java_home -v 1.7.0_07 --exec javac -version

Mark
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So is there any way to do this and still use Java 6?
 
Mark Spritzler
ranger
Posts: 17314
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Gregg Bolinger wrote:So is there any way to do this and still use Java 6?



What exactly do you mean? to do what? Use vertex? vertex requires Java 7 no matter what.

Mark
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What I mean is, how difficult is it to have 6 and 7 installed on OSX? I suppose I could have one of them installed as the main jvm and just have the other version tucked away in a folder that I can use via path adjustments when necessary.
 
Mark Spritzler
ranger
Posts: 17314
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Gregg Bolinger wrote:What I mean is, how difficult is it to have 6 and 7 installed on OSX? I suppose I could have one of them installed as the main jvm and just have the other version tucked away in a folder that I can use via path adjustments when necessary.



Yes, just like linux you can have multiple versions of Java installed and have certain applications use different versions etc. For instance, In order to startup Open Office, it requires 6 even though I now have 7 at the top. So I just went into the Utilities folder for the Java preferences and just had 6 also checked off, but at the bottom of the list. Now Open Office can find Java 6 and use it to run. Also in IDEA I can have one project use 6 and another open at the same time using 7.

Mark
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!