Java released under the GPL

It's finally happened, but the surprise is that Sun's picked the General Public License
Written by Graeme Wearden, Contributor

In a development that could shake up the software industry, Sun is releasing the Java programming language under the General Public License (GPL).

Both Java Platform Micro Edition (Java ME), which is used on mobile devices, and Java Platform Standard Edition (Java SE) software, used for desktop applications, are being released immediately under GPLv2. The Java class libraries will be released over the next six months.

Rumours that Sun was poised to make Java open source emerged last week, but there may still be surprise over its choice of licence. Simon Phipps, Sun's chief open source officer, told ZDNet UK that a final decision was only made a fortnight ago. Sun's own Community Development and Distribution License (CDDL) was another option.

Sun's server-side Java Platform Enterprise Edition software is already open sourced under the CDDL, through the GlassFish project. This enterprise edition will now also be available under GPLv2.

Phipps believes that the GPL is the best choice of licence, and should boost the take-up of Java around the world.

"The objective is to grow the Java market," explained Phipps. "In countries such as Brazil and Chile there is a requirement to use only free software in government, so it's not been possible to use Java in these deployments."

Sun is also hoping that Linux distributions such as Debian and Fedora will now include Java. At present they don't, because it has not been freely available.

Sun has chosen to use the so-called "classpath exception", a licence addition that allows the company to place limits on the software that the GPL covers.

Rich Green, Sun's executive vice president of software, told CNET News.com, that this means programmers who create applications using Sun's open-source versions of Java can use choose a different licence for their applications, he said.

"In the case of Java SE [Java Standard Edition], we're enhancing [the GPL] with the classpath exception," Green said. "So when you're working on top or shipping applications with the [Java] libraries and virtual machine, you're not affected by the Java licence."

In addition, Java creator Sun will continue to offer a commercial proprietary licence, a "dual-licence" structure that gives other software vendors legal indemnification and official standards certification. Phipps explained that Sun has spent many months going through every line of Java code, checking that it owned the intellectual property for each one. When it didn't, it has attempted to negotiate with the relevant rights holder. In some cases, agreement couldn't be reached so Sun pulled in alternative code from other sources. This included some of the projects that have sprung up to create open-source versions of Java. Phipps revealed that some technology companies had refused to reach an agreement, but declined to name them.

Sun has been under pressure to make Java open source for several years. In 2004, free software advocate Richard Stallman claimed that software developers should beware of Java because it was not offered under a free licence.

"If your program is free software, it is basically ethical — but there is a trap you must be on guard for. Your program, though in itself free, may be restricted by non-free software that it depends on. Since the problem is most prominent today for Java programs, we call it the Java Trap," wrote Stallman. He recommended only using a free Java development environment.

Sun's move comes just weeks after Linux vendor Novell signed a controversial patent protection deal with Microsoft. Under this deal, Microsoft has promised not to sue Novell over any alleged patent infringements in Linux.

Phipps claims that this deal indicates Novell is concerned that its Mono project — an open-source implementation of Microsoft's .Net platform — may infringe some patents.

"It's interesting that Novell suggests Mono is encumbered by patent problems just a week before we free Java," said Phipps. "The timing couldn't be better."

Sun will announce further details of its plans on Monday, with a live webcast scheduled for 5.30pm GMT.

Editorial standards