summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Olbrich <m.olbrich@pengutronix.de>2018-02-12 12:53:40 +0100
committerMichael Olbrich <m.olbrich@pengutronix.de>2018-03-12 08:59:43 +0100
commita7c077494b0e855b505f8152e78fc1abccb002dd (patch)
treeddee6a1c434ff7b213a9b6c84655500a4cecb06a
parent6266e44d4f1e1960e06a6ed5d5355bc0228f8c7d (diff)
downloadptxdist-a7c077494b0e855b505f8152e78fc1abccb002dd.tar.gz
ptxdist-a7c077494b0e855b505f8152e78fc1abccb002dd.tar.xz
ptxd_create_section_from_license: put deprecated licenses in a separate section
This way, they are easily fond and can be updated. Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
-rw-r--r--scripts/lib/ptxd_make_world_license.sh9
1 files changed, 7 insertions, 2 deletions
diff --git a/scripts/lib/ptxd_make_world_license.sh b/scripts/lib/ptxd_make_world_license.sh
index 8681aabb8..1a79387b0 100644
--- a/scripts/lib/ptxd_make_world_license.sh
+++ b/scripts/lib/ptxd_make_world_license.sh
@@ -288,12 +288,15 @@ ptxd_create_section_from_license()
IFS=$'(), '
for license in ${1}; do
+ local deprecated="false"
local osi="false"
local exception="false"
# remove the 'or later' modifier
license="${license%+}"
if ptxd_make_spdx "${license}"; then
- if [ "${osi}" == "true" ]; then
+ if [ "${deprecated}" == "true" ]; then
+ section[deprecated]="true"
+ elif [ "${osi}" == "true" ]; then
section[osi-conform]="true"
elif [ "${exception}" != "true" ]; then
section[misc]="true"
@@ -328,7 +331,9 @@ ptxd_create_section_from_license()
echo "${!section[@]}"
return 0
fi
- if [ "${section[other]}" = "true" ]; then
+ if [ "${section[deprecated]}" = "true" ]; then
+ echo "deprecated"
+ elif [ "${section[other]}" = "true" ]; then
echo "other"
else
echo "mixed"