Page MenuHomePhabricator

[PATCH] [llvm] [Support] Update license on ConvertUTF.* per upstream license change

Authored by mgorny on Aug 18 2019, 3:07 AM.



According to [1], the author of the code found in ConvertUTF.* has
stated that the code has been relicensed to the standard Unicode license
as found on [2]. Update our copyright header appropriately, following
the same action done by Google breakpad maintainers [3].

Most importantly, the old license was non-free, effectively rendering
the whole LLVM distribution non-free. This is a major problem e.g. for
Debian [4], and has been also reported to LLVM Bugzilla [5]. I have
accidentally missed this license in Gentoo, and adding it will render
the package non-free which is going to cause real pain to some of our

Sylvestre Ledru has already started working on porting LLVM to use
breakpad's version but apparently his work was stalled in regressions.
Since the issue is urgent, I am proposing instead to update the license
without porting other changes.


Diff Detail

Event Timeline

mgorny created this revision.Aug 18 2019, 3:07 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 18 2019, 3:07 AM

I don't think we can unilaterally update the license. Especially as the new code is different.
My change need some work (summer doesn't help). The testsuites work, the unit tests on this file don't.

And it isnt really urgent as it has been this way for years now

As I've noted on D64740, the code in breakpad is identical (except for ordering and whitespace changes) to our initial code. All code differences between us and breakpad are our local changes. Therefore, I think we can change the license in place. If you really insist, I can reorder the functions match ordering in breakpad, and do some whitespace changes ;-).

@chandlerc What do you think? thanks!

Some more ping.

sylvestre.ledru resigned from this revision.Jun 18 2020, 3:47 AM

I would like to see that happening but I am not a lawyer and important enough person in the project to make such call.

With my experience with license (ex: iceweasel vs firefox), I am sure that @chandlerc isn't ignoring you, just that he cannot answer about this subject.

Indeed, legal issues are complicated.

Looking into this today, I'm personally fairly confident this code is indeed re-licensed and that, therefore, this change is OK. I say that based on analysis as follows:

  1. (archived 2008-08-31) has the new license text in place, and says it applies to all source code distributed under
  2. You can find the ConvertUTF.c and ConvertUTF.h files at (archive link as of 2008-09-13, but file content unchanged since 2004). That is: they were being distributed, then, under this "new" license. Note that the files were subsequently deleted, in 2009, due to being buggy and unmaintained -- so you cannot find them on today.
  3. LLVM's initial commit of these files ( contains files derived -- with only LLVM-side changes -- from the version of the software distributed in that link.

I'm not giving an "Approval" to commit this change yet, though -- I believe LLVM Foundation lawyer will be double-checking this is a correct action, first.

Herald added a project: Restricted Project. · View Herald TranscriptJun 2 2022, 1:21 PM
tonic added a subscriber: tonic.Jul 21 2022, 11:38 AM
tonic added a comment.Jul 29 2022, 3:24 PM

After legal consult, The LLVM Foundation board is ok with the change to the license on these files.

gribozavr resigned from this revision.Jul 31 2022, 8:19 AM
This revision was not accepted when it landed; it landed in state Needs Review.Aug 12 2022, 9:54 AM
This revision was automatically updated to reflect the committed changes.