Skip to content

Why GPL instead of LGPL? Why no linking exception? #5

@ngoffee

Description

@ngoffee

I'm not an expert in OCaml or JavaScript, just someone who's exploring the various functional languages that compile to JavaScript for use in a long-term hobby project.

Your README says:

Since our work is derivative work of js_of_ocaml, the license of the OCamlScript components is GPLv2, the same as js_of_ocaml.

But the js_of_ocaml license is LGPL, not GPL. In https://github.com/ocsigen/js_of_ocaml/blob/master/LICENSE, the relevant statement is:

The Compiler and Library are distributed under the terms of the GNU
Library General Public License version 2 (included below).

[emphasis mine]

As I understand it (I'm not an expert by any means), using GPL instead of LGPL (for library/runtime files; for the compiler, it doesn't matter) prevents combining with commercial software, or with software under a license that's incompatible with the GPL, such as the Eclipse Public License. (Suppose someone wants to port something from the Clojure(Script) ecosystem, which is largely EPL.)

Secondly, the js_of_ocaml license also includes the following useful exception:

As a special exception to the GNU Library General Public License, you
may link, statically or dynamically, a "work that uses the Library"
with a publicly distributed version of the Library to produce an
executable file containing portions of the Library, and distribute
that executable file under terms of your choice, without any of the
additional requirements listed in clause 6 of the GNU Library General
Public License.

If I understand correctly, this exception is useful for (among other things) distributing open-source software via the Apple app store, whose terms are otherwise incompatible with the GPL or LGPL. While much software compiled to JavaScript is just distributed via a web server, where no app store licenses apply, one might also want to distribute compiled-to-JavaScript code (and the accompanying runtime and library) in a Cordova or React Native app.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions