1

I had a question about the GNU General Public License v2 license. More specifically, I'm using a library with a GNU GPL v2 license. I'm merely importing it in Java through Maven, I'm not redistributing ANY code and no code is modified either.

What rights does this give me to my code? Is my code forced to have the same (or higher, v3) license of GNU GPL, or am I free to do with my code whatever I want to do?

More specifically, I'm using the Bukkit & CraftBukkit (through SpigotMC) library owned by Mojang licensed with GNU GPL v2.

  • 1
    Can you provide a link to the actual license? Some Java packages use a modified version of the GPL license that could be relevant here. – Bart van Ingen Schenau Nov 22 '17 at 18:44
  • 1
    "I'm merely importing it in Java through Maven, I'm not redistributing ANY code" - If you import a third-party library, build your product, and then distribute your product, you are also distributing the third-party library. – Brandin Nov 23 '17 at 7:35
1

Any code linked to a GPL library (or an object module with GPL license) should be GPL licensed. Please read the GPL FAQ (notably GPL in proprietary systems). What matters is not running the library (or some binary linked to it), but distributing (or conveying) a software using it.

If you write a library and wants it to have a license permitting linking it in proprietary (and redistributed, e.g. sold) program you need to give another license, e.g. LGPL

If you just run (without any kind of distribution) a software (e.g. on some Web server that you own) using a GPL library it makes a different question (and AFAIK you can do that, but I am not a lawyer). Read about the AGPL license.

You really should look at things the other way and read the philosophy of the GNU project. Ask also yourself how you can actively contribute to it. And remember that you are not obliged to use any GPL software, but if you do use one, you should obey its license.

If you have any doubt, consult a lawyer (and pay it for that).

  • Thanks for the explanation. Due to too few rep I cannot upvote :( – Dennis van der Veeke Nov 24 '17 at 20:49
  • Does this also apply when you have GPL code with the classpath exception? – Bionix1441 Aug 25 '18 at 11:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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