3

MPL & CC-BY-SA both allow putting only a small license statement to place I deem fit. But both of them use "this":

This Source Code Form is subject to the terms of the Mozilla Public License


This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

I'm not risking rephrasing the notes because I don't know if it's allowed (in MPL case it seems hardcoded), even though I want to. Is it OK to put it all into a separate file stating something like:

For source code: [MPL note]

For non source code: [CC note]

implying that MPL is for all source code files and CC is for the rest?

2
  • What do you mean by separate file? A LICENSE file? Can you elaborate on what is the source of the code and what are your motives?
    – Zimm i48
    Commented Sep 22, 2016 at 9:10
  • @Zimmi48 Yes, a license file. Code is my own (I don't intend modyfing other's license notices). Motive is to avoid inclusion of a license notice in each file. Commented Sep 22, 2016 at 9:32

2 Answers 2

3

MPL license

The recommended way of applying the MPL license to your source code is to include Exhibit A in the headers of your source files. However, because it is not always a good solution (some languages do not allow comments for instance), the MPL license contains the following advice:

If it is not possible or desirable to put the notice in a particular file, then You may include the notice in a location (such as a LICENSE file in a relevant directory) where a recipient would be likely to look for such a notice.

So if your prefer, you do not need to add a header to every source file. You could instead add a LICENSE file in your src/ directory if all source code is located there. You would start the LICENSE file with Exhibit A, possibly a statement of your copyright ownership, then the text of the license itself. You could also put the exhibit in your README instead.

You are right that Exhibit A is part of the text of the license itself:

1.4. “Covered Software”

means Source Code Form to which the initial Contributor has attached the notice in Exhibit A, the Executable Form of such Source Code Form, and Modifications of such Source Code Form, in each case including portions thereof.

What do you risk by not putting the exhibit in every source file or using a different license notice?

Legally you are not at risk, even if you license your software improperly, because your are the owner but:

  • Many uninformed developers tend to confound unlicensed source code (published on Github for instance) with public domain source code. These developers will typically reuse your code without respecting the terms of the license unless you make it very explicit.

  • Corporate developers will typically shy away from reusing code if their lawyers do not think that the applicable license is clear enough. If that happens, they are most likely to contact you, asking that you change the wording a little so that they can reuse your code. If they ask you to add a header in a particular file, it will be up to you to do so or not.

Creative Commons license

You will remark that notices that a work is published under CC-BY-SA can vary greatly from one source to another but they will generally include a canonical link for the license: https://creativecommons.org/licenses/by-sa/4.0/.

The text of the license does not restrict you in any way on how to apply the license to your work:

Licensed Material means the artistic or literary work, database, or other material to which the Licensor applied this Public License.

You should just use a clear statement and include it somewhere where people are likely to look for it (a README, LICENSE or About page). Example of such statement:

The non source code content of this application is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

Example of such a double notice

Here is an example of a project distinguishing between source code and non source code (granted they use MIT, not MPL 2.0): https://github.com/github/choosealicense.com/blob/gh-pages/README.md#license

The content of this project itself is licensed under the Creative Commons Attribution 3.0 license, and the underlying source code used to format and display that content is licensed under the MIT license.

4
  • Thank you for an answer, but I do know these advices and that I'm somewhat free to choose a place for a notice. I consider "License.txt" in the root folder to be accessable and noticeable (just like "ReadMe.txt"). My confusion is caused by the use of "this" and combination of several notices. Commented Sep 22, 2016 at 10:00
  • 1
    This should not be a problem (see also my edit). If you are worried about "this" you can change it. The sentence is not really part of the license itself so it is up to you. In particular, it is very common to find variations of this sentence for CC-BY-SA.
    – Zimm i48
    Commented Sep 22, 2016 at 10:43
  • I'm not sure, but in case of MPL notice seems like a part of the license. Or is there some legal practice/convention that allows altering notices? Commented Sep 22, 2016 at 23:54
  • You are right for MPL. I edited my answer to clarify all of this.
    – Zimm i48
    Commented Sep 23, 2016 at 10:54
2

Motive is to avoid inclusion of a license notice in each file.

My 2 cents: explicit is better than implicit. To make it easier and clear to my users, I find it is always best to put explicit notices in the source file themselves and eventually in the binaries too. Anything else would be a source of confusion.

Now there are ways like using a short SPDX license identifier to make this statement short and that could be combined with top level notices. This is an approach used by Uboot for instance.

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.