You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by us...@apache.org on 2013/06/15 12:03:34 UTC
svn commit: r1493334 - in /lucene/dev/branches/branch_4x: ./ lucene/
lucene/analysis/ lucene/analysis/common/ lucene/analysis/icu/
lucene/analysis/kuromoji/ lucene/demo/ lucene/join/ lucene/spatial/
lucene/tools/
Author: uschindler
Date: Sat Jun 15 10:03:34 2013
New Revision: 1493334
URL: http://svn.apache.org/r1493334
Log:
Merged revision(s) 1493333 from lucene/dev/trunk:
LUCENE-5055: "rat-sources" target now checks also build.xml, ivy.xml, forbidden-api signatures, and parts of resources folders
Modified:
lucene/dev/branches/branch_4x/ (props changed)
lucene/dev/branches/branch_4x/build.xml
lucene/dev/branches/branch_4x/lucene/ (props changed)
lucene/dev/branches/branch_4x/lucene/CHANGES.txt
lucene/dev/branches/branch_4x/lucene/analysis/ (props changed)
lucene/dev/branches/branch_4x/lucene/analysis/common/build.xml
lucene/dev/branches/branch_4x/lucene/analysis/icu/build.xml
lucene/dev/branches/branch_4x/lucene/analysis/kuromoji/build.xml
lucene/dev/branches/branch_4x/lucene/common-build.xml (contents, props changed)
lucene/dev/branches/branch_4x/lucene/demo/ (props changed)
lucene/dev/branches/branch_4x/lucene/demo/build.xml
lucene/dev/branches/branch_4x/lucene/join/ (props changed)
lucene/dev/branches/branch_4x/lucene/join/build.xml
lucene/dev/branches/branch_4x/lucene/spatial/ (props changed)
lucene/dev/branches/branch_4x/lucene/spatial/build.xml
lucene/dev/branches/branch_4x/lucene/tools/ (props changed)
lucene/dev/branches/branch_4x/lucene/tools/build.xml
lucene/dev/branches/branch_4x/lucene/tools/custom-tasks.xml
Modified: lucene/dev/branches/branch_4x/build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/build.xml?rev=1493334&r1=1493333&r2=1493334&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/build.xml (original)
+++ lucene/dev/branches/branch_4x/build.xml Sat Jun 15 10:03:34 2013
@@ -90,6 +90,7 @@
<target name="rat-sources" description="Runs rat across all sources and tests">
<subant target="rat-sources" inheritall="false" failonerror="true">
+ <fileset dir="." includes="extra-targets.xml" /><!-- run rat-sources also for root directory -->
<fileset dir="lucene" includes="build.xml" />
<fileset dir="solr" includes="build.xml" />
</subant>
Modified: lucene/dev/branches/branch_4x/lucene/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/CHANGES.txt?rev=1493334&r1=1493333&r2=1493334&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/CHANGES.txt (original)
+++ lucene/dev/branches/branch_4x/lucene/CHANGES.txt Sat Jun 15 10:03:34 2013
@@ -198,6 +198,10 @@ Build
project name. This also enforces UTF-8 encoding when files are copied with
filtering.
+* LUCENE-5055: "rat-sources" target now checks also build.xml, ivy.xml,
+ forbidden-api signatures, and parts of resources folders. (Ryan Ernst,
+ Uwe Schindler)
+
Tests
* LUCENE-4901: TestIndexWriterOnJRECrash should work on any
Modified: lucene/dev/branches/branch_4x/lucene/analysis/common/build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/analysis/common/build.xml?rev=1493334&r1=1493333&r2=1493334&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/analysis/common/build.xml (original)
+++ lucene/dev/branches/branch_4x/lucene/analysis/common/build.xml Sat Jun 15 10:03:34 2013
@@ -25,6 +25,7 @@
<!-- some files for testing that do not have license headers -->
<property name="rat.excludes" value="**/*.aff,**/*.dic,**/*.txt,**/charfilter/*.htm*,**/*LuceneResourcesWikiPage.html"/>
+ <property name="rat.additional-includes" value="src/tools/**"/>
<import file="../analysis-module-build.xml"/>
Modified: lucene/dev/branches/branch_4x/lucene/analysis/icu/build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/analysis/icu/build.xml?rev=1493334&r1=1493333&r2=1493334&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/analysis/icu/build.xml (original)
+++ lucene/dev/branches/branch_4x/lucene/analysis/icu/build.xml Sat Jun 15 10:03:34 2013
@@ -23,6 +23,8 @@
Analysis integration with ICU (International Components for Unicode).
</description>
+ <property name="rat.additional-includes" value="src/tools/**"/>
+
<import file="../analysis-module-build.xml"/>
<path id="icujar">
@@ -59,7 +61,7 @@
<property name="gennorm2.src.files"
value="nfc.txt nfkc.txt nfkc_cf.txt BasicFoldings.txt DiacriticFolding.txt DingbatFolding.txt HanRadicalFolding.txt NativeDigitFolding.txt"/>
<property name="gennorm2.tmp" value="${build.dir}/gennorm2/utr30.tmp"/>
- <property name="gennorm2.dst" value="src/resources/org/apache/lucene/analysis/icu/utr30.nrm"/>
+ <property name="gennorm2.dst" value="${resources.dir}/org/apache/lucene/analysis/icu/utr30.nrm"/>
<target name="gennorm2" depends="gen-utr30-data-files">
<echo>Note that the gennorm2 and icupkg tools must be on your PATH. These tools
are part of the ICU4C package. See http://site.icu-project.org/ </echo>
@@ -82,7 +84,7 @@ are part of the ICU4C package. See http:
</target>
<property name="rbbi.src.dir" location="src/data/uax29"/>
- <property name="rbbi.dst.dir" location="src/resources/org/apache/lucene/analysis/icu/segmentation"/>
+ <property name="rbbi.dst.dir" location="${resources.dir}/org/apache/lucene/analysis/icu/segmentation"/>
<target name="genrbbi" depends="compile-tools">
<mkdir dir="${rbbi.dst.dir}"/>
Modified: lucene/dev/branches/branch_4x/lucene/analysis/kuromoji/build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/analysis/kuromoji/build.xml?rev=1493334&r1=1493333&r2=1493334&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/analysis/kuromoji/build.xml (original)
+++ lucene/dev/branches/branch_4x/lucene/analysis/kuromoji/build.xml Sat Jun 15 10:03:34 2013
@@ -26,6 +26,7 @@
<!-- currently whether rat detects this as binary or not
is platform dependent?! -->
<property name="rat.excludes" value="**/*.txt,**/bocchan.utf-8"/>
+ <property name="rat.additional-includes" value="src/tools/**"/>
<!-- we don't want to pull in ipadic/naist etc -->
<property name="ivy.default.configuration" value="default"/>
@@ -45,7 +46,7 @@
<property name="dict.encoding" value="euc-jp"/>
<property name="dict.format" value="ipadic"/>
<property name="dict.normalize" value="false"/>
- <property name="dict.target.dir" location="./src/resources"/>
+ <property name="dict.target.dir" location="${resources.dir}"/>
<available type="dir" file="${build.dir}/${ipadic.version}" property="dict.available"/>
@@ -83,7 +84,7 @@
<target name="build-dict" depends="compile-tools, download-dict">
<sequential>
<delete verbose="true">
- <fileset dir="src/resources/org/apache/lucene/analysis/ja/dict" includes="**/*"/>
+ <fileset dir="${resources.dir}/org/apache/lucene/analysis/ja/dict" includes="**/*"/>
</delete>
<!-- TODO: optimize the dictionary construction a bit so that you don't need 1G -->
<java fork="true" failonerror="true" maxmemory="1g" classname="org.apache.lucene.analysis.ja.util.DictionaryBuilder">
Modified: lucene/dev/branches/branch_4x/lucene/common-build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/common-build.xml?rev=1493334&r1=1493333&r2=1493334&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/common-build.xml (original)
+++ lucene/dev/branches/branch_4x/lucene/common-build.xml Sat Jun 15 10:03:34 2013
@@ -186,6 +186,7 @@
<property name="build.encoding" value="utf-8"/>
<property name="src.dir" location="src/java"/>
+ <property name="resources.dir" location="${src.dir}/../resources"/>
<property name="tests.src.dir" location="src/test"/>
<available property="module.has.tests" type="dir" file="${tests.src.dir}"/>
<property name="build.dir" location="build"/>
@@ -255,6 +256,8 @@
<!-- a reasonable default exclusion set, can be overridden for special cases -->
<property name="rat.excludes" value="**/TODO,**/*.txt,**/*.iml"/>
+ <!-- This pattern can be defined to add additional files for checks, relative to module's home dir -->
+ <property name="rat.additional-includes" value=""/>
<propertyset id="uptodate.and.compiled.properties" dynamic="true">
<propertyref regex=".*\.uptodate$$"/>
@@ -492,7 +495,7 @@
<!-- Copy the resources folder (if existent) -->
<copy todir="${build.dir}/classes/java">
- <fileset dir="${src.dir}/../resources" erroronmissingdir="no"/>
+ <fileset dir="${resources.dir}" erroronmissingdir="no"/>
</copy>
</target>
@@ -1342,7 +1345,7 @@ ${tests-output}/junit4-*.suites - pe
<sequential>
<mkdir dir="${build.dir}" />
<jarify basedir="${src.dir}" destfile="${build.dir}/${final.name}-src.jar">
- <fileset dir="${src.dir}/../resources" erroronmissingdir="no"/>
+ <fileset dir="${resources.dir}" erroronmissingdir="no"/>
</jarify>
</sequential>
</target>
@@ -1518,7 +1521,6 @@ ${tests-output}/junit4-*.suites - pe
<target name="rat-sources" depends="rat-sources-typedef"
description="runs the tasks over source and test files">
- <sequential>
<!-- create a temp file for the log to go to -->
<tempfile property="rat.sources.logfile"
prefix="rat"
@@ -1526,11 +1528,12 @@ ${tests-output}/junit4-*.suites - pe
<!-- 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="." includes="*.xml ${rat.additional-includes}"/>
+ <fileset dir="${src.dir}" excludes="${rat.excludes}" erroronmissingdir="false"/>
<fileset dir="${tests.src.dir}" excludes="${rat.excludes}" erroronmissingdir="false"/>
- <!-- some modules have a src/tools/[java,test] -->
- <fileset dir="src/tools/java" excludes="${rat.excludes}" erroronmissingdir="false"/>
- <fileset dir="src/tools/test" excludes="${rat.excludes}" erroronmissingdir="false"/>
+
+ <!-- TODO: Check all resource files. Currently not all stopword and similar files have no header! -->
+ <fileset dir="${resources.dir}" includes="META-INF/**" erroronmissingdir="false"/>
<!-- bsd-like stuff -->
<rat:substringMatcher licenseFamilyCategory="BSD "
@@ -1597,7 +1600,6 @@ ${tests-output}/junit4-*.suites - pe
<available file="${rat.sources.logfile}"/>
</condition>
</fail>
- </sequential>
</target>
<!--+
Modified: lucene/dev/branches/branch_4x/lucene/demo/build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/demo/build.xml?rev=1493334&r1=1493333&r2=1493334&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/demo/build.xml (original)
+++ lucene/dev/branches/branch_4x/lucene/demo/build.xml Sat Jun 15 10:03:34 2013
@@ -58,7 +58,7 @@
<echo>Compiling XML QueryParser Demo WAR</echo>
<war destfile="${build.dir}/lucene-xml-query-demo.war" webxml="src/resources/org/apache/lucene/demo/xmlparser/WEB-INF/web.xml">
- <fileset dir="src/resources/org/apache/lucene/demo/xmlparser/"/>
+ <fileset dir="${resources.dir}/org/apache/lucene/demo/xmlparser/"/>
<lib dir="${build.dir}">
<include name="${final.name}.jar"/>
</lib>
Modified: lucene/dev/branches/branch_4x/lucene/join/build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/join/build.xml?rev=1493334&r1=1493333&r2=1493334&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/join/build.xml (original)
+++ lucene/dev/branches/branch_4x/lucene/join/build.xml Sat Jun 15 10:03:34 2013
@@ -1,4 +1,22 @@
<?xml version="1.0"?>
+<!--
+ 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.
+-->
<project name="join" default="default">
<description>
Index-time and Query-time joins for normalized content
Modified: lucene/dev/branches/branch_4x/lucene/spatial/build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/spatial/build.xml?rev=1493334&r1=1493333&r2=1493334&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/spatial/build.xml (original)
+++ lucene/dev/branches/branch_4x/lucene/spatial/build.xml Sat Jun 15 10:03:34 2013
@@ -1,4 +1,22 @@
<?xml version="1.0"?>
+<!--
+ 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.
+-->
<project name="spatial" default="default">
<description>
Geospatial search
Modified: lucene/dev/branches/branch_4x/lucene/tools/build.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/tools/build.xml?rev=1493334&r1=1493333&r2=1493334&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/tools/build.xml (original)
+++ lucene/dev/branches/branch_4x/lucene/tools/build.xml Sat Jun 15 10:03:34 2013
@@ -21,6 +21,9 @@
<description>Lucene Tools</description>
<property name="build.dir" location="../build/tools"/>
+
+ <!-- TODO: Add prettify ASF license header. Currently they have no header because they were compressed without License header! -->
+ <property name="rat.additional-includes" value="forbiddenApis/**"/>
<import file="../common-build.xml"/>
Modified: lucene/dev/branches/branch_4x/lucene/tools/custom-tasks.xml
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/tools/custom-tasks.xml?rev=1493334&r1=1493333&r2=1493334&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/tools/custom-tasks.xml (original)
+++ lucene/dev/branches/branch_4x/lucene/tools/custom-tasks.xml Sat Jun 15 10:03:34 2013
@@ -1,4 +1,21 @@
-
+<!--
+ 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.
+-->
<project name="custom-tasks">
<description>
This file is designed for importing into a main build file, and not intended