lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brian Cuttler <>
Subject Modify demo jar files, build question
Date Fri, 01 Nov 2002 15:46:09 GMT


I've installed ant 1.5.1 on Solaris 8 so that I could modify
the demo jar files that come with Lucene 1.2.

I've made a small modification to which is
under /lucene-1.2-src/src/demo/org/apache/lucene/demo, I've
modified the code to exclude the indexing of the .txt files.

I believe I have to compile the java file in order to create
a class file in order to replace IndexHTML in the demo.jar file.

If there is already code I can use that will index only the
htm and html files I'd be happy to use it...

Is that right ? Can I do that directly (it produced errors and
I don't know quite enough about java, ok, I don't know anything
about java).

Obviously this didn't work so looking at the I tried
a second attempt using ANT.

# javac Class org.apache.lucene.analysis.standard.StandardAnalyzer not found in
import org.apache.lucene.analysis.standard.StandardAnalyzer;
       ^ Package org.apache.lucene.index not found in import.
import org.apache.lucene.index.*;
       ^ Class org.apache.lucene.document.Document not found in import.
import org.apache.lucene.document.Document;
       ^ Class org.apache.lucene.util.Arrays not found in import.
import org.apache.lucene.util.Arrays;
       ^ Class org.apache.lucene.demo.html.HTMLParser not found in import.
import org.apache.lucene.demo.html.HTMLParser;
5 errors

I've added /usr/local/ant to my PATH.

I've set CLASSPATH to /tmp/ant/jakarta-ant-1.5.1/lib because
I thought ant  needed to find its jar files (and that is where
they are).

I # cd to the top level of the lucene file...

# cd /tmp/lucene/lucene-1.2-src
# ls
BUILD.txt           README.txt  src
CHANGES.txt         TODO.txt            lib
LICENSE.txt         build.xml           lucene-1.2-src.jar

Run ant...

# ant
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/tools/ant/Main

I realize I'm probably making some hidiously novice mistake.. can someone
help me out ?

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message