From 9b131026a70c6cd89722620775f2bbd26e0df5df Mon Sep 17 00:00:00 2001 From: mahlzahn Date: Sun, 15 Oct 2023 17:41:11 +0200 Subject: [PATCH] add packages ambiguation and additional licenses --- src/vrms_arch/disambiguation.py | 6 ++++++ src/vrms_arch/license_finder.py | 28 ++++++++++++++++++++++------ 2 files changed, 28 insertions(+), 6 deletions(-) diff --git a/src/vrms_arch/disambiguation.py b/src/vrms_arch/disambiguation.py index e691f0b..9b991d3 100644 --- a/src/vrms_arch/disambiguation.py +++ b/src/vrms_arch/disambiguation.py @@ -6,6 +6,7 @@ 'adobe-source-serif-pro-fonts': ['OFL'], 'amd-ucode': ['custom:non-free'], 'aom': ['BSD', 'custom:free'], + 'apptainer': ['BSD-3-Clause-LBNL'], 'blas': ['custom:BSD-like'], 'boost': ['Boost'], 'boost-libs': ['Boost'], @@ -17,6 +18,7 @@ 'cups-filters': ['GPL', 'GPL2', 'GPL3-only', 'GPL3'], 'db': ['custom:Sleepycat'], 'discord': ['custom:non-free'], + 'endless-sky': ['custom:GPL-2.0-or-later', 'custom:GPL-3.0-or-later', 'custom:public-domain', 'custom:CC0', 'custom:CC-BY-2.0', 'custom:CC-BY-3.0', 'custom:CC-BY-4.0', 'custom:CC-BY-SA-3.0', 'custom:CC-BY-SA-4.0'], 'expat': ['MIT'], 'file': ['BSD'], 'flashplugin': ['custom:non-free'], @@ -131,6 +133,7 @@ 'spirv-tools': ['Apache'], 'steam': ['custom:non-free'], 'sudo': ['ISC', 'BSD3', 'BSD2', 'ZLIB'], + 'svt-av1': ['BSD-3-Clause'], # additionally 'Alliance for Open Media Patent License 1.0' 'tcl': ['custom:BSD-like'], 'tk': ['custom:BSD-like'], 'ttf-bitstream-vera': ['custom:bitstream-vera'], @@ -157,6 +160,7 @@ 'xfce4-wavelan-plugin': ['BSD2'], 'xfce4-xkb-plugin': ['BSD2'], 'xkeyboard-config': ['MIT', 'custom:HPND', 'custom:X11', 'custom:MIT-style'], + 'xcalib': ['GPL-2.0'], # additionally with optional postcardware 'xorg-bdftopcf': ['custom:X11'], 'xorg-fonts-encodings': ['custom:Public Domain'], 'xorg-font-util': ['custom:UCD', 'MIT', 'BSD2'], @@ -197,6 +201,8 @@ 'zoom': ['custom:non-free'], # AUR 'zsh-abbr': ['custom:CC-BY-NC-SA-4.0', 'custom:Hippocratic'], # AUR 'zsh': ['custom:MIT-style', 'GPL'], + 'zeroc-ice': ['GPL-2.0-only'], # alternatively non-free commercial license + 'zeroc-ice-java': ['GPL-2.0-only'], # alternatively non-free commerical license } class Package(object): diff --git a/src/vrms_arch/license_finder.py b/src/vrms_arch/license_finder.py index 611065d..b209890 100644 --- a/src/vrms_arch/license_finder.py +++ b/src/vrms_arch/license_finder.py @@ -15,8 +15,9 @@ def clean_license_name(license): # CCPL (Creative Commons) should be specified with one of the # sublicenses (one of /usr/share/licenses/common/CCPL/*), some of # which are non-free - "Creative Commons", + "CC", "CCPL", + "Creative Commons", ]] FREE_LICENSES = [clean_license_name(license) for license in [ @@ -36,12 +37,14 @@ def clean_license_name(license): 'Beerware', 'bitstream-vera', 'Boost', + '0BSD', 'BSD', 'BSD2', - 'BSD-2-clause', + 'BSD-2-Clause', 'BSD-2-Clause-Patent', 'BSD3', - 'BSD-3-clause', + 'BSD-3-Clause', + 'BSD-3-Clause-LBNL', 'BSD License', 'BSD-like', 'BSDL', @@ -49,13 +52,17 @@ def clean_license_name(license): 'BSL', 'bzip2', 'CC0', - 'CC0 1.0', + 'CC0-1.0', + 'CC-BY', + 'CC-BY-2.5', 'CC-BY-3.0', + 'CC-BY-4.0', 'CC-BY-SA', 'CC-BY-SA-2.5', 'CC-BY-SA-3.0', - 'CC BY-SA-4.0', + 'CC-BY-SA-4.0', 'CCPL:by', + 'CCPL:by-4.0' 'CCPL:by-sa', 'CCPL:cc-by', 'CCPL:cc-by-sa', @@ -81,6 +88,7 @@ def clean_license_name(license): 'FFSL', 'FIPL', 'font embedding exception', + 'Free Public License 1.0.0', 'FSFAP', 'GD', 'GFDL', @@ -134,11 +142,14 @@ def clean_license_name(license): 'LGPL2_1', 'LGPL-2.1-only', 'LGPL-2.1-or-later', + 'LGPL2.1 with linking exception', 'LGPL3', 'LGPLv3+', 'LGPL-3.0', 'LGPL-3.0-only', 'LGPL-3.0-or-later', + 'LGPL-3.0+ with WxWindows-exception-3.1', + 'LGPL-exception', 'libpng', 'libtiff', 'libxcomposite', @@ -155,15 +166,18 @@ def clean_license_name(license): 'MPL2', 'MPLv2', 'NCSA', + 'NCSAOSL', 'neovim', 'nfsidmap', 'NoCopyright', + 'NYSL', 'OASIS', 'OFL', 'OFL-1.1', 'OPEN DATA LICENSE', 'OpenLDAP', 'OpenMPI', + 'OpenSSL Linking Exception', 'OSGPL', 'perl', 'PerlArtistic', @@ -174,7 +188,7 @@ def clean_license_name(license): 'PostgreSQL', 'PSF', 'Public', - 'Public Domain', + 'public-domain', 'Python', 'Qhull', 'QPL', @@ -183,6 +197,7 @@ def clean_license_name(license): 'Ruby', 'scite', 'scowl', + 'sdbus-c++ LGPL Exception 1.0', 'Sendmail', 'Sendmail open source license', 'SGI', @@ -218,6 +233,7 @@ def clean_license_name(license): 'X11-DEC', 'XFREE86', 'Xiph', + 'Zero-Clause BSD', 'zlib', 'zlib/libpng', 'ZPL',