Index: solr/core/src/java/doc-files/tutorial.html
===================================================================
--- solr/core/src/java/doc-files/tutorial.html	(revision 1309242)
+++ solr/core/src/java/doc-files/tutorial.html	(working copy)
@@ -1,4 +1,20 @@
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <META http-equiv="Content-Type" content="text/html; charset=UTF-8" />
Index: solr/core/src/java/overview.html
===================================================================
--- solr/core/src/java/overview.html	(revision 1309242)
+++ solr/core/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Apache Solr Search Server, new users should familiarize themselves with the <a href="doc-files/tutorial.html">Solr Tutorial</a>.
Index: solr/core/build.xml
===================================================================
--- solr/core/build.xml	(revision 1309242)
+++ solr/core/build.xml	(working copy)
@@ -22,6 +22,9 @@
 
   <property name="ivy.retrieve.pattern" value="${common-solr.dir}/lib/[artifact]-[revision].[ext]"/>
 
+  <!-- html file for testing -->
+  <property name="rat.excludes" value="**/htmlStripReaderTest.html"/>
+
   <import file="../common-build.xml"/>
 
   <target name="compile-core" depends="compile-solrj,common-solr.compile-core"/>
Index: solr/solrj/src/java/overview.html
===================================================================
--- solr/solrj/src/java/overview.html	(revision 1309242)
+++ solr/solrj/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Apache Solr Search Server: Solr-j
Index: solr/build.xml
===================================================================
--- solr/build.xml	(revision 1309242)
+++ solr/build.xml	(working copy)
@@ -195,6 +195,16 @@
       </additional-filters>
     </license-check-macro>
   </target>
+
+  <!-- rat sources -->
+  <target name="rat-sources">
+    <sequential>
+       <ant dir="core" target="rat-sources" inheritall="false"/>
+       <ant dir="solrj" target="rat-sources" inheritall="false"/>
+       <ant dir="test-framework" target="rat-sources" inheritall="false"/>
+      <contrib-crawl target="rat-sources" failonerror="true"/>
+    </sequential>
+  </target>
   
   <!-- Clean targets -->
   <target name="clean" description="Cleans compiled files and other temporary artifacts.">
Index: solr/contrib/clustering/src/java/overview.html
===================================================================
--- solr/contrib/clustering/src/java/overview.html	(revision 1309242)
+++ solr/contrib/clustering/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Apache Solr Search Server: Clustering contrib
Index: solr/contrib/extraction/src/java/overview.html
===================================================================
--- solr/contrib/extraction/src/java/overview.html	(revision 1309242)
+++ solr/contrib/extraction/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Apache Solr Search Server: Solr Cell contrib
Index: solr/contrib/analysis-extras/src/java/overview.html
===================================================================
--- solr/contrib/analysis-extras/src/java/overview.html	(revision 1309242)
+++ solr/contrib/analysis-extras/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Apache Solr Search Server: Analysis Extras contrib
Index: solr/contrib/uima/src/java/overview.html
===================================================================
--- solr/contrib/uima/src/java/overview.html	(revision 1309242)
+++ solr/contrib/uima/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Apache Solr Search Server: Solr UIMA contrib
Index: solr/contrib/velocity/src/java/overview.html
===================================================================
--- solr/contrib/velocity/src/java/overview.html	(revision 1309242)
+++ solr/contrib/velocity/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Apache Solr Search Server: Velocity Response Writer contrib
Index: solr/contrib/langid/src/java/overview.html
===================================================================
--- solr/contrib/langid/src/java/overview.html	(revision 1309242)
+++ solr/contrib/langid/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Apache Solr Search Server: Solr Language Identifier contrib
Index: solr/contrib/dataimporthandler/src/java/overview.html
===================================================================
--- solr/contrib/dataimporthandler/src/java/overview.html	(revision 1309242)
+++ solr/contrib/dataimporthandler/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Apache Solr Search Server: DataImportHandler contrib
Index: solr/contrib/dataimporthandler-extras/src/java/overview.html
===================================================================
--- solr/contrib/dataimporthandler-extras/src/java/overview.html	(revision 1309242)
+++ solr/contrib/dataimporthandler-extras/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Apache Solr Search Server: DataImportHandler Extras contrib
Index: solr/test-framework/src/java/overview.html
===================================================================
--- solr/test-framework/src/java/overview.html	(revision 1309242)
+++ solr/test-framework/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Apache Solr Search Server: Test Framework
Index: build.xml
===================================================================
--- build.xml	(revision 1309242)
+++ build.xml	(working copy)
@@ -46,6 +46,14 @@
       </subant></sequential>
   </target>
 
+  <target name="rat-sources" description="Runs rat across all sources and tests">
+    <sequential><subant target="rat-sources" inheritall="false" failonerror="true">
+        <fileset dir="lucene" includes="build.xml" />
+        <fileset dir="modules" includes="build.xml" />
+        <fileset dir="solr" includes="build.xml" />
+    </subant></sequential>
+  </target>
+
   <target name="resolve" description="Resolves all dependencies">
     <sequential><subant target="resolve" inheritall="false" failonerror="true">
         <fileset dir="lucene" includes="build.xml" />
Index: modules/suggest/build.xml
===================================================================
--- modules/suggest/build.xml	(revision 1309242)
+++ modules/suggest/build.xml	(working copy)
@@ -27,5 +27,7 @@
   <property name="dist.dir" location="dist/" />
   <property name="maven.dist.dir" location="../dist/maven" />
 
+  <!-- just a list of words for testing suggesters -->
+  <property name="rat.excludes" value="**/Top50KWiki.utf8"/>
   <import file="../../lucene/contrib/contrib-build.xml"/>
 </project>
Index: modules/facet/src/java/org/apache/lucene/facet/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
   <head>
     <title>Faceted Indexing and Search</title>
Index: modules/facet/src/java/org/apache/lucene/facet/search/aggregator/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/search/aggregator/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/search/aggregator/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
   <head>
     <title>Aggregating Facets during Faceted Search</title>
Index: modules/facet/src/java/org/apache/lucene/facet/search/results/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/search/results/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/search/results/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
   <head>
     <title>Results of Faceted Search</title>
Index: modules/facet/src/java/org/apache/lucene/facet/search/sampling/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/search/sampling/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/search/sampling/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
   <head>
     <title>Sampling for facets accumulation</title>
Index: modules/facet/src/java/org/apache/lucene/facet/search/params/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/search/params/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/search/params/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
   <head>
     <title>Parameters for Faceted Search</title>
Index: modules/facet/src/java/org/apache/lucene/facet/search/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/search/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/search/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
   <head>
     <title>Faceted Search API</title>
Index: modules/facet/src/java/org/apache/lucene/facet/index/params/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/index/params/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/index/params/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Indexing-time specifications for handling facets</title>
Index: modules/facet/src/java/org/apache/lucene/facet/index/attributes/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/index/attributes/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/index/attributes/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Category attributes and their properties for indexing</title>
Index: modules/facet/src/java/org/apache/lucene/facet/index/streaming/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/index/streaming/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/index/streaming/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Expert: attributes streaming definition for indexing facets</title>
Index: modules/facet/src/java/org/apache/lucene/facet/index/categorypolicy/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/index/categorypolicy/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/index/categorypolicy/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Policies for indexing categories</title>
Index: modules/facet/src/java/org/apache/lucene/facet/index/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/index/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/index/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Indexing of document categories</title>
Index: modules/facet/src/java/org/apache/lucene/facet/enhancements/params/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/enhancements/params/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/enhancements/params/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Enhanced category features</title>
Index: modules/facet/src/java/org/apache/lucene/facet/enhancements/association/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/enhancements/association/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/enhancements/association/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Association category enhancements</title>
Index: modules/facet/src/java/org/apache/lucene/facet/enhancements/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/enhancements/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/enhancements/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Enhanced category features</title>
Index: modules/facet/src/java/org/apache/lucene/facet/util/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/util/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/util/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
   <head>
     <title>Various utilities for faceted search</title>
Index: modules/facet/src/java/org/apache/lucene/facet/taxonomy/writercache/cl2o/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/taxonomy/writercache/cl2o/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/taxonomy/writercache/cl2o/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Category->Ordinal caching implementation using an optimized data-structures</title>
Index: modules/facet/src/java/org/apache/lucene/facet/taxonomy/writercache/lru/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/taxonomy/writercache/lru/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/taxonomy/writercache/lru/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>An LRU cache implementation for the CategoryPath to Ordinal map</title>
Index: modules/facet/src/java/org/apache/lucene/facet/taxonomy/writercache/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/taxonomy/writercache/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/taxonomy/writercache/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Improves indexing time by caching a map of CategoryPath to their Ordinal</title>
Index: modules/facet/src/java/org/apache/lucene/facet/taxonomy/directory/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/taxonomy/directory/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/taxonomy/directory/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Taxonomy implemented using a Lucene-Index</title>
Index: modules/facet/src/java/org/apache/lucene/facet/taxonomy/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/facet/taxonomy/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/facet/taxonomy/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Taxonomy of Categories</title>
Index: modules/facet/src/java/org/apache/lucene/util/encoding/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/util/encoding/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/util/encoding/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Encoding</title>
Index: modules/facet/src/java/org/apache/lucene/util/collections/package.html
===================================================================
--- modules/facet/src/java/org/apache/lucene/util/collections/package.html	(revision 1309242)
+++ modules/facet/src/java/org/apache/lucene/util/collections/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
 <title>Collections</title>
Index: modules/facet/build.xml
===================================================================
--- modules/facet/build.xml	(revision 1309242)
+++ modules/facet/build.xml	(working copy)
@@ -26,6 +26,9 @@
   <property name="build.dir" location="build/" />
   <property name="dist.dir" location="dist/" />
   <property name="maven.dist.dir" location="../dist/maven" />
+
+  <!-- prettify.css/js -->
+  <property name="rat.excludes" value="**/prettify.css,**/prettify.js"/>
   
   <import file="../../lucene/contrib/contrib-build.xml"/>
 
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/flexible/messages/MessagesTestBundle_ja.properties
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/flexible/messages/MessagesTestBundle_ja.properties	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/flexible/messages/MessagesTestBundle_ja.properties	(working copy)
@@ -1,3 +1,17 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
 Q0001E_INVALID_SYNTAX = \u69cb\u6587\u30a8\u30e9\u30fc: {0}
 
 Q0004E_INVALID_SYNTAX_ESCAPE_UNICODE_TRUNCATION = \u5207\u308a\u6368\u3066\u3089\u308c\u305f\u30e6\u30cb\u30b3\u30fc\u30c9\u30fb\u30a8\u30b9\u30b1\u30fc\u30d7\u30fb\u30b7\u30fc\u30b1\u30f3\u30b9\u3002
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/flexible/messages/MessagesTestBundle.properties
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/flexible/messages/MessagesTestBundle.properties	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/flexible/messages/MessagesTestBundle.properties	(working copy)
@@ -1,3 +1,17 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
 Q0001E_INVALID_SYNTAX = Syntax Error: {0}
 
 Q0004E_INVALID_SYNTAX_ESCAPE_UNICODE_TRUNCATION = Truncated unicode escape sequence.
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/TermsQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/TermsQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/TermsQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 		<!-- TermsQuery uses an analyzer to tokenize text and creates a BooleanQuery with nested
 			"should" TermQueries for each of the tokens encountered. This can be used for user input
 			which may include content or characters that would otherwise be illegal query syntax when
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/UserInputQueryCustomField.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/UserInputQueryCustomField.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/UserInputQueryCustomField.xml	(working copy)
@@ -1,2 +1,18 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <UserQuery fieldName="doesNotExist" boost="10">Bank^2</UserQuery>
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/MatchAllDocsQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/MatchAllDocsQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/MatchAllDocsQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <FilteredQuery>
 	<Query>
 		<MatchAllDocsQuery/>
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/TermsFilterQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/TermsFilterQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/TermsFilterQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <FilteredQuery>
 	<Query>
 		<BooleanQuery fieldName="contents">
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/albumLuceneClassicQuery.xsl
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/albumLuceneClassicQuery.xsl	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/albumLuceneClassicQuery.xsl	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
 <xsl:template match="/Document">
 <!-- This template is designed to work with a google-like search form - one edit box and 
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/NumericRangeQueryQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/NumericRangeQueryQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/NumericRangeQueryQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <BooleanQuery fieldName="contents">
 	<Clause occurs="should">
 		<TermQuery>merger</TermQuery>
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/albumBooleanQuery.xsl
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/albumBooleanQuery.xsl	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/albumBooleanQuery.xsl	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
 <xsl:template match="/Document">
 <!--This template ANDs all fields together. Within a single field all terms are ORed.
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/LikeThisQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/LikeThisQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/LikeThisQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <LikeThisQuery percentTermsToMatch="5" stopWords="Reuter" minDocFreq="2">
 IRAQI TROOPS REPORTED PUSHING BACK IRANIANS Iraq said today its troops were pushing Iranian forces out of 
 	positions they had initially occupied when they launched a new offensive near the southern port of 
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/BooleanQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/BooleanQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/BooleanQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <BooleanQuery fieldName="contents">
 	<Clause occurs="should">
 		<TermQuery>merger</TermQuery>
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/DuplicateFilterQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/DuplicateFilterQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/DuplicateFilterQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <FilteredQuery>
 	<Query>
 		<BooleanQuery fieldName="contents">
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/BoostingQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/BoostingQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/BoostingQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <BoostingQuery>
 	<!-- Find docs about banks, preferably merger info and preferably not "World bank" -->
 	<Query>
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/FuzzyLikeThisQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/FuzzyLikeThisQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/FuzzyLikeThisQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <FuzzyLikeThisQuery>
 	<!-- Matches on misspelt "Sumitomo" bank -->
 	<Field fieldName="contents">
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/NumericRangeFilterQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/NumericRangeFilterQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/NumericRangeFilterQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <FilteredQuery>
 	<Query>
 		<BooleanQuery fieldName="contents">
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/ConstantScoreQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/ConstantScoreQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/ConstantScoreQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <ConstantScoreQuery>
 	<RangeFilter fieldName="date" lowerTerm="19870409" upperTerm="19870412"/>
 </ConstantScoreQuery>
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/UserInputQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/UserInputQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/UserInputQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <FilteredQuery>
 	<Query>
 		<UserQuery>"Bank of England"</UserQuery>
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/BooleanFilter.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/BooleanFilter.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/BooleanFilter.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <FilteredQuery>
 	<Query>
 		<MatchAllDocsQuery/>
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/SpanQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/SpanQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/SpanQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <SpanOr fieldName="contents">
 	<SpanNear slop="8" inOrder="false" >		
 			<SpanOr>
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/RangeFilterQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/RangeFilterQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/RangeFilterQuery.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <FilteredQuery>
 	<Query>
 		<BooleanQuery fieldName="contents">
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/TermQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/TermQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/TermQuery.xml	(working copy)
@@ -1,2 +1,18 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <TermQuery fieldName="contents">sumitomo</TermQuery>
\ No newline at end of file
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/BoostingTermQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/BoostingTermQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/BoostingTermQuery.xml	(working copy)
@@ -1,2 +1,18 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <BoostingTermQuery fieldName="contents">sumitomo</BoostingTermQuery>
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/NestedBooleanQuery.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/NestedBooleanQuery.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/NestedBooleanQuery.xml	(working copy)
@@ -1,5 +1,21 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<!--
 	This query was added to demonstrate nested boolean queries - there
 	was a bug in the XML parser which added ALL child <Clause> tags to 
 	the top level tags ie. took child and grandchild elements instead
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/albumFilteredQuery.xsl
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/albumFilteredQuery.xsl	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/albumFilteredQuery.xsl	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
 <xsl:template match="/Document">
 <!-- This template uses an efficient, cached filter for the "genre" field".
Index: modules/queryparser/src/test/org/apache/lucene/queryparser/xml/CachedFilter.xml
===================================================================
--- modules/queryparser/src/test/org/apache/lucene/queryparser/xml/CachedFilter.xml	(revision 1309242)
+++ modules/queryparser/src/test/org/apache/lucene/queryparser/xml/CachedFilter.xml	(working copy)
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <FilteredQuery>
 	<Query>
 		<BooleanQuery fieldName="contents">
Index: modules/analysis/common/build.xml
===================================================================
--- modules/analysis/common/build.xml	(revision 1309242)
+++ modules/analysis/common/build.xml	(working copy)
@@ -26,6 +26,9 @@
   <property name="build.dir" location="../build/common" />
   <property name="dist.dir" location="../dist/common" />
 
+  <!-- some files for testing that do not have license headers -->
+  <property name="rat.excludes" value="**/*.aff,**/*.dic,**/*.txt,**/charfilter/*.htm*,**/*LuceneResourcesWikiPage.html"/>
+
   <import file="../../../lucene/contrib/contrib-build.xml"/>
 	
   <target name="compile-core" depends="jflex-notice, common.compile-core"/>
Index: modules/analysis/build.xml
===================================================================
--- modules/analysis/build.xml	(revision 1309242)
+++ modules/analysis/build.xml	(working copy)
@@ -116,5 +116,9 @@
   <target name="javadocs-index.html">
     <forall-analyzers target="javadocs-index.html"/>
   </target>
+
+  <target name="rat-sources">
+    <forall-analyzers target="rat-sources"/>
+  </target>
 	
 </project>
Index: modules/analysis/stempel/src/java/overview.html
===================================================================
--- modules/analysis/stempel/src/java/overview.html	(revision 1309242)
+++ modules/analysis/stempel/src/java/overview.html	(working copy)
@@ -1,4 +1,20 @@
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <head>
   <meta content="text/html; charset=UTF-8" http-equiv="content-type">
Index: modules/grouping/src/java/org/apache/lucene/search/grouping/package.html
===================================================================
--- modules/grouping/src/java/org/apache/lucene/search/grouping/package.html	(revision 1309242)
+++ modules/grouping/src/java/org/apache/lucene/search/grouping/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 
Index: modules/grouping/src/java/overview.html
===================================================================
--- modules/grouping/src/java/overview.html	(revision 1309242)
+++ modules/grouping/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Lucene's grouping module
Index: modules/build.xml
===================================================================
--- modules/build.xml	(revision 1309242)
+++ modules/build.xml	(working copy)
@@ -68,6 +68,10 @@
     <license-check-macro dir="${basedir}" />
   </target>
 
+  <target name="rat-sources">
+    <forall-modules target="rat-sources"/>
+  </target>
+
   <target name="clean" description="Clean all modules">
     <delete dir="dist"/>
     <forall-modules target="clean" />
Index: modules/join/src/java/org/apache/lucene/search/join/package.html
===================================================================
--- modules/join/src/java/org/apache/lucene/search/join/package.html	(revision 1309242)
+++ modules/join/src/java/org/apache/lucene/search/join/package.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 
Index: modules/join/src/java/overview.html
===================================================================
--- modules/join/src/java/overview.html	(revision 1309242)
+++ modules/join/src/java/overview.html	(working copy)
@@ -1,3 +1,19 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements.  See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
 <html>
 <body>
 Lucene's join module
Index: lucene/common-build.xml
===================================================================
--- lucene/common-build.xml	(revision 1309242)
+++ lucene/common-build.xml	(working copy)
@@ -201,6 +201,9 @@
   <property name="clover.db.dir" location="${common.dir}/build/test/clover/db"/>
   <property name="clover.report.dir" location="${common.dir}/build/test/clover/reports"/>
 
+  <!-- a reasonable default exclusion set, can be overridden for special cases -->
+  <property name="rat.excludes" value="**/TODO,**/*.txt"/>
+
   <available
             property="clover.present"
             classname="com.cenqua.clover.tasks.CloverReportTask"
@@ -907,14 +910,73 @@
 
   <target name="rat-sources" depends="rat-sources-typedef"
 	  description="runs the tasks over source and test files">
-    <rat:report xmlns:rat="antlib:org.apache.rat.anttasks">
-      <fileset dir="${src.dir}"/>
-      <fileset dir="${tests-framework.src.dir}"/>
-      <fileset dir="${tests.src.dir}" erroronmissingdir="false"/>
+    <sequential>
+    <!-- create a temp file for the log to go to -->
+    <tempfile property="rat.sources.logfile"
+              prefix="rat"
+              destdir="${java.io.tmpdir}"/>
+    <!-- run rat, going to the file -->
+    <rat:report xmlns:rat="antlib:org.apache.rat.anttasks" 
+                reportFile="${rat.sources.logfile}">
+      <fileset dir="${src.dir}" excludes="${rat.excludes}"/>
+      <fileset dir="${tests.src.dir}" excludes="${rat.excludes}" erroronmissingdir="false"/>
       <!-- some modules have a src/tools/[java,test] -->
-      <fileset dir="src/tools/java" erroronmissingdir="false"/>
-      <fileset dir="src/tools/test" erroronmissingdir="false"/>
+      <fileset dir="src/tools/java" excludes="${rat.excludes}" erroronmissingdir="false"/>
+      <fileset dir="src/tools/test" excludes="${rat.excludes}" erroronmissingdir="false"/>
+      
+      <!-- bsd-like stuff -->
+      <rat:substringMatcher licenseFamilyCategory="BSD  "
+             licenseFamilyName="Modified BSD License">
+      <!-- brics automaton -->
+        <pattern substring="Copyright (c) 2001-2009 Anders Moeller"/>
+      <!-- snowball -->
+        <pattern substring="Copyright (c) 2001, Dr Martin Porter"/>
+      <!-- UMASS kstem -->
+        <pattern substring="THIS SOFTWARE IS PROVIDED BY UNIVERSITY OF MASSACHUSETTS AND OTHER CONTRIBUTORS"/>
+      <!-- Egothor -->
+        <pattern substring="Egothor Software License version 1.00"/>
+      <!-- JaSpell -->
+        <pattern substring="Copyright (c) 2005 Bruno Martins"/>
+      </rat:substringMatcher>
+
+      <!-- mit-like -->
+      <rat:substringMatcher licenseFamilyCategory="MIT  "
+             licenseFamilyName="The MIT License">
+      <!-- ICU license -->
+        <pattern substring="Permission is hereby granted, free of charge, to any person obtaining a copy"/>
+      </rat:substringMatcher>
+
+      <rat:substringMatcher licenseFamilyCategory="GEN  "
+             licenseFamilyName="Generated">
+      <!-- svg files generated by gnuplot -->
+        <pattern substring="Produced by GNUPLOT"/>
+      <!-- snowball stemmers generated by snowball compiler -->
+        <pattern substring="This file was generated automatically by the Snowball to Java compiler"/>
+      <!-- uima tests generated by JCasGen -->
+        <pattern substring="First created by JCasGen"/>
+      </rat:substringMatcher>
+
+      <!-- built in approved licenses -->
+      <rat:approvedLicense familyName="Apache License Version 2.0"/>
+      <rat:approvedLicense familyName="The MIT License"/>
+      <rat:approvedLicense familyName="Modified BSD License"/>
+      <rat:approvedLicense familyName="Generated"/>
     </rat:report>
+    <!-- now print the output, for review -->
+    <loadfile property="rat.output" srcFile="${rat.sources.logfile}"/>
+    <echo>${rat.output}</echo>
+    <delete>
+      <fileset file="${rat.sources.logfile}">
+        <containsregexp expression="^0 Unknown Licenses"/>
+      </fileset>
+    </delete>
+    <!-- fail if we didnt find the pattern -->
+    <fail message="Rat problems were found!">
+      <condition>
+        <available file="${rat.sources.logfile}"/>
+      </condition>
+    </fail>
+    </sequential>
   </target>
 
   <!--+
Index: lucene/build.xml
===================================================================
--- lucene/build.xml	(revision 1309242)
+++ lucene/build.xml	(working copy)
@@ -301,6 +301,14 @@
   	</sequential>
   </target>
 
+  <target name="rat-sources">
+    <sequential>
+       <ant dir="core" target="rat-sources" inheritall="false"/>
+       <ant dir="test-framework" target="rat-sources" inheritall="false"/>
+       <ant dir="tools" target="rat-sources" inheritall="false"/>
+       <contrib-crawl target="rat-sources" failonerror="true"/>
+    </sequential>
+  </target>
 
   <!-- ================================================================== -->
   <!-- D I S T R I B U T I O N                                            -->
Index: lucene/tools/src/java/lucene-solr.antlib.xml
===================================================================
--- lucene/tools/src/java/lucene-solr.antlib.xml	(revision 1309242)
+++ lucene/tools/src/java/lucene-solr.antlib.xml	(working copy)
@@ -1,3 +1,19 @@
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+ -->
 <antlib>
     <taskdef 
         name="licenses" 
@@ -2,2 +18,2 @@
         classname="org.apache.lucene.validation.LicenseCheckTask" />
-</antlib> 
\ No newline at end of file
+</antlib> 
Index: lucene/tools/src/java/org/apache/lucene/validation/LicenseCheckTask.java
===================================================================
--- lucene/tools/src/java/org/apache/lucene/validation/LicenseCheckTask.java	(revision 1309242)
+++ lucene/tools/src/java/org/apache/lucene/validation/LicenseCheckTask.java	(working copy)
@@ -1,5 +1,22 @@
 package org.apache.lucene.validation;
 
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
 import java.io.File;
 import java.util.ArrayList;
 import java.util.Iterator;
