This is an automated email from Gerrit. Antonio Borneo ([email protected]) just uploaded a new patch set to Gerrit, which you can find at http://openocd.zylin.com/5608
-- gerrit commit d3760663637b34358ca894d5d49ffbd3eeeacd3d Author: Antonio Borneo <[email protected]> Date: Sun Apr 26 16:03:45 2020 +0200 [RFC] checkpath: check for spdx only GPL-2.0 or GPL-2.0-or-later The checkpatch from Linux kernel uses the external helper script spdxcheck.py to check for spdx tag in a set of possible license files. For OpenOCD the situation is far simpler, so keep it easy and embed in checkpatch the only used spdx tags. This removes the dependencies from python, the need to replicate the kernel's folders tree LICENSES and to adapt the scripts to the folder structure of OpenOCD. Change-Id: I0a40da0127746217ee0ac416058d5ceb922428ff Signed-off-by: Antonio Borneo <[email protected]> diff --git a/tools/scripts/checkpatch.pl b/tools/scripts/checkpatch.pl index c98ce9b..5399a9d 100755 --- a/tools/scripts/checkpatch.pl +++ b/tools/scripts/checkpatch.pl @@ -898,6 +898,15 @@ sub is_maintained_obsolete { sub is_SPDX_License_valid { my ($license) = @_; + $license =~ s/[ \t\*\/]*$//; + return 1 if ($license =~ /^SPDX-License-Identifier: GPL-2\.0-or-later$/); + return 1 if ($license =~ /^SPDX-License-Identifier: GPL-2\.0$/); + return 0; +} + +sub is_SPDX_License_valid_original_now_unused { + my ($license) = @_; + return 1 if (!$tree || which("python") eq "" || !(-e "$root/scripts/spdxcheck.py") || !(-e "$root/.git")); my $root_path = abs_path($root); -- _______________________________________________ OpenOCD-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/openocd-devel
