xref: /OpenGrok/opengrok-indexer/pom.xml (revision 1a2bb6b62dad61e494b39e2d2ff60155a362319f)
108a0c20eSJorgen Austvik<?xml version="1.0" encoding="UTF-8"?>
218446c8aSKnut Anders Hatlen<!--
318446c8aSKnut Anders Hatlen
418446c8aSKnut Anders HatlenCDDL HEADER START
518446c8aSKnut Anders Hatlen
618446c8aSKnut Anders HatlenThe contents of this file are subject to the terms of the
718446c8aSKnut Anders HatlenCommon Development and Distribution License (the "License").
818446c8aSKnut Anders HatlenYou may not use this file except in compliance with the License.
918446c8aSKnut Anders Hatlen
1018446c8aSKnut Anders HatlenSee LICENSE.txt included in this distribution for the specific
1118446c8aSKnut Anders Hatlenlanguage governing permissions and limitations under the License.
1218446c8aSKnut Anders Hatlen
1318446c8aSKnut Anders HatlenWhen distributing Covered Code, include this CDDL HEADER in each
1418446c8aSKnut Anders Hatlenfile and include the License file at LICENSE.txt.
1518446c8aSKnut Anders HatlenIf applicable, add the following below this CDDL HEADER, with the
1618446c8aSKnut Anders Hatlenfields enclosed by brackets "[]" replaced with your own identifying
1718446c8aSKnut Anders Hatleninformation: Portions Copyright [yyyy] [name of copyright owner]
1818446c8aSKnut Anders Hatlen
1918446c8aSKnut Anders HatlenCDDL HEADER END
2018446c8aSKnut Anders Hatlen
2156f072caSAdam HornáčekCopyright (c) 2010, 2018, Oracle and/or its affiliates. All rights reserved.
22431a6d7cSChris FrairePortions Copyright (c) 2017-2018, Chris Fraire <cfraire@me.com>.
2318446c8aSKnut Anders Hatlen
2418446c8aSKnut Anders Hatlen-->
250170aac5SAdam Hornáček<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
2608a0c20eSJorgen Austvik    <modelVersion>4.0.0</modelVersion>
2708a0c20eSJorgen Austvik
2808a0c20eSJorgen Austvik    <parent>
2956f072caSAdam Hornáček        <groupId>org.opengrok</groupId>
306ed99b2dSVladimir Kotal        <artifactId>opengrok-top</artifactId>
314b01e6e7SVladimir Kotal        <version>1.1-rc30</version>
3208a0c20eSJorgen Austvik    </parent>
3308a0c20eSJorgen Austvik
34bb76b0b8SAdam Hornáček    <artifactId>opengrok</artifactId>
35a03922c4SAdam Hornáček    <version>1.1-rc30</version>
360170aac5SAdam Hornáček    <packaging>jar</packaging>
370170aac5SAdam Hornáček
380170aac5SAdam Hornáček    <name>OpenGrok Indexer</name>
390170aac5SAdam Hornáček
400170aac5SAdam Hornáček    <dependencies>
410170aac5SAdam Hornáček        <dependency>
420170aac5SAdam Hornáček            <groupId>org.apache.bcel</groupId>
430170aac5SAdam Hornáček            <artifactId>bcel</artifactId>
440170aac5SAdam Hornáček        </dependency>
450170aac5SAdam Hornáček        <dependency>
460170aac5SAdam Hornáček            <groupId>org.apache.lucene</groupId>
470170aac5SAdam Hornáček            <artifactId>lucene-core</artifactId>
480170aac5SAdam Hornáček        </dependency>
490170aac5SAdam Hornáček        <dependency>
500170aac5SAdam Hornáček            <groupId>org.apache.lucene</groupId>
510170aac5SAdam Hornáček            <artifactId>lucene-analyzers-common</artifactId>
520170aac5SAdam Hornáček        </dependency>
530170aac5SAdam Hornáček        <dependency>
540170aac5SAdam Hornáček            <groupId>org.apache.lucene</groupId>
552cacd6e7SAdam Hornáček            <artifactId>lucene-highlighter</artifactId>
562cacd6e7SAdam Hornáček        </dependency>
572cacd6e7SAdam Hornáček        <dependency>
582cacd6e7SAdam Hornáček            <groupId>org.apache.lucene</groupId>
592cacd6e7SAdam Hornáček            <artifactId>lucene-join</artifactId>
602cacd6e7SAdam Hornáček        </dependency>
612cacd6e7SAdam Hornáček        <dependency>
622cacd6e7SAdam Hornáček            <groupId>org.apache.lucene</groupId>
632cacd6e7SAdam Hornáček            <artifactId>lucene-memory</artifactId>
642cacd6e7SAdam Hornáček        </dependency>
652cacd6e7SAdam Hornáček        <dependency>
662cacd6e7SAdam Hornáček            <groupId>org.apache.lucene</groupId>
672cacd6e7SAdam Hornáček            <artifactId>lucene-queries</artifactId>
682cacd6e7SAdam Hornáček        </dependency>
692cacd6e7SAdam Hornáček        <dependency>
702cacd6e7SAdam Hornáček            <groupId>org.apache.lucene</groupId>
710170aac5SAdam Hornáček            <artifactId>lucene-queryparser</artifactId>
720170aac5SAdam Hornáček        </dependency>
730170aac5SAdam Hornáček        <dependency>
740170aac5SAdam Hornáček            <groupId>org.apache.lucene</groupId>
75f11f248bSAdam Hornáček            <artifactId>lucene-backward-codecs</artifactId>
76f11f248bSAdam Hornáček            <version>${lucene.version}</version>
77f11f248bSAdam Hornáček        </dependency>
78f11f248bSAdam Hornáček        <dependency>
79f11f248bSAdam Hornáček            <groupId>org.apache.lucene</groupId>
800170aac5SAdam Hornáček            <artifactId>lucene-suggest</artifactId>
810170aac5SAdam Hornáček        </dependency>
820170aac5SAdam Hornáček        <dependency>
830170aac5SAdam Hornáček            <groupId>javax.servlet</groupId>
84e393cb49SAdam Hornáček            <artifactId>javax.servlet-api</artifactId>
850170aac5SAdam Hornáček        </dependency>
860170aac5SAdam Hornáček        <dependency>
870170aac5SAdam Hornáček            <groupId>com.googlecode.json-simple</groupId>
880170aac5SAdam Hornáček            <artifactId>json-simple</artifactId>
890170aac5SAdam Hornáček        </dependency>
900170aac5SAdam Hornáček        <dependency>
9156f072caSAdam Hornáček            <groupId>org.opengrok</groupId>
920170aac5SAdam Hornáček            <artifactId>jrcs</artifactId>
930170aac5SAdam Hornáček            <version>${project.version}</version>
940170aac5SAdam Hornáček        </dependency>
950170aac5SAdam Hornáček        <dependency>
960170aac5SAdam Hornáček            <groupId>org.apache.ant</groupId>
970170aac5SAdam Hornáček            <artifactId>ant</artifactId>
980170aac5SAdam Hornáček        </dependency>
99*1a2bb6b6SAdam Hornáček        <dependency> <!-- TODO: remove! (moving Messages to web module) -->
100*1a2bb6b6SAdam Hornáček            <groupId>org.glassfish.jersey.ext</groupId>
101*1a2bb6b6SAdam Hornáček            <artifactId>jersey-bean-validation</artifactId>
1024ce4e2b9SAdam Hornáček            <version>${jersey.version}</version>
1034ce4e2b9SAdam Hornáček        </dependency>
1044ce4e2b9SAdam Hornáček        <dependency>
1054ce4e2b9SAdam Hornáček            <groupId>org.glassfish.jersey.media</groupId>
1064ce4e2b9SAdam Hornáček            <artifactId>jersey-media-json-jackson</artifactId>
1074ce4e2b9SAdam Hornáček            <version>${jersey.version}</version>
1084ce4e2b9SAdam Hornáček        </dependency>
1094ce4e2b9SAdam Hornáček        <dependency>
110*1a2bb6b6SAdam Hornáček            <groupId>org.glassfish.jersey.core</groupId>
111*1a2bb6b6SAdam Hornáček            <artifactId>jersey-client</artifactId>
1124ce4e2b9SAdam Hornáček            <version>${jersey.version}</version>
1134ce4e2b9SAdam Hornáček        </dependency>
1144ce4e2b9SAdam Hornáček        <dependency>
115*1a2bb6b6SAdam Hornáček            <groupId>org.glassfish.jersey.inject</groupId>
116*1a2bb6b6SAdam Hornáček            <artifactId>jersey-hk2</artifactId>
117*1a2bb6b6SAdam Hornáček            <version>${jersey.version}</version>
1184ce4e2b9SAdam Hornáček        </dependency>
1194ce4e2b9SAdam Hornáček        <dependency>
1200170aac5SAdam Hornáček            <groupId>junit</groupId>
1210170aac5SAdam Hornáček            <artifactId>junit</artifactId>
1220170aac5SAdam Hornáček            <scope>test</scope>
1230170aac5SAdam Hornáček        </dependency>
124*1a2bb6b6SAdam Hornáček        <dependency> <!-- TODO: remove! (moving Messages to web module) -->
1254ce4e2b9SAdam Hornáček            <groupId>org.awaitility</groupId>
1264ce4e2b9SAdam Hornáček            <artifactId>awaitility</artifactId>
1274ce4e2b9SAdam Hornáček            <version>3.1.0</version>
1284ce4e2b9SAdam Hornáček            <scope>test</scope>
1294ce4e2b9SAdam Hornáček        </dependency>
1300170aac5SAdam Hornáček    </dependencies>
1310170aac5SAdam Hornáček
13208a0c20eSJorgen Austvik    <build>
133aa4907e2SLubos Kosco
13408a0c20eSJorgen Austvik        <plugins>
135e0f7ec00SKnut Anders Hatlen
136e0f7ec00SKnut Anders Hatlen            <plugin>
137e0f7ec00SKnut Anders Hatlen                <groupId>org.apache.maven.plugins</groupId>
138e0f7ec00SKnut Anders Hatlen                <artifactId>maven-jar-plugin</artifactId>
1399f619df4SLubos Kosco                <version>3.0.2</version>
140e0f7ec00SKnut Anders Hatlen                <configuration>
141e0f7ec00SKnut Anders Hatlen                    <archive>
142e0f7ec00SKnut Anders Hatlen                        <manifest>
143686556f2SAdam Hornáček                            <mainClass>org.opengrok.indexer.index.Indexer</mainClass>
144e0f7ec00SKnut Anders Hatlen                            <addClasspath>true</addClasspath>
145e0f7ec00SKnut Anders Hatlen                            <classpathPrefix>lib/</classpathPrefix>
146e0f7ec00SKnut Anders Hatlen                        </manifest>
147e0f7ec00SKnut Anders Hatlen                        <manifestEntries>
148e0f7ec00SKnut Anders Hatlen                        </manifestEntries>
149e0f7ec00SKnut Anders Hatlen                    </archive>
150e0f7ec00SKnut Anders Hatlen                </configuration>
151*1a2bb6b6SAdam Hornáček                <executions> <!-- so the web module can use test classes from indexer module -->
152*1a2bb6b6SAdam Hornáček                    <execution>
153*1a2bb6b6SAdam Hornáček                        <goals>
154*1a2bb6b6SAdam Hornáček                            <goal>test-jar</goal>
155*1a2bb6b6SAdam Hornáček                        </goals>
156*1a2bb6b6SAdam Hornáček                    </execution>
157*1a2bb6b6SAdam Hornáček                </executions>
158e0f7ec00SKnut Anders Hatlen            </plugin>
159e0f7ec00SKnut Anders Hatlen
16008a0c20eSJorgen Austvik            <plugin>
16108a0c20eSJorgen Austvik                <groupId>de.jflex</groupId>
16245ec3841SLubos Kosco                <artifactId>jflex-maven-plugin</artifactId>
1634e6518cbSLubos Kosco                <version>1.6.1</version>
16408a0c20eSJorgen Austvik                <executions>
16508a0c20eSJorgen Austvik                    <execution>
16608a0c20eSJorgen Austvik                        <goals>
16708a0c20eSJorgen Austvik                            <goal>generate</goal>
16808a0c20eSJorgen Austvik                        </goals>
16908a0c20eSJorgen Austvik                        <configuration>
17008a0c20eSJorgen Austvik                            <lexDefinitions>
17158f88ff1SChris Fraire                                <lexDefinition>${basedir}/target/jflex-sources</lexDefinition>
17208a0c20eSJorgen Austvik                            </lexDefinitions>
17345ec3841SLubos Kosco                            <inputStreamCtor>false</inputStreamCtor>
17408a0c20eSJorgen Austvik                        </configuration>
17508a0c20eSJorgen Austvik                    </execution>
17608a0c20eSJorgen Austvik                </executions>
17708a0c20eSJorgen Austvik            </plugin>
1789182cd30SLubos Kosco
179eeb7e5b3SAdam Hornáček            <!-- patches jflex generated files to stop increasing buffer beyond token size that lucene accepts
180ff70ede8SLubos Kosco            https://github.com/OpenGrok/OpenGrok/issues/1170 make parsers stop producing tokens > 32766 chars
181ba14bbd8SLubos Kosco            at least for PlainFullTokenizer, PlainSymbolTokenizer, JavaScriptSymbolTokenizer, JavaSymbolTokenizer
1829182cd30SLubos Kosco            use below
1839182cd30SLubos Kosco            -->
1849182cd30SLubos Kosco
185ff70ede8SLubos Kosco            <plugin>
186ff70ede8SLubos Kosco                <groupId>com.google.code.maven-replacer-plugin</groupId>
187ff70ede8SLubos Kosco                <artifactId>replacer</artifactId>
1889182cd30SLubos Kosco                <version>1.5.3</version>
189ff70ede8SLubos Kosco                <executions>
190ff70ede8SLubos Kosco                    <execution>
1919182cd30SLubos Kosco                        <phase>generate-sources</phase>
192ff70ede8SLubos Kosco                        <goals>
193ff70ede8SLubos Kosco                            <goal>replace</goal>
194ff70ede8SLubos Kosco                        </goals>
195ff70ede8SLubos Kosco                    </execution>
196ff70ede8SLubos Kosco                </executions>
197ff70ede8SLubos Kosco                <configuration>
1989182cd30SLubos Kosco                    <filesToInclude>
1999805b761SAdam Hornáček                        ${basedir}/target/generated-sources/jflex/org/opengrok/indexer/analysis/java/JavaSymbolTokenizer.java,${basedir}/target/generated-sources/jflex/org/opengrok/indexer/analysis/javascript/JavaScriptSymbolTokenizer.java,${basedir}/target/generated-sources/jflex/org/opengrok/indexer/analysis/plain/PlainFullTokenizer.java,${basedir}/target/generated-sources/jflex/org/opengrok/indexer/analysis/plain/PlainSymbolTokenizer.java
2009182cd30SLubos Kosco                    </filesToInclude>
2019182cd30SLubos Kosco                    <replacements>
2029182cd30SLubos Kosco                        <replacement>
2039182cd30SLubos Kosco                            <token>private static final int ZZ_BUFFERSIZE =</token>
2049182cd30SLubos Kosco                            <value>private int ZZ_BUFFERSIZE =</value>
2059182cd30SLubos Kosco                        </replacement>
2069182cd30SLubos Kosco                        <replacement>
2079182cd30SLubos Kosco                            <token>int requested = zzBuffer\.length - zzEndRead;</token>
2089182cd30SLubos Kosco                            <value>int requested = zzBuffer.length - zzEndRead - zzFinalHighSurrogate;</value>
2099182cd30SLubos Kosco                        </replacement>
2109182cd30SLubos Kosco                        <replacement>
2119182cd30SLubos Kosco                            <token>(zzFinalHighSurrogate = 1;)(\r?\n)</token>
2129182cd30SLubos Kosco                            <value>$1$2          if (numRead == 1) { return true; }$2</value>
2139182cd30SLubos Kosco                        </replacement>
2149182cd30SLubos Kosco
2159182cd30SLubos Kosco                        <replacement>
2169182cd30SLubos Kosco                            <token>[ \t]*/\* is the buffer big enough\? \*/\s+if \(zzCurrentPos >= zzBuffer\.length.*?\}[ \t]*\r?\n</token>
2179182cd30SLubos Kosco                            <value></value>
2189182cd30SLubos Kosco                        </replacement>
2199182cd30SLubos Kosco                        <!-- also revert 0 character check that got in with 1.6.1 : https://github.com/jflex-de/jflex/blob/master/jflex/examples/zero-reader/README.md -->
2209182cd30SLubos Kosco                        <replacement>
2219182cd30SLubos Kosco                            <token>[ \t]*/\* not supposed to occur according to specification of java\.io\.Reader \*/\s+if \(numRead == 0.*?\}[ \t]*\r?\n</token>
2229182cd30SLubos Kosco                            <value></value>
2239182cd30SLubos Kosco                        </replacement>
2249182cd30SLubos Kosco
2259182cd30SLubos Kosco                    </replacements>
226ff70ede8SLubos Kosco                    <regexFlags>
2279182cd30SLubos Kosco                        <regexFlag>DOTALL</regexFlag>
228ff70ede8SLubos Kosco                    </regexFlags>
229ff70ede8SLubos Kosco                </configuration>
2309182cd30SLubos Kosco            </plugin>
2312e3d7e6eSJorgen Austvik
2322e3d7e6eSJorgen Austvik            <plugin>
23345ec3841SLubos Kosco                <groupId>org.apache.maven.plugins</groupId>
2342e3d7e6eSJorgen Austvik                <artifactId>maven-antrun-plugin</artifactId>
2359f619df4SLubos Kosco                <version>1.8</version>
2362e3d7e6eSJorgen Austvik                <executions>
2372e3d7e6eSJorgen Austvik                    <execution>
23858f88ff1SChris Fraire                        <id>collect-lex-lexh</id>
23958f88ff1SChris Fraire                        <phase>initialize</phase>
24058f88ff1SChris Fraire                        <configuration>
24158f88ff1SChris Fraire                            <target>
242eeb7e5b3SAdam Hornáček                                <property name="src.dir" value="src/main/resources"/>
24358f88ff1SChris Fraire                                <property name="tgt.dir" value="${basedir}/target/jflex-sources"/>
24458f88ff1SChris Fraire                                <ant target="-collect-lex-lexh"/>
24558f88ff1SChris Fraire                            </target>
24658f88ff1SChris Fraire                        </configuration>
24758f88ff1SChris Fraire                        <goals>
24858f88ff1SChris Fraire                            <goal>run</goal>
24958f88ff1SChris Fraire                        </goals>
25058f88ff1SChris Fraire                    </execution>
25158f88ff1SChris Fraire                    <execution>
25258f88ff1SChris Fraire                        <id>update-build-info</id>
25318446c8aSKnut Anders Hatlen                        <phase>generate-resources</phase>
25418446c8aSKnut Anders Hatlen                        <configuration>
25518446c8aSKnut Anders Hatlen                            <target>
25645ec3841SLubos Kosco                                <property name="version" value="${project.version}"/>
25718446c8aSKnut Anders Hatlen                                <ant target="-update-build-info"/>
25818446c8aSKnut Anders Hatlen                            </target>
25918446c8aSKnut Anders Hatlen                        </configuration>
26018446c8aSKnut Anders Hatlen                        <goals>
26118446c8aSKnut Anders Hatlen                            <goal>run</goal>
26218446c8aSKnut Anders Hatlen                        </goals>
26318446c8aSKnut Anders Hatlen                    </execution>
26418446c8aSKnut Anders Hatlen                    <execution>
2652e3d7e6eSJorgen Austvik                        <id>build-config-files</id>
2662e3d7e6eSJorgen Austvik                        <phase>process-test-classes</phase>
2672e3d7e6eSJorgen Austvik                        <goals>
2682e3d7e6eSJorgen Austvik                            <goal>run</goal>
2692e3d7e6eSJorgen Austvik                        </goals>
2702e3d7e6eSJorgen Austvik                        <configuration>
27118446c8aSKnut Anders Hatlen                            <target unless="maven.test.skip">
27218446c8aSKnut Anders Hatlen                                <ant target="-post-compile-test"/>
27318446c8aSKnut Anders Hatlen                            </target>
2742e3d7e6eSJorgen Austvik                        </configuration>
2752e3d7e6eSJorgen Austvik                    </execution>
2762e3d7e6eSJorgen Austvik                </executions>
2772e3d7e6eSJorgen Austvik            </plugin>
2782e3d7e6eSJorgen Austvik
279aa4907e2SLubos Kosco            <plugin>
280aa4907e2SLubos Kosco                <groupId>org.apache.maven.plugins</groupId>
281aa4907e2SLubos Kosco                <artifactId>maven-surefire-plugin</artifactId>
282aa4907e2SLubos Kosco                <configuration>
283aa4907e2SLubos Kosco                    <excludes>
284aa4907e2SLubos Kosco                        <!-- Test helper class with name that confuses surefire -->
285aa4907e2SLubos Kosco                        <exclude>**/TestRepository.java</exclude>
286aa4907e2SLubos Kosco                    </excludes>
28734684d40SVladimir Kotal                    <argLine>${surefireArgLine}</argLine>
288aa4907e2SLubos Kosco                </configuration>
289aa4907e2SLubos Kosco            </plugin>
290aa4907e2SLubos Kosco
291bc6c8375SVladimir Kotal            <plugin>
292bc6c8375SVladimir Kotal                <groupId>org.codehaus.mojo</groupId>
293bc6c8375SVladimir Kotal                <artifactId>exec-maven-plugin</artifactId>
294bc6c8375SVladimir Kotal                <version>1.6.0</version>
295bc6c8375SVladimir Kotal                <executions>
296bc6c8375SVladimir Kotal                    <execution>
297bc6c8375SVladimir Kotal                        <phase>verify</phase>
298bc6c8375SVladimir Kotal                            <goals>
299bc6c8375SVladimir Kotal                                <goal>exec</goal>
300bc6c8375SVladimir Kotal                            </goals>
301bc6c8375SVladimir Kotal                    </execution>
302bc6c8375SVladimir Kotal                </executions>
303bc6c8375SVladimir Kotal                <configuration>
304bc6c8375SVladimir Kotal                    <executable>pep8</executable>
305bc6c8375SVladimir Kotal                    <arguments>
306bc6c8375SVladimir Kotal                        <argument>-v</argument>
307873a5de8SVladimir Kotal                        <argument>--exclude=filelock.py,test_command.py,test_commands.py</argument>
308bc6c8375SVladimir Kotal                        <argument>${project.basedir}/../tools/sync</argument>
309bc6c8375SVladimir Kotal                    </arguments>
310bc6c8375SVladimir Kotal                </configuration>
311bc6c8375SVladimir Kotal            </plugin>
312aa4907e2SLubos Kosco
31308a0c20eSJorgen Austvik        </plugins>
31408a0c20eSJorgen Austvik    </build>
31508a0c20eSJorgen Austvik
31608a0c20eSJorgen Austvik</project>
317