There is a case between Google and Oracle over the use of Java and it's standard library on the Google Android operating system. From [this article]:

To recap: Oracle accused Google of copying some of its Java computer code when it wrote Android. Android itself wasn't the issue. Android is different than Java. But Google wanted developers who work with Java, a popular language for web apps, to jump to Android. So it incorporated Java's application programming interfaces (APIs) into Android. This allowed them to quickly convert their apps to Android and it meant that the millions of programmers trained on Java would be familiar with Android, too.

Oracle sued claiming that the APIs were copyrighted. But the judge ruled that APIs are not subject to copyright laws

On Friday, an appellate court just overturned that loss, and said APIs are subject to copyright.


My question is, Java is Open Source, and was at the time Google forked ( used loosely to mean copied some pieces of code), AFAIK. I'm not interested in whether APIs are copyright-able, let's assume they are (since that's where the case left off). How is what Google did not permissible under the Open Source license that it's distributed under (AFAIK GPLv2 (or 3?) with Classpath exception)?

2 Answers 2


First Google never "forked Java" for Android. Google implemented its own Java for Android, but when doing so copied the API of Oracle JDK. (and also copied a method named rangeCheck of 9 lines of utterly trivial code).

You must to be careful when you say "Java". Oracle has licensed OpenJDK under GPLv2 with the classpath extension. This is an open source project consisting of legacy code from the Sun Java project (taken over by Oracle). Oracle has never objected to the API or code from OpenJDK to be used in open source projects.

There is also a closed source Oracle JDK. This includes Oracle’s implementation of Java Plugin and Java WebStart, Oracle JDK Flight Recorder, as well as third party components like a graphics rasterizer.

Software like Android Studio expects Oracle JDK API to be used, not the OpenJDK API.

Oracle's infringement suit against Google is about the API to the Oracle JDK, not the OpenJDK.

  • 1
    I use the term forked loosely to mean copying the code into a new code base that you maintain, not to imply a full repository fork. Simply that they are not maintained in the same code base. Commented Aug 1, 2015 at 20:55
  • 1
    The methods and structure of the Oracle API is well documented and publicly available. But it is not licensed under a free software license. Commented Aug 1, 2015 at 21:03
  • 3
    I don't understand. Aren't the API of the Oracle JDK and OpenJDK the same? Oracle lists e.g. java.nio.channels as one of the 37 API packages (page 2 line 20). But in OpenJdk these files have GPL license. Commented Aug 14, 2015 at 1:19
  • 9
    @Christiand'Heureuse You may be interested in reading my answer on Law.SE. In brief, Google did not want to claim their use was authorized under the GPL because Google felt that having their work anywhere near the GPL would have been a bad outcome. (Also, they never made any attempt to abide by the GPL in their implementation (e.g., including a copy of the license), so they could not easily claim that they were operating under the GPL, even if they had wanted to.)
    – apsillers
    Commented May 10, 2016 at 14:39
  • 3
    Based on the comments by Christiand'Heureuse and @apsillers, this answer is incorrect.
    – mhsmith
    Commented Mar 13, 2017 at 21:56

To review, the issue here is that Google used the structure of the Java API when implementing their own software. The appeals court found that the structure of an API is eligible for copyright protection, so Google's implementation was considered a derivative work of that API structure.

The API structure is part of both Oracle's propietary JDK and Oracle's GPL-licensed OpenJDK. Therefore, Google could have made a derivative work using OpenJDK's GPL-licensed API structure. There are at least two issues with this, however:

  • Per Free Radical's answer, here are differences between the proprietary JDK and OpenJDK. If Google used any Java APIs that did not exist in OpenJDK, then obviously they could not cite a license grant for OpenJDK, since the infringing material didn't exist in OpenJDK.

  • Even if Google limited themselves to OpenJDK APIs, Google could not claim they were operating under the GPL, for several reasons (as noted in fosspatent.com's article):

    • They did not want to be bound by the GPL, for fear that its copyleft provisions may have required them to license other parts of Android under the GPL as well (and they wished to keep some component proprietary).

    • They did not follow the requirements of the GPL, because their downstream derivative work itself was not GPL-licensed. (It did not include a copy of the license, nor require further downstream works to also be under the GPL, etc.)

    • Google was opposed to the idea that the structure of an API could be copyrighted, so they claimed they did not use any copyright material (since, they claimed unsucessfuly, an API structure is not eligible for copyright). They could not claim their use was licensed under the GPL's copyright license, because they already claimed that the parts they used were uncopyrightable.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.