Licensing requirements

My impression from reading http://llvm.org/docs/DeveloperPolicy.html#clp is that it's intended to be possible to compile programs using llvm and distribute the resulting binaries freely. This does not seem to be the case.

I'm assuming no portion of LLVM is included in the compiled binaries, only the runtime library components, so that the compiled binaries are not derived from LLVM. Is that true?

The runtime library components state that they are licensed under http://www.opensource.org/licenses/mit-license.php which does not contain a specific clause regarding binary redistribution. This seems to have been interpreted as not placing any restrictions on binary redistribution, i.e. that "all copies" has somehow been interpreted as "copies in source code form". (Different licenses such as Boost, zlib, and bzip2 etc. do not require copyright notices for binary redistributions.)

Is it sufficient to include the MIT copyright notices from http://llvm.org/svn/llvm-project/compiler-rt/trunk/LICENSE.TXT / http://llvm.org/svn/llvm-project/libcxx/trunk/LICENSE.TXT for programs compiled with LLVM? (Probably including the respective CREDITS.TXT files as a courtesy, although there doesn't seem to be any actual requirements to indicate that it's for Compiler-RT/libc++)

And finally, could it be possible to change the licensing (again) so that no notices would be required?

   - Tor Gunnar

Other than having you read:

http://llvm.org/docs/DeveloperPolicy.html#license

your best bet is to consult your lawyer with questions like this.

-eric

My impression from reading http://llvm.org/docs/DeveloperPolicy.html#clp
is that it's intended to be possible to compile programs using llvm and
distribute the resulting binaries freely. This does not seem to be the case.

I'm assuming no portion of LLVM is included in the compiled binaries,
only the runtime library components, so that the compiled binaries are
not derived from LLVM. Is that true?

This is true if you use clang. If you use the LLVM libraries to build other compilers, it depends on that compiler.

The runtime library components state that they are licensed under
http://www.opensource.org/licenses/mit-license.php which does not
contain a specific clause regarding binary redistribution. This seems to
have been interpreted as not placing any restrictions on binary
redistribution, i.e. that "all copies" has somehow been interpreted as
"copies in source code form". (Different licenses such as Boost, zlib,
and bzip2 etc. do not require copyright notices for binary redistributions.)

Is it sufficient to include the MIT copyright notices from
http://llvm.org/svn/llvm-project/compiler-rt/trunk/LICENSE.TXT /
http://llvm.org/svn/llvm-project/libcxx/trunk/LICENSE.TXT for programs
compiled with LLVM? (Probably including the respective CREDITS.TXT files
as a courtesy, although there doesn't seem to be any actual requirements
to indicate that it's for Compiler-RT/libc++)

There is no need to include any notices in the binaries of an application built with clang, or some with some other application that links to the LLVM runtime libraries that are dual licensed.

And finally, could it be possible to change the licensing (again) so
that no notices would be required?

Not sure what you mean.

-Chris

Thanks for your response. Is this ability to distribute binaries without notices based on your personal assertion that the MIT license used does not require them? (I do not use clang but I assumed you were just clarifying front-end vs back-end, and that it's not because of a guarantee offered to clang users, an automatic inclusion of the notice stuffed inside binaries created using clang, or anything like that?)

The license in LICENSE.TXT actually lists the following conditions, which do not exclude binaries:

     The above copyright notice and this permission notice shall be included in
     all copies or substantial portions of the Software.

(See e.g. http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=610257 , http://ideas.opensource.org/ticket/45 , about:license#expat in Firefox compared to about:license#optional-notices , or Help->Acknowledgments in Safari)

Is there anything else that would permit distributing the runtime libraries without complying with the LICENSE.TXT conditions?

   - Tor Gunnar

I'm assuming no portion of LLVM is included in the compiled binaries,
only the runtime library components, so that the compiled binaries are
not derived from LLVM. Is that true?

Yes. Code compiled with LLVM is not a derived work of LLVM and as such
not subject to the LLVM license.

The runtime library components state that they are licensed under
http://www.opensource.org/licenses/mit-license.php which does not
contain a specific clause regarding binary redistribution. This seems to
have been interpreted as not placing any restrictions on binary
redistribution, i.e. that "all copies" has somehow been interpreted as
"copies in source code form". (Different licenses such as Boost, zlib,
and bzip2 etc. do not require copyright notices for binary redistributions.)

If you want a hard answer, you have to ask a copyright lawyer. The
normal interpreation is that all copies include binary versions and if
you ship compiled code (e.g. compiler_rt), you have to include a copy of
the license file or the copyright note in your distribution. The MIT
license is generally considered equivalent to the 2-clause BSD license
in this regard.

Note that the GCC runtime doesn't differ in this regard, even with the
exception clause.

Is it sufficient to include the MIT copyright notices from
http://llvm.org/svn/llvm-project/compiler-rt/trunk/LICENSE.TXT /
http://llvm.org/svn/llvm-project/libcxx/trunk/LICENSE.TXT for programs
compiled with LLVM? (Probably including the respective CREDITS.TXT files
as a courtesy, although there doesn't seem to be any actual requirements
to indicate that it's for Compiler-RT/libc++)

Yes, if you distribute them with (or in the case of static linkage, as
part of) your program.

And finally, could it be possible to change the licensing (again) so
that no notices would be required?

I don't think that's likely to happen.

Joerg

Yes. I am not a lawyer and am not giving legal advice. This is based on my understanding of the MIT license.

-Chris

OK, thanks. That's contradictory to the actual conditions written in the license, and as such the dual-licensing does not serve that purpose. Could http://llvm.org/docs/DeveloperPolicy.html#license be updated to reflect that?

(Or do you strongly disagree that "all copies of the software" includes "binary"? When changing the license, you mentioned an example of Mozilla building with Clang. As can be seen in about:license, they consider MIT licenses to require reproduction of the license text. What's your reasoning for your understanding?)

I really agree with the intentions, it would be nice for user-compiled programs not to unwittingly include code that imposes licensing conditions. It would be great if it were feasible to also provide such a different license, or additional permissions similar to what GNU libstdc++ does.

   - Tor Gunnar

[...]

I really agree with the intentions, it would be nice for user-compiled
programs not to unwittingly include code that imposes licensing
conditions.

It's pretty narsty, but including the text of the license in a data
segment that gets automatically linked into the final program will
satisfy the letter of the license text --- after all, it doesn't say it
has to be *readable*.

My reading of the MIT license is that it requires binary attribution,
too --- it doesn't distinguish between source and binary and therefore
applies to both. But I'd very much like to be wrong.

- --
┌─── dg@cowlark.com ───── http://www.cowlark.com ─────

│ "I have a mind like a steel trap. It's rusty and full of dead mice."
│ --- Anonymous, on rasfc

I, and many other reasonable people, consider the phrase:

"The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software."

... to be talking about *copies of the software*. A binary is not a copy of the software, it is a lump of bits derived from it.

I am not a lawyer, and do not offer this as legal advise. However, lawyers that I respect agree with this interpretation. You can choose to interpret it however you would like.

-Chris

Thanks, that looks quite short and clear, though it doesn't seem to be obvious (and I would not personally wish to rely on it).

Would it be possible to add something like that to http://llvm.org/docs/DeveloperPolicy.html#license so it's clear how it was interpreted? Do you happen to know if all the copyright holders also interpret it that way?

   - Tor Gunnar

I, and many other reasonable people, consider the phrase:

"The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software."

... to be talking about *copies of the software*. A binary is not a copy of the software, it is a lump of bits derived from it.

I am not a lawyer, and do not offer this as legal advise. However, lawyers that I respect agree with this interpretation. You can choose to interpret it however you would like.

Thanks, that looks quite short and clear, though it doesn't seem to be obvious (and I would not personally wish to rely on it).

Would it be possible to add something like that to http://llvm.org/docs/DeveloperPolicy.html#license so it's clear how it was interpreted?

No, and it is pretty useless to ask for that. How I interpret it doesn't really matter, and that page doesn't give legal advice.

You seem to be hung up on mozilla including MIT code in their about box. There is a big difference between them choosing to include the text, as a sign of good faith, and them being forced to include it legally.

Do you happen to know if all the copyright holders also interpret it that way?

No I don't.

-Chris

Tor Gunnar Houeland wrote:
[...]

Thanks, that looks quite short and clear, though it doesn't seem to be
obvious (and I would not personally wish to rely on it).

Some random searching on t'interweb shows that people in general appear
to be undecided as to whether the MIT license requires attribution in
binaries.

Given that the process of compiling source code to binary can be
considered to be a mathematical transform, I think it's perfectly
reasonable to argue that the source and the binary are equivalent and
therefore the phrase 'all copies or substantial portions of the
software' applies to both.

Certainly, for my day job I write commercial software with MIT code
embedded in it, and our legal department have told us we must provide a
copy of the MIT license with our binaries.

David Given wrote:
> Tor Gunnar Houeland wrote:
> [...]
> > Thanks, that looks quite short and clear, though it doesn't seem to be
> > obvious (and I would not personally wish to rely on it).
>
> Some random searching on t'interweb shows that people in general appear
> to be undecided as to whether the MIT license requires attribution in
> binaries.
>
> Given that the process of compiling source code to binary can be
> considered to be a mathematical transform, I think it's perfectly
> reasonable to argue that the source and the binary are equivalent and
> therefore the phrase 'all copies or substantial portions of the
> software' applies to both.
>
> Certainly, for my day job I write commercial software with MIT code
> embedded in it, and our legal department have told us we must provide a
> copy of the MIT license with our binaries.

Yeah, there certainly appears to be some confusion, with people writing and asking questions on forums and mailing lists and saying various things.

In any case it would be accurate to say that such binaries are covered by the MIT-style license, whether that requires inclusion of the notices alongside the binaries or not.

OSI, FSF and the Wikipedia page are pretty clear and say that it's roughly equivalent to BSD.

Mozilla explicitly lists MIT-style license notices as requiring reproduction.

I'm not a lawyer, but I think the license text itself is pretty clear too. You are granted permissions for "the Software", under conditions for "the Software". If you're distributing something that's not "the Software", then the license doesn't grant you permissions for that. (The precise consequence of copyright law if not following the license is of course not as clear or simple.)

   - Tor Gunnar