[cfe-dev] standard headers question

Daniel Berlin dberlin at dberlin.org
Fri Dec 14 12:33:48 PST 2007

So, speaking as a lawyer, you are best off with the LLVM licensewith
the "binary form should reproduce" clause removed, or the MIT license.

Binary form for headers never really matters except if you start using
inline functions, because the binary form of a header is often nothing
for C.  However, it is a legal gray area, and it's easier to just
avoid it.  Otherwise, you are going to get lawyers at corporations
claiming they can't use your headers because they have to put stuff in
their about boxes.

Make damn sure the copyright header is the same on all of them:

I have had the fun experience of having to paste 50 different
copyright notices and licenses into documentation because of binary
form requirements in headers that include inline functions before :)

In this case, the copyright was different for each piece, and since
the conditions said " 2. Redistributions in binary form must reproduce
the above copyright
 *    notice, this list of conditions and the following disclaimer in the
 *    documentation and/or other materials provided with the distribution.
we ended up with 50 different copies of this that only differed in the
copyright owner (since it says "the above copyright notice and this
list of conditions," and they are thus unique and different when you
change the above copyright notice :P)
MIT would also be fine (it is more or less the same as LLVM license
without the binary form attribution)

The main point is that you don't want to get into a situation where
you have either multiple licenses, or licenses that require people to
put lots of text in binaries that use headers.

I'll note that Apple's headers are mostly APSL, but i can't tell what
the hell the license really is for something like /usr/include/time.h
on darwin (it's not clear if they got permission to relicense, or they
are claiming their license on the parts they made,  but not  the
original, or what.  I hope they have permission to relicense, because
if there are parts still covered by the 4-clause BSD license listed, a
lot of people are in violation of the license :)

More information about the cfe-dev mailing list