Opening this tracker mostly as a single point of reference for how to fix missing LICENSE entries. I've been using dev-util/ninka to help me recognize the missing licenses. The most effective way is: $ ebuild foo-1.ebuild unpack $ cd /tmp/portage/whatever/work $ find '(' -name '*LICEN[SC]E*' -o -name '*COPYING*' ')' -exec ninka {} ';' |& tee ninka $ cut -d';' -f2 ninka | sort -u This outputs all recognized licenses. If there's UNKNOWN on the list, you gotta read them separately: $ grep '^[^;]*;UNKNOWN' ninka | cut -d';' -f1 | xargs $EDITOR Mapping from ninka terms to Gentoo terms: Apache-2 → Apache-2.0 BSD3 → BSD MIToldwithoutSellandNoDocumentationRequi → ISC (with 'and/or' → 'and') MITX11BSDvar → ISC spdxBSD2 → BSD-2 spdxBSD3 → BSD spdxMIT → MIT Multiple entries indicate that the license in question appears multiple time in the file. Note that this is only very dumb process. You still have to figure out how licenses apply, i.e. some packages may have multiple LICENSE* files and you have to figure if it's AND or OR.
A generic note on license compatibility: if the packages vendors any dependency whose license is LGPL and GPL (and does not include explicit linking exception on top), then the package must be LGPL/GPL as well. This is something that needs to be reported upstream. Feel free to ping me for help.
https://github.com/google/go-licenses
(In reply to Konstantin (Qrator Labs) from comment #2) > https://github.com/google/go-licenses This is great. To get the list of transitively used licenses: $go-licenses csv github.com/user/project | awk -F ',' '{print $NF}' | sort | uniq
should www-apps/grafana-bin also be considered?
I've made a pull request to add this tool to portage tree https://github.com/gentoo/gentoo/pull/15508
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=09efbf4ed38ffb300545cb132cd313d4943c8010 commit 09efbf4ed38ffb300545cb132cd313d4943c8010 Author: Konstantin Podshumok <kpp.live+signed@gmail.com> AuthorDate: 2020-04-25 01:35:05 +0000 Commit: Joonas Niilola <juippis@gentoo.org> CommitDate: 2020-05-12 13:57:08 +0000 dev-go/licenseclassifier: new ebuild I find this tool very helpful for managing LICENSE in different ebuilds. Just run identify_license on any file - just a source code or COPYING/LICENSE file. It also can be built against licenses in /var/db/repos/gentoo/licenses, but this is not yet implemented in this commit. Bug: https://bugs.gentoo.org/694792 Bug: https://bugs.gentoo.org/694790 Signed-off-by: Konstantin Podshumok <kpp.live+signed@gmail.com> Signed-off-by: Joonas Niilola <juippis@gentoo.org> dev-go/licenseclassifier/Manifest | 12 ++++ .../licenseclassifier-0_pre20200402.ebuild | 84 ++++++++++++++++++++++ dev-go/licenseclassifier/metadata.xml | 22 ++++++ 3 files changed, 118 insertions(+)