From 1ce3419fc830bf67f5dc6bff981e8c8ae10f30a9 Mon Sep 17 00:00:00 2001
From: Pawel Hajdan, Jr <phajdan.jr@chromium.org>
Date: Thu, 3 Nov 2011 16:34:30 +0100
Subject: [PATCH] Recognize more variations of MIT/X11 license.
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

This is a part of an effort to make Chromium project sources
pass licensecheck: http://code.google.com/p/chromium/issues/detail?id=28291

Signed-off-by: Paweł Hajdan, Jr <phajdan.jr@chromium.org>
---
 scripts/licensecheck.pl |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/scripts/licensecheck.pl b/scripts/licensecheck.pl
index 461de28..4266296 100755
--- a/scripts/licensecheck.pl
+++ b/scripts/licensecheck.pl
@@ -437,9 +437,9 @@ sub parselicense($) {
 	$license = "QPL $license";
     }
 
-    if ($licensetext =~ /http:\/\/opensource\.org\/licenses\/mit-license\.php/) {
+    if ($licensetext =~ /opensource\.org\/licenses\/mit-license\.php/) {
 	$license = "MIT/X11 (BSD like) $license";
-    } elsif ($licensetext =~ /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/) {
+    } elsif ($licensetext =~ /Permission is hereby granted, free of charge, to any person obtaining a copy of this software and(\/or)? associated documentation files \(the (Software|Materials)\), to deal in the (Software|Materials)/) {
 	$license = "MIT/X11 (BSD like) $license";
     } elsif ($licensetext =~ /Permission is hereby granted, without written agreement and without license or royalty fees, to use, copy, modify, and distribute this software and its documentation for any purpose/) {
 	$license = "MIT/X11 (BSD like) $license";
-- 
1.7.4.4

