Skip to content

Commit fb9734d

Browse files
authored
Merge pull request #1421 from nexB/new-and-improved-license-rules-03-06
Add new and improved licenses and licenses rules
2 parents 3e70c5b + 77f7358 commit fb9734d

File tree

2,151 files changed

+2811
-84391
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,151 files changed

+2811
-84391
lines changed

etc/scripts/synclic.py

Lines changed: 31 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# -*- coding: utf-8 -*-
22
#
3-
# Copyright (c) 2017 nexB Inc. and others. All rights reserved.
3+
# Copyright (c) 2019 nexB Inc. and others. All rights reserved.
44
# http://nexb.com and https://github.com/nexB/scancode-toolkit/
55
# The ScanCode software is licensed under the Apache License version 2.0.
66
# Data generated with ScanCode require an acknowledgment.
@@ -56,9 +56,9 @@
5656
- the DejaCode licenses
5757
5858
Run python synclic.py -h for help.
59-
6059
"""
6160

61+
6262
TRACE = True
6363
TRACE_ADD = True
6464
TRACE_FETCH = True
@@ -434,10 +434,6 @@ def build_license(self, mapping, scancode_licenses):
434434

435435
other_urls = list(other_urls)
436436

437-
# notes = mapping.get('licenseComments')
438-
# if notes and notes.strip():
439-
# notes = 'Per SPDX.org, ' + ' '.join(notes.split())
440-
441437
standard_notice = mapping.get('standardLicenseHeader') or ''
442438
if standard_notice:
443439
standard_notice = clean_text(standard_notice)
@@ -545,11 +541,7 @@ def build_license(self, mapping, scancode_licenses):
545541
# these licenses are combos of many others and are ignored: we detect
546542
# instead each part of the combo
547543
dejacode_special_composites = set([
548-
'lzma-sdk-2006',
549-
'intel-bsd-special',
550-
'openssh',
551-
'aes-128-3.0',
552-
'stlport-2000',
544+
'intel-bsd-special',
553545
])
554546
is_combo = key in dejacode_special_composites
555547
if is_combo:
@@ -772,27 +764,35 @@ def license_to_dict(lico):
772764
Return an OrderedDict of license data with texts for API calls.
773765
Fields with empty values are not included.
774766
"""
775-
return dict(
767+
licm = dict(
776768
is_active=False,
777769
reviewed=False,
778770
license_status='NotReviewed',
779771
is_component_license=False,
780-
781772
key=lico.key,
782773
short_name=lico.short_name,
783774
name=lico.name,
784775
category=lico.category,
785776
owner=lico.owner,
786-
homepage_url=lico.homepage_url,
787-
reference_notes=lico.notes,
788-
full_text=lico.text,
789-
is_exception=lico.is_exception,
790-
spdx_license_key=lico.spdx_license_key,
791-
text_urls='\n'.join(lico.text_urls),
792-
osi_url=lico.osi_url,
793-
faq_url=lico.faq_url,
794-
other_urls='\n'.join(lico.other_urls),
777+
is_exception=lico.is_exception
795778
)
779+
if lico.text:
780+
licm.update(full_text=lico.text)
781+
if lico.homepage_url:
782+
licm.update(homepage_url=lico.homepage_url)
783+
if lico.spdx_license_key:
784+
licm.update(spdx_license_key=lico.spdx_license_key)
785+
if lico.notes:
786+
licm.update(reference_notes=lico.notes)
787+
if lico.text_urls:
788+
licm.update(text_urls='\n'.join(lico.text_urls))
789+
if lico.osi_url:
790+
licm.update(osi_url=lico.osi_url)
791+
if lico.faq_url:
792+
licm.update(faq_url=lico.faq_url)
793+
if lico.other_urls:
794+
licm.update(other_urls='\n'.join(lico.other_urls))
795+
return licm
796796

797797

798798
EXTERNAL_LICENSE_SYNCHRONIZATION_SOURCES = {
@@ -863,12 +863,15 @@ def update_external(_attrib, _sc_val, _ext_val):
863863
# special case for URL lists, we consider all URL fields to
864864
# update
865865
if attrib.endswith('_urls',):
866-
all_sc_urls = set(list(normalized_scancode_value)
867-
+scancode_license.text_urls
868-
+scancode_license.other_urls
869-
+[scancode_license.homepage_url,
870-
scancode_license.osi_url,
871-
scancode_license.faq_url])
866+
all_sc_urls = set(
867+
list(normalized_scancode_value) +
868+
scancode_license.text_urls +
869+
scancode_license.other_urls +
870+
[scancode_license.homepage_url,
871+
scancode_license.osi_url,
872+
scancode_license.faq_url
873+
]
874+
)
872875
all_sc_urls = set(u for u in all_sc_urls if u)
873876
new_other_urls = normalize_external_value.difference(all_sc_urls)
874877
# add other urls to ScanCode
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
All code contained in this distributed is placed in the public domain.
2+
=============================================================
3+
Disclaimer:
4+
THIS SOFTWARE IS PROVIDED BY THE AUTHORS ''AS IS''
5+
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
6+
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
7+
PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS
8+
BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
9+
OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
10+
OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
11+
BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
12+
WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
13+
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
14+
EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
15+
=============================================================
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
key: aes-128-3.0
2+
short_name: AES-128 3.0 License
3+
name: AES-128 v3.0 License
4+
category: Public Domain
5+
owner: Unspecified
6+
minimum_coverage: 90
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
key: alfresco-exception-0.5
2-
name: Alfresco FLOSS Exception v0.5
32
short_name: Alfresco FLOSS Exception v0.5
3+
name: Alfresco FLOSS Exception v0.5
44
category: Copyleft
55
owner: Alfresco
66
homepage_url: https://web.archive.org/web/20070306001556/http://www.alfresco.com/legal/licensing/floss_exception/

src/licensedcode/data/licenses/autoconf-simple-exception-2.0.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,5 @@ name: Autoconf simple exception to GPL-2.0
44
category: Copyleft Limited
55
owner: Free Software Foundation (FSF)
66
homepage_url: https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob;f=config.guess;h=a7448442748cc6f98a066d2d1051fad3b043761a;hb=HEAD
7-
notes: |-
8-
this is a simpler version of the Autonconf exception to the GPL
7+
notes: this is a simpler version of the Autonconf exception to the GPL
98
is_exception: yes

src/licensedcode/data/licenses/blitz-artistic.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@ name: Blitz++ Artistic License
44
category: Copyleft Limited
55
owner: Blitz++
66
homepage_url: https://github.com/blitzpp/blitz
7-
notes: This is a modified artistic license, no longer in use.
7+
notes: This is a modified artistic license, no longer in use.
88
text_urls:
99
- https://raw.githubusercontent.com/blitzpp/blitz/e3c973d68e5ee17aec779bf9711b38fd4afc355f/LICENSE
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
key: bsd-3-clause-no-change
2-
short_name: BSD 3-Clause No Change
3-
name: BSD 3-Clause No Change
2+
short_name: BSD 3-Clause No Change
3+
name: BSD 3-Clause No Change
44
category: Permissive
5-
owner: David Corcoran <[email protected]>
5+
owner: David Corcoran <[email protected]>
66
homepage_url: https://pcsclite.apdu.fr/
7+
notes: there is an extra clause about changes which has some ambiguities
78
other_urls:
89
- https://salsa.debian.org/rousseau/PCSC/blob/master/COPYING
9-
notes: there is an extra clause about changes which has some ambiguities

src/licensedcode/data/licenses/bsd-original-muscle.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,5 @@ name: BSD-Original MUSCLE
44
category: Permissive
55
owner: David Corcoran
66
homepage_url: https://web.archive.org/web/20060318003856/http://linuxnet.com/
7-
notes: This license has some extra terms beyond the advertizing clause not found in the bsd-originl
7+
notes: This license has some extra terms beyond the advertizing clause not found in the bsd-original
8+
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
key: cvwl
22
short_name: Collaborative Virtual Workspace License
33
name: Collaborative Virtual Workspace License
4-
category: Proprietary
4+
category: Proprietary Free
55
owner: Mitre
66
homepage_url: https://opensource.org/licenses/mitrepl
77
minimum_coverage: 30

src/licensedcode/data/licenses/dwtfnmfpl-3.0.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,4 @@ name: DWTFNMFPL-3.0
44
category: Permissive
55
owner: dittodhole
66
homepage_url: https://github.com/dittodhole/WTFNMFPLv3
7-
notes: A variation Do What The Fuck You Want
8-
Public License (WTFPL) by Sam Hocevar.
7+
notes: A variant on the Do What The Fuck You Want Public License (WTFPL) by Sam Hocevar.

0 commit comments

Comments
 (0)