10

I would like to sell a Java desktop application of mine to more schools after having success with one single school. Seems like it wouldn't have been a problem, if I haven't mixed different licenses up, but that's exactly what I did. It is no problem for me, to deliver my source code with the program itself when I distribute it to the customers, but the question is under what license I have to publish the program and if I can ask for payment directly or if I need to set up some kind of donation possibility. I am looking forward to your advice.

I used the following dependencies with licenses:

  • JXL: LGPLv2
  • JTattoo: GNU GPL v2.0+
  • Apache Commons IO: Apache license 2.0
  • Apache POI: Apache license 2.0

It is no problem for me that the customers are able to modify and redistribute my code, due to the fact that they don't have the knowledge of how to do any of it.

2
  • 3
    "It is no problem for me that the customers are able to modify and redistribute my code, due to the fact that they don't have the knowledge how to do any of it." - Keep in mind that under the GPL (and Apache), your license terms also can't effectively restrict someone from installing the same copy on several computers. Many (most?) computer users know how to copy software.
    – Brandin
    Aug 14, 2023 at 6:19
  • Not that it helps with your Apache 2.0 dependencies being incompatible with Jxl, but if this is the correct project, JTattoo is actually licensed under GPL-2.0+, with purchase options for other licenses.
    – lights0123
    Aug 15, 2023 at 1:27

3 Answers 3

12

This answer is based on the information in the currently newest information at time of writing, I quote it here for completeness:

JXL: LGPLv2
JTattoo: GNU GPL v2.0+
Apache Commons IO: Apache license 2.0
Apache POI: Apache license 2.0

The GNU GPL v2 is incompatible with the Apache license 2.0, but the GNU GPL v3 is compatible. Luckily the JTattoo is licensed as version 2 or any later at your choice, so you may choose GNU GPL v3.

Thus you are allowed to create a derivative work of the JTattoo, Commons IO and POI libraries under terms of the GPL v3.

The license of the JXL under the LGPL v2 does not change the conclusion above: A library under an LGPL license can be included into any work regardless of the combined work's license, even proprietary work. It however imposes the requirement that you allow and enable the recipients of your software to replace the LGPL-licensed library by another version of that library.

In your case that condition is easily fulfilled: you (have to) offer the complete corresponding source code of the whole project anyway as that is a requirement directly from the GPLv3.


This is the original answer which is based on different license information quoted below. I leave it here for illustration that the details matter a LOT, and that it really pays to pay attention to individual licenses before using any software component:

JXL: GPLv2
JTattoo: GNU GPL v3
Apache Commons IO: Apache license 2.0
Apache POI: Apache license 2.0

That's a bit of bad luck, or a hard lesson to learn: if the dependency under GNU GPL v2 is NOT licensed as or any later version of GNU GPL, you are out of luck, and you are not allowed to distribute the software at all.

The GNU GPL v2 is not compatible with the Apache license v2, however the GNU GPL v3 is. Thus if you don't have the option to distribute Jxl under GPL v3, you will have to remove that dependency or replace it by something else. (If it is this JXL, you might incorporate the linked version under BSD3, and that is compatible again).

Thus if you are allowed to distribute Jxl under GNU GPL v3, a strong copyleft license, this means in essence that you must offer the full corresponding source code under GPLv3 to your clients to enable them to build the software themselves.

Mind: look at the licenses of your dependencies before you incorporate them into your work, and check their compatibility with your license, so that you don't accidentally end up with anything you may not distribute to anyone. It may work on your PC, but otherwise have no permission to give the work to anyone else, including any client regardless of their interest in sources or whatever.

4
  • How Olivier found out I messed the License of JXL up, it is LGPLv2. Does this change your answer? Thank you so far
    – Hagenbeck
    Aug 16, 2023 at 13:38
  • 2
    I completely rewrote the answer based on the changed information. In the future please be careful and precise, especially when asking or researching about license compatibility. Details may matter here more than one would like to see them matter. And it's somewhat unfair towards the people answering as suddenly their answers become completely invalid when the original question changes :) (No worries here now) Aug 16, 2023 at 14:40
  • @planetmaker I am definitely sorry... apologize for my bad research, I trusted Wikipedia... Generally, your answer is worth gold... Thank you. It is really not, of course, to get such a nice answer.
    – Hagenbeck
    Aug 16, 2023 at 16:38
  • 2
    @Hagenbeck it's not the bad research - which could happen to any of us - it's the failure to provide what you know. You don't need to let us know stuff you don't know, but it's really helpful if you can let us know everything you do know! For example, there seem to me to be multiple projects called JXL (as one might well expect, with only 17600-odd possible combinations of TLA!) so any pointers you could give us to the library you're using (where did you get it? who wrote it? what distro package is it part of? that sort of thing...) will help.
    – MadHatter
    Aug 16, 2023 at 18:59
3

There is an ambiguity about JXL: does it refer to this or that library?

The first one in under GPLv2 while the second is under LGPLv2. And my guess is that you are using the second library.

6
  • 3
    You may be right, and I wish the OP had linked to all the relevant projects, but the OP is pretty clear (s)he thinks the jxl (s)he's using is GPLv2, which suggests your guess may be wrong.
    – MadHatter
    Aug 13, 2023 at 13:07
  • The exact word "GNU GPL v2" is mentioned in Wikipedia - Java Excel API (JXL API).
    – Andrew T.
    Aug 14, 2023 at 14:32
  • @AndrewT. The Wikipedia page is wrong.
    – Olivier
    Aug 15, 2023 at 6:33
  • so... yeah I messed that point up. I just searched JXL and didn't look further into what JXL I was looking at. I used the second option(I'll edit the question) Thank you for that
    – Hagenbeck
    Aug 16, 2023 at 13:31
  • 1
    No, you should always check the primary references, and if Wikipedia's wrong, fix it. In this case, I have done so, so thanks to everyone for helping to get that fixed!
    – MadHatter
    Aug 16, 2023 at 14:17
3

We need to have two questions answered.

Firstly, how are each of the dependencies linked to or used by your software?

Secondly, is JXL licensed GPLv2-only or GPLv2+?

The first question is important, because dynamic and static linking causes all linked software to be subject to the conditions of the GPL license, while aggregates are not.

If communication to GPL'ed software is done only through inter-process communication like TCP, then they are considered to be aggregates with your software, and so the conditions of the GPL does not apply to your software.

The second question is important in order to determine the overall license compatibility of the software. GPLv2-only software cannot be directly or indirectly linked with GPLv3 software. However, GPLv2+ software can be directly or indirectly linked with GPLv3 software, and the overall combination of it will be licensed under GPLv3. And GPLv3 is compatible with Apache License 2.0.

1
  • To the second question: another answer found a fault in my research. I messed the license of JXL up, it is LGPLv2 To the first question: I have to be honest, I am 100% selftaught and don't have any apprenticeship. This means that I don't understand it completely, but I'll try to answer it as best as possible. I put the dependencies in the pom.xml and used their methods in my source code. I didnt't edit them or anything like that.
    – Hagenbeck
    Aug 16, 2023 at 13:36

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.