[prev in list] [next in list] [prev in thread] [next in thread]
List: openembedded-core
Subject: [OE-core] [PATCH 46/50] Fixing my bad license parsing: license.bbclass
From: koen () dominion ! thruhere ! net (Koen Kooi)
Date: 2011-02-27 9:30:00
Message-ID: 438b29bb8458d657556e6e685b5908c18e884106.1298798633.git.koen () dominion ! thruhere ! net
[Download RAW message or body]
From: Beth Flanagan <elizabeth.flanagan at intel.com>
Fix to my bad license parsing. Also added the MIT generic license
files.
Signed-off-by: Beth Flanagan <elizabeth.flanagan at intel.com>
---
meta/classes/license.bbclass | 7 ++++---
meta/files/common-licenses/MIT | 6 ++++++
meta/files/common-licenses/MIT-style | 1 +
3 files changed, 11 insertions(+), 3 deletions(-)
create mode 100644 meta/files/common-licenses/MIT
create mode 120000 meta/files/common-licenses/MIT-style
diff --git a/meta/classes/license.bbclass b/meta/classes/license.bbclass
index 4e3cd1c..9c4ccb3 100644
--- a/meta/classes/license.bbclass
+++ b/meta/classes/license.bbclass
@@ -66,9 +66,10 @@ python do_populate_lic() {
# I'm sure someone has written a logic parser for these fields, but if so, I \
don't know where it is.
# So what I do is just link to every license mentioned in the license field.
- for license_type in (' '.join(license_types.replace('&', ' ').replace('+', ' \
').replace('|', ' ')
- .replace('(', ' ').replace(')', ' ').replace(';', ' \
').replace(',', ' ').split())):
- if os.path.isfile(os.path.join(generic_directory, license_type)):
+ for license_type in ((license_types.replace('+', '').replace('|', '&')
+ .replace('(', '').replace(')', '').replace(';', '')
+ .replace(',', '').replace(" ", "").split("&"))):
+if os.path.isfile(os.path.join(generic_directory, license_type)):
gen_lic_dest = os.path.join(bb.data.getVar('LICENSE_DIRECTORY', d, \
True), "common-licenses") try:
bb.mkdirhier(gen_lic_dest)
diff --git a/meta/files/common-licenses/MIT b/meta/files/common-licenses/MIT
new file mode 100644
index 0000000..d136d5e
--- /dev/null
+++ b/meta/files/common-licenses/MIT
@@ -0,0 +1,6 @@
+The MIT License
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of this \
software and associated documentation files (the ???Software???), to deal in the \
Software without restriction, including without limitation the rights to use, copy, \
modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, \
and to permit persons to whom the Software is furnished to do so, subject to the \
following conditions: +
+The above copyright notice and this permission notice shall be included in all \
copies or substantial portions of the Software. +THE SOFTWARE IS PROVIDED ???AS \
IS???, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO \
THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND \
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY \
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR \
OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR \
OTHER DEALINGS IN THE SOFTWARE.
diff --git a/meta/files/common-licenses/MIT-style \
b/meta/files/common-licenses/MIT-style new file mode 120000
index 0000000..8ab70c0
--- /dev/null
+++ b/meta/files/common-licenses/MIT-style
@@ -0,0 +1 @@
+MIT
\ No newline at end of file
--
1.6.6.1
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic