codebling / VFSJFileChooser2

**THIS PROJECT IS NO LONGER MAINTAINED.** Updates and improves upon the inactive VFSJFileChooser project.
http://vfsjfilechooser.sourceforge.net/
Apache License 2.0
5 stars 1 forks source link

Legal - SwingCommonsUtilities.java base is proprietary or GPLv2 code #17

Open hopeThisHelps opened 12 years ago

hopeThisHelps commented 12 years ago

Hi,

the file SwingCommonsUtilities.java contains: Copy of some functions in SwingUtilities2 to avoid using sun proprietary classes

This has indeed been verified, the code is copy/pasted from JDK. Thus the file is either:

  1. SUN/Oracle proprietary. In that case, you just cannot modify it and distribute it.
  2. GPLv2 code (openJDK). Which makes it incompatible with Apache2, see http://www.gnu.org/licenses/quick-guide-gplv3-compatibility.png from http://www.gnu.org/licenses/quick-guide-gplv3.html

Possible solutions: a. Is there another location where the original code is licensed under another (Apache 2) compatible license? b. Why is this needed? Is it an issue to rely on the original file in the classpath?

Thanks.

codebling commented 12 years ago

I think it may be from OpenJDK and be licensed GPLv2 like you said. The reason that class is used is because you aren't supposed to use any com.sun (or sun. ) packages in your code. They are not part of Java, they are not portable to other JRE, they are subject to constant change from version to version.

I'm not sure how to fix this. I think that to fix this completely legally a "clean room" approach is needed, whereby someone documents exactly what every method does (the dirty room) and then a different person who has not seen the code writes each method from scratch based strictly on the documentation (clean room). The resulting code then belongs to the project and has no ties to the SwingUtilities2 code. If the coder look has seen the SwingUtilities2 code at all, I think it could legally be considered a modification of that code and thus be subject to its license.

hopeThisHelps commented 12 years ago

You may also evaluate if the service provided by SwingCommonsUtilities.java cannot be done using completely another way. And thus make a new implementation not based on what can be found in SwingUtilities2.

Or evaluate if the service provided by SwingCommonsUtilities.java is necessary at all.