diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
index e65a722..568c5dd 100644
--- a/meta/classes/base.bbclass
+++ b/meta/classes/base.bbclass
@@ -392,6 +392,8 @@ python () {
 
 
         dont_want_license = d.getVar('INCOMPATIBLE_LICENSE', 1)
+        spdx_dont_want_license = d.getVarFlag('SPDXLICENSEMAP', dont_want_license)
+
         if dont_want_license and not pn.endswith("-native") and not pn.endswith("-cross") and not pn.endswith("-cross-initial") and not pn.endswith("-cross-intermediate") and not pn.endswith("-crosssdk-intermediate") and not pn.endswith("-crosssdk") and not pn.endswith("-crosssdk-initial"):
             hosttools_whitelist = (d.getVar('HOSTTOOLS_WHITELIST_%s' % dont_want_license, 1) or "").split()
             lgplv2_whitelist = (d.getVar('LGPLv2_WHITELIST_%s' % dont_want_license, 1) or "").split()
@@ -400,10 +402,22 @@ python () {
 
                 import re
                 this_license = d.getVar('LICENSE', 1)
-                if this_license and re.search(dont_want_license, this_license):
-                    bb.note("SKIPPING %s because it's %s" % (pn, this_license))
-                    raise bb.parse.SkipPackage("incompatible with license %s" % this_license)
-
+                this_license_clean=re.sub(r'[+&()*]', '', this_license)
+                or_licenses = re.split('[|]', this_license_clean)
+
+                for one_or_license in or_licenses:
+		    licenses = re.split('[ ]', one_or_license)
+		    good_license=one_or_license
+		    for onelicense in licenses:
+			spdx_onelicense = d.getVarFlag('SPDXLICENSEMAP', onelicense)
+			if ( onelicense and re.search(dont_want_license, onelicense) ) or ( onelicense and re.search(spdx_dont_want_license, onelicense) ) or ( spdx_onelicense and re.search(dont_want_license, spdx_onelicense) ) or ( spdx_onelicense and re.search(spdx_dont_want_license, spdx_onelicense) ):
+				good_license = ""
+				break
+		    if good_license != "":
+			break
+		if good_license == "":
+		    bb.note("SKIPPING %s because it's %s" % (pn, this_license))
+		    raise bb.parse.SkipPackage("incompatible with license %s" % this_license)
     srcuri = d.getVar('SRC_URI', 1)
     # Svn packages should DEPEND on subversion-native
     if "svn://" in srcuri:
