

Lion removes Java? - latchkey
http://lookfirst.com/2011/07/lion-removes-java.html

======
st3fan
_My guess is that there is some sort of Oracle licensing agreement that
prevents Apple from distributing Java with the release. You'd think that these
two massive public companies would be able to work something out_

This is pure unfounded speculation.

In reality Apple probably wanted to make the Lion base install leaner.

Many components are are now simply loaded and installed on demand. Like for
example also extra voices for text2speech.

~~~
silvestrov
Mike Swingler (Apple JVM developer) said:
[http://lists.apple.com/archives/java-
dev/2011/Jul/msg00041.h...](http://lists.apple.com/archives/java-
dev/2011/Jul/msg00041.html)

 _After a decade of shipping Java on the Mac and tricking old apps that
hardcode paths to the 1.3.1 JVM, or putting in class loader hacks to fake out
Xerces XML classes that were moved in 1.5.0, we are ready to try something
different._

In [http://lists.apple.com/archives/java-
dev/2011/Jul/msg00044.h...](http://lists.apple.com/archives/java-
dev/2011/Jul/msg00044.html)

 _What you loose in a per-app embedded model is shared memory mapping of the
native libraries and .jar files, but this is the same problem as a half dozen
apps embedding (often different) versions of the Sparkle.framework to do app
self-updates. The cost of the JVM heap is still the same, and class-sharing
was never ported to 64-bit by Sun, so that optimization hasn't been around for
a long time on Macs._

In [http://lists.apple.com/archives/java-
dev/2011/Jul/msg00038.h...](http://lists.apple.com/archives/java-
dev/2011/Jul/msg00038.html)

 _Long-term, we recommend that app developers who use the JavaApplicationStub
should transition to embedding the Java runtime within their own app. We are
working with Oracle on the OpenJDK project to provide an open source version
of JDK7 that can be embedded, and several developers have already started
deploying their apps with an embedded JDK7 (but it requires many manual steps
right now)._

 _We are tracking the progress of creating an embeddable JRE in_
<http://java.net/jira/browse/MACOSX_PORT-105>

Conclusion: Apple's JVM team think this model is better for solving end users
problem with JVM compatibility.

~~~
rchowe
And conveniently it means that mac app store apps can't be java apps, which
leads to them being better integrated and (slightly) higher quality.

~~~
astrange
There are already apps on the Mac App Store embedding their own JRE.

[http://itunes.apple.com/us/app/cyberduck/id409222199?mt=12&#...</a>

------
Flow
No, it's just not installed fully by default.

I Spotlighted for Java Preferences and when I started it I was told that Java
will be downloaded. After Lion downloaded and installed Java the Java
Preferences started.

IntelliJ et al works as expected.

You don't need to do these manual step the article suggests(for running Java
apps). (See comment below when you need to do these steps)

~~~
jonknee
It was previously included and is no longer included... It has been removed.

~~~
Flow
Not removed, stubbed in such a way it will be installed automatically when
needed.

~~~
mcantelon
If it was there and isn't now it has been removed. The ability to easily re-
add it doesn't change that.

------
jzoidberg
We have known this was coming for many months now - why is anyone surprised?
The support will revert to JVM vendors where it belongs. Personally I think it
is a good thing - we will get JVM versions much faster than Apple supplied
them.

~~~
latchkey
It isn't about being surprised. Apple is still supplying the JVM. At my
company, some IT guy sends out an email saying 'don't install Lion cause Java
isn't installed and it breaks Network Connect'. It is this kind of unnecessary
confusion which doesn't help anyone. My blog post is simply telling people how
they can fix their stuff after Apple decides to make things difficult and
confusing for people.

~~~
seandougall
When I first launched Xcode after installing Lion, a dialog popped up saying I
would need to install Java and relaunch, and gave me a button to press that
would do that for me. It worked exactly as advertised -- literally one mouse
click. Not at all difficult or confusing, and in fact simpler than the
command-line approach your post describes. Other folks I've talked to had the
exact same thing happen with apps like Photoshop and Java-dependent games:
just one click. Was your experience different?

~~~
latchkey
I didn't find opening up Terminal.app and typing 'java' difficult or confusing
either. The rest of the blog post (with the symlinks) is about telling Eclipse
where to find the source code.

That said, I think that it sure would be nice if my OS already came with Java.
But I use Java every day, so maybe I'm biased.

For those of you who are worried about Apple needing to spend a few of the
billions of dollars it has in the bank on paying a couple engineers to
maintain security patches, it doesn't have to be the Apple or Oracle one
either. OpenJDK would be fine.

------
blinkingled
It makes sense for Apple to not bundle any extraneous, non-core stuff like the
JVM/Ruby/Python runtimes with the OS and let people download and install
things on demand from their preferred source. Microsoft has always done it
this way.

The problem in the JVM's case is that Apple made some intricate changes to the
JVM to better integrate with OS X / Cocoa - like the look and feel and other
integration stuff. A JVM with default Swing implementation on a Mac, without
these changes, would have never been used at all - it just doesn't go with a
Mac.

These changes are not going to be Open Sourced and the required OS level
support for these changes is going to be deprecated. Which means whatever
solution OpenJDK comes up with is likely going to be at the level of 'bare
minimum' - enough to run server side apps and stuff and may be some horrible
looking alien Swing Apps based on X11 or something.

There's the hold up I think - they need to come up with open source
reimplementation of the integration bits without needing any OS/framework
level hacks and that ain't no easy task!

~~~
jamesbritt
_It makes sense for Apple to not bundle any extraneous, non-core stuff like
the JVM/Ruby/Python runtimes with the OS and let people download and install
things on demand from their preferred source._

But they do bundle Ruby 1.8.7.

~~~
mitchty
And in private frameworks you can find macruby as well interestingly. Tonight
I'm going to find out whats using it, i'm curious.

------
gregory80
Wasn't this announced in October of 2010?

[http://www.cultofmac.com/steve-jobs-explains-was-java-was-
de...](http://www.cultofmac.com/steve-jobs-explains-was-java-was-deprecated-
on-os-x/65324)

"Java runtime at the same level, and it may even be removed from future
versions of Mac OS X."

~~~
runjake
Read the article. The news (for people who weren't in the Lion beta program)
is that if you open up a Terminal prompt and type 'java', it will
automatically install Java for you.

So, it's not really deprecated anymore. In fact, Java was updated a few times
during the beta process.

~~~
chc
They never called it "deprecated" — they said it was an optional install in
10.7 and would no longer receive the same level of support. They gave Rosetta
the same treatment in 10.6. It's gone now. All signs point to this being a
grace period for Java devs to figure something else out.

~~~
runjake
It's always best to qualify your statements with "... that I'm aware of." ;)

Straight from the horse's mouth:

 _As of the release of Java for Mac OS X 10.6 Update 3, the Java runtime
ported by Apple and that ships with Mac OS X is deprecated. Developers should
not rely on the Apple-supplied Java runtime being present in future versions
of Mac OS X.

The Java runtime shipping in Mac OS X 10.6 Snow Leopard, and Mac OS X 10.5
Leopard, will continue to be supported and maintained through the standard
support cycles of those products._

[http://developer.apple.com/library/mac/#releasenotes/Java/Ja...](http://developer.apple.com/library/mac/#releasenotes/Java/JavaSnowLeopardUpdate3LeopardUpdate8RN/NewandNoteworthy/NewandNoteworthy.html#//apple_ref/doc/uid/TP40010380-CH4-SW1)

~~~
chc
I see it as fairly unnecessary to qualify things that way, because it's
implied in any statement of fact that we're speaking according to our
knowledge. I'd never write "according to your knowledge."

At any rate, this is still not a reversal of any stance. Apple never said it
would not ship a Java runtime for Lion (and iirc it has been this way in Lion
for a long time), and it still isn't recommended that developers depend on
this.

~~~
runjake
I was just responding to your erroneous correction that Apple never said it
was "deprecated", when in fact they explicitly said so. :)

Even our Apple rep said it was deprecated and he sure as heck doesn't read
Developer notes, so I'd have to assume he got the news through some other
chain at Apple.

Perhaps other orgs were protesting as loudly as our org was.

------
glhaynes
Unless I missed a subsequent announcement, this was a silent change of policy
— my understanding from their earlier announcement had been that you'd have to
get a JRE from Oracle directly. Which gave me a bit of a scare when I realized
my VPN software relied on Java and I hadn't seen any announcement from Oracle
of a downloadable JRE. Happily, the first time I tried to connect, Lion popped
up a window asking if I wanted to install Java; I said yes, and a few minutes
later, everything worked as it always had.

------
mmuro
Java and Flash aren't installed by default on Windows, right? Then, what's the
big deal of loading your own copy assuming you need it.

------
Hoff
Apple has gone to the same general distribution scheme for Java as they've
implemented for themselves with Lion, Xcode, and many other pieces. Download
it when you need it, and download the newest bits. (The Java download is
certainly not as integrated as the Mac App Store stuff, but then the Xcode
download that is in the Mac App Store is also a little weird, too. Download on
demand, or whatever you want to call it.)

What's more interesting (to me) is the remote satellite boot that's now
feasible during Lion recovery (where your Mac can boot off software loaded
from Apple's servers via the Internet), and additions such as the ability to
perform a recovery boot that can go as far as to launch Safari and get to the
Internet to access services or to research whatever has caused me to be in the
recovery path.

This certainly looks to be an operating system that's moving out onto the
web/cloud/Internet.

------
riobard
I recalled there was an internal Apple support stat showing that the two major
sources of security holes on Mac OS X are Flash and Java. Apple has to
maintain its own JVM stack, which is basically nightmare for a company with so
few head counts compared to its product volume. The majority of OS X users
won't ever use Java in their life time. Seems a really good idea not to bundle
it.

------
callmeed
After upgrading my MBA to Lion, I couldn't launch Photoshop CS3 without
installing a Java Runtime. Took 5 mins. Not really a big deal ...

------
the-kenny
They don't ship it by default.

If you run `java` in the terminal, Lion detects this and automatically
installs it.

~~~
latchkey
Wow, you must have read my blog posting!

------
pwpwp
I remember when OS X was promoted as the "greatest platform for running Java".

~~~
riobard
That was years ago. Practically no one has ever written pleasant Java-based
consumer-facing applications running on OS X. Then iOS and OS X attracted a
lot of native app developers using Xcode/Obj-C, and it paved the end of pre-
installed Java on OS X.

------
sigzero
It does...but you can put it right back.

------
dmooray
What about Flash?

~~~
glhaynes
Not included anymore; you have to install it from adobe.com. They'd already
switched to that on their hardware (at least on the storage-constrained
MacBook Air… others too, though, I think) a few months back.

~~~
mikeryan
If you upgrade from a Snow Leopard install with Flash, it seems to carry over
to Lion with the upgrade.

------
nextparadigms
Nobody thinks the removal of Flash's hardware acceleration and now Java are
somehow related? My guess is they don't want to support technologies that are
"helping" Android.

~~~
capnrefsmmat
They didn't remove Flash hardware acceleration.

[http://www.macrumors.com/2011/07/22/adobe-retracts-claim-
sug...](http://www.macrumors.com/2011/07/22/adobe-retracts-claim-suggesting-
lion-may-lack-support-for-flash-hardware-acceleration/)

