Blob Blame History Raw
#!/usr/bin/perl
use strict;
use warnings;

# List taken from http://opensource.org/licenses/alphabetical
# Fedora tags taken from https://fedoraproject.org/wiki/Licensing:Main?rd=Licensing#SoftwareLicenses
# Bad or unknown licenses are commented out
# This should be easily comparable to the current list and extended if need be
my %licenses = (
    q!Academic Free License 3.0 (AFL-3.0)! =>
    'AFL',
    q!Affero GNU Public License: See "GNU Affero General Public License 3.0 (AGPL-3.0)"! =>
    'AGPLv3',
    # q!Adaptive Public License (APL-1.0)! =>
    q!Apache License 2.0 (Apache-2.0)! =>
    'ASL 2.0',
    q!Apple Public Source License (APSL-2.0)! =>
    'APSL 2.0',
    q!Artistic license 2.0 (Artistic-2.0)! =>
    'Artistic 2.0',
    q!Attribution Assurance Licenses (AAL)! =>
    'AAL',
    q!BSD 3-Clause "New" or "Revised" License (BSD-3-Clause)! =>
    'BSD',
    q!BSD 2-Clause "Simplified" or "FreeBSD" License (BSD-2-Clause)! =>
    'BSD',
    q!Boost Software License (BSL-1.0)! =>
    'Boost',
    q!CeCILL License 2.1 (CECILL-2.1)! =>
    'CeCILL',
    q!Computer Associates Trusted Open Source License 1.1 (CATOSL-1.1)! =>
    'CATOSL',
    q!Common Development and Distribution License 1.0 (CDDL-1.0)! =>
    'CDDL',
    q!Common Public Attribution License 1.0 (CPAL-1.0)! =>
    'CPAL',
    q!CUA Office Public License Version 1.0 (CUA-OPL-1.0)! =>
    'MPLv1.1',
    q!EU DataGrid Software License (EUDatagrid)! =>
    'EU Datagrid',
    q!Eclipse Public License 1.0 (EPL-1.0)! =>
    'EPL',
    q!Educational Community License, Version 2.0 (ECL-2.0)! =>
    'ECL 2.0',
    q!Eiffel Forum License V2.0 (EFL-2.0)! =>
    'EFL 2.0',
    q!Entessa Public License (Entessa)! =>
    'Entessa',
    q!European Union Public License, Version 1.1 (EUPL-1.1) (links to every language's version on their site)! =>
    'EUPL 1.1',
    q!Fair License (Fair)! =>
    'Fair',
    #q!Frameworx License (Frameworx-1.0)! =>
    q!GNU Affero General Public License v3 (AGPL-3.0)! =>
    'AGPLv3',
    q!GNU General Public License version 2.0 (GPL-2.0)! =>
    'GPLv2',
    q!GNU General Public License version 3.0 (GPL-3.0)! =>
    'GPLv3',
    q!GNU Library or "Lesser" General Public License version 2.1 (LGPL-2.1)! =>
    'LGPLv2',
    q!GNU Library or "Lesser" General Public License version 3.0 (LGPL-3.0)! =>
    'LGPLv3',
    q!Historical Permission Notice and Disclaimer (HPND)! =>
    'MIT',
    q!IBM Public License 1.0 (IPL-1.0)! =>
    'IBM',
    q!IPA Font License (IPA)! =>
    'IPA',
    q!ISC License (ISC)! =>
    'ISC',
    q!LaTeX Project Public License 1.3c (LPPL-1.3c)! =>
    'LPPL',
    q!Lucent Public License Version 1.02 (LPL-1.02)! =>
    'LPL',
    q!MirOS Licence (MirOS)! =>
    'MirOS',
    q!Microsoft Public License (MS-PL)! =>
    'MS-PL',
    q!Microsoft Reciprocal License (MS-RL)! =>
    'MS-RL',
    q!MIT license (MIT)! =>
    'MIT',
    q!Motosoto License (Motosoto)! =>
    'Motosoto',
    q!Mozilla Public License 2.0 (MPL-2.0)! =>
    'MPLv2.0',
    #q!Multics License (Multics)! =>
    #q!NASA Open Source Agreement 1.3 (NASA-1.3)! =>
    #q!NTP License (NTP)! =>
    q!Naumen Public License (Naumen)! =>
    'Naumen',
    q!Nethack General Public License (NGPL)! =>
    'NGPL',
    q!Nokia Open Source License (Nokia)! =>
    'Nokia',
    #q!Non-Profit Open Software License 3.0 (NPOSL-3.0)! =>
    #q!OCLC Research Public License 2.0 (OCLC-2.0)! =>
    q!Open Font License 1.1 (OFL-1.1)! =>
    'OFL',
    #q!Open Group Test Suite License (OGTSL)! =>
    q!Open Software License 3.0 (OSL-3.0)! =>
    'OSL 3.0',
    q!PHP License 3.0 (PHP-3.0)! =>
    'PHP',
    q!The PostgreSQL License (PostgreSQL)! =>
    'PostgreSQL',
    q!Python License (Python-2.0) (overall Python license)! =>
    'Python',
    q!CNRI Python license (CNRI-Python) (CNRI portion of Python License)! =>
    'CNRI',
    q!Q Public License (QPL-1.0)! =>
    'QPL',
    q!RealNetworks Public Source License V1.0 (RPSL-1.0)! =>
    'RPSL',
    #q!Reciprocal Public License 1.5 (RPL-1.5)! =>
    #q!Ricoh Source Code Public License (RSCPL)! =>
    #q!Simple Public License 2.0 (SimPL-2.0)! =>
    q!Sleepycat License (Sleepycat)! =>
    'Sleepycat',
    q!Sun Public License 1.0 (SPL-1.0)! =>
    'SPL',
    #q!Sybase Open Watcom Public License 1.0 (Watcom-1.0)! =>
    q!University of Illinois/NCSA Open Source License (NCSA)! =>
    'NCSA',
    q!Vovida Software License v. 1.0 (VSL-1.0)! =>
    'VSL',
    q!W3C License (W3C)! =>
    'W3C',
    #q!wxWindows Library License (WXwindows)! =>
    #q!X.Net License (Xnet)! =>
    q!Zope Public License 2.0 (ZPL-2.0)! =>
    'ZPLv2.0',
    q!zlib/libpng license (Zlib)! =>
    'zlib'
);

my %tags;
$tags{$licenses{$_}}++ for (keys %licenses);

print 'License:        '.join(' or ', sort keys %tags)."\n";