From cb38b9fe4fb5ff8cb10b049fa25482cf64ed9808 Mon Sep 17 00:00:00 2001 From: James Knight Date: Fri, 23 Feb 2024 01:01:00 -0500 Subject: [PATCH] add spdx license id to compiled header This commit adjusts the merging script to include a SPDX license identifier at the start of the single header file. This can help users of Crow which have environments using license scanning tools to help manage/monitor used implementation. Signed-off-by: James Knight --- scripts/merge_all.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/merge_all.py b/scripts/merge_all.py index 61e050926..9fc7871c6 100755 --- a/scripts/merge_all.py +++ b/scripts/merge_all.py @@ -86,7 +86,8 @@ for x in edges: assert order.index(x) < order.index(y), 'cyclic include detected' print(order) -build = [lsc, '#pragma once'] +spdx_lsc = '// SPDX-License-Identifier: BSD-3-Clause AND ISC AND MIT' +build = [spdx_lsc, lsc, '#pragma once'] for header in order: d = open(pt.join(header_path, header), encoding='UTF-8').read() d_no_depend = re_depends.sub(lambda x: '', d)