I came across an old project in which there's a LGPL licensed JavaScript code was used. The code had the commented LGPL license information, but it was in a combined JS file (Not minified though) which also had other library files as well. Not sure, but it looks like the complete file had just third party libraries in it.

Now I need to publish this project as an external facing website and I want to know what could be the repercussion of having LGPL licensed code in it. The code is in a private repo right now and the project is unpublished.

I want to know whether I can go ahead with publishing the project as is or should I invest some time to remove the code from the project? If I really want to go ahead with the current project, would I have to open source just the combined library file or the complete project, or none of it?

The project is commercial/enterprise in nature and it was last modified a year ago.

Update: Following is the library I discussed about -

The license comment mentions that it's using LGPL, doesn't define any version. Here's the license comment -

 * jsii - JavaScript Inheritance Implementation
 * Copyright (c) 2009 Eduardo Nunes (http://e-nunes.com.br), Otávio Avila (http://otavioavila.com)
 * Licensed under GNU Lesser General Public License
 * Inspired in http://ejohn.org/blog/simple-javascript-inheritance/
 * @docs http://code.google.com/p/jsii/
 * @version 1.0.0
  • 1
    you can very likely use the LGPL-covered code, though maybe with minor adaptions to how you are currently deploying it. Could you tell us which version of the LGPL is involved here? Is it v2.1 or v3? – amon Mar 12 at 9:05
  • @amon it doesn't mention any specific version. Please check the update in the question – noob Mar 12 at 10:08
  • @amon, the Google Code page referred in the question links to the LGPLv3 license page. – Bart van Ingen Schenau Mar 12 at 11:37
  • @BartvanIngenSchenau I guess it links to the latest version of LGPL whatever it is. – noob Mar 12 at 12:33
  • 2
    @noob Every version of the (L)GPL contains language that the absence of a version number means you may use any version. In the LGPLv2.x, this is "If the Library does not specify a license version number, you may choose any version ever published by the Free Software Foundation." – apsillers Mar 12 at 16:06

LGPL goes only for the code it's licensed under and for modifications of said code.

If the LGPL code would be in a separate file, then you would only open source that file under LGPL.

If that LGPL code is mixed up with other code in the same file then you have to open source that LGPL code under LGPL and make sure all the other code licensed under different licenses would get their license terms met as well - you can't license the whole file under LGPL just because there was some LGPL code in it.

In any case - you do not have to open source the whole project if you do not want to.

Good luck!

  • 1
    Copying a single line of LGPL-licensed code can mean that a whole multi-file project needs to be licensed under the (L)GPL, so your bold statement is not universally true. It all depends on if the concatenated JS file will be considered a derived work (LGPL must apply to the whole work then) or an aggregation of independent works (each part has its own license). – Bart van Ingen Schenau Apr 15 at 19:38
  • @BartvanIngenSchenau - That's not true at all. The LGPL license only applies to the code under that license and only might apply to the modifications of said code. There is no license that can legally demand you to release your code under their license terms. Author is the only one who can dictate the terms of license they release their code under. – Smart455 Apr 16 at 4:57
  • You appear to have a too narrow view of what is a derived work under copyright law. The author of a derived work is not completely free in their choice of license, because they are also bound by the license of the work they derived from. – Bart van Ingen Schenau Apr 16 at 9:24
  • @BartvanIngenSchenau Derivative work requires actual modifications to the existing code. Adding your code to it or linking your code to a library does not constitute as modification since the original code stays the same. But even actual modifications and derived work do not limit the choice of license. This is not my narrow view, if there would be anything wrong with my interpretation, then Gnu would have the same license UNIX was licensed under. Since throughout Gnu development, it had UNIX code in it and was compiled together with the remaining UNIX code. Do you understand? – Smart455 Apr 16 at 13:53

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.