summaryrefslogtreecommitdiffstats
path: root/scripts/lib/recipetool/create_npm.py
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2016-05-30 10:20:59 +1200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-06-01 12:38:41 +0100
commit2b510f5e018fed5f0e679d887656a501a6a38aaa (patch)
tree8cbe6c7f640defa9137229edd0feb3b1ee644f49 /scripts/lib/recipetool/create_npm.py
parentc056dad62cdc4d4043e8ac91ff103d234005660f (diff)
downloadpoky-2b510f5e018fed5f0e679d887656a501a6a38aaa.tar.gz
recipetool: create: support extracting SUMMARY and HOMEPAGE
Allow plugins to set any variable value through the extravalues dict, and use this to support extracting SUMMARY and HOMEPAGE values from spec files included with the source; additionally translate "License:" to a comment next to the LICENSE field (we have our own logic for setting LICENSE, but it will often be useful to see what the spec file says if one is present). Also use the same mechanism for setting the same variables for node.js modules; this was already supported but wasn't inserting the settings in the appropriate place in the file which this will now do. (From OE-Core rev: 91fc35ff5e89aa6d4c4ad945e45406fb4f71018e) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/lib/recipetool/create_npm.py')
-rw-r--r--scripts/lib/recipetool/create_npm.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/lib/recipetool/create_npm.py b/scripts/lib/recipetool/create_npm.py
index cc4fb42684..ffbcb4905c 100644
--- a/scripts/lib/recipetool/create_npm.py
+++ b/scripts/lib/recipetool/create_npm.py
@@ -104,9 +104,9 @@ class NpmRecipeHandler(RecipeHandler):
104 classes.append('npm') 104 classes.append('npm')
105 handled.append('buildsystem') 105 handled.append('buildsystem')
106 if 'description' in data: 106 if 'description' in data:
107 lines_before.append('SUMMARY = "%s"' % data['description']) 107 extravalues['SUMMARY'] = data['description']
108 if 'homepage' in data: 108 if 'homepage' in data:
109 lines_before.append('HOMEPAGE = "%s"' % data['homepage']) 109 extravalues['HOMEPAGE'] = data['homepage']
110 110
111 # Shrinkwrap 111 # Shrinkwrap
112 localfilesdir = tempfile.mkdtemp(prefix='recipetool-npm') 112 localfilesdir = tempfile.mkdtemp(prefix='recipetool-npm')