On Fri, 2 Jun 2006, Vic Bancroft wrote:

The following diff seemed to help build a nice native binary in my fedora. The first modification makes using the new core archive file name and the second avoids a problematic class . . .

You can actually compile all of Lucene + a bunch of contribs with gcj provided you apply some patches [1] and compile .java -> .class using javac from a JDK and .class -> .o -> .so with gcj.

Andi..

[1] http://svn.osafoundation.org/pylucene/trunk/patches.lucene


[EMAIL PROTECTED] lucene-trunk]$ svn diff

Index: src/gcj/Makefile

===================================================================

--- src/gcj/Makefile    (revision 410910)

+++ src/gcj/Makefile    (working copy)

@@ -8,7 +8,7 @@

CORE=$(BUILD)/classes/java

SRC=.

-CORE_OBJ:=$(subst .jar,.a,$(wildcard $(BUILD)/lucene-[0-9]*.jar))

+CORE_OBJ:=$(subst .jar,.a,$(wildcard $(BUILD)/lucene-core-[0-9].*.jar))

CORE_JAVA:=$(shell find $(ROOT)/src/java -name '*.java')

CORE_HEADERS=\

@@ -55,7 +55,7 @@

# yet accept from .class files.

# NOTE: Change when http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15501 is fixed. $(CORE_OBJ) : $(CORE_JAVA)

- $(GCJ) $(GCJFLAGS) -c -I $(CORE) -o $@ `find $(ROOT)/src/java -name '*.java' -not -name '*Sort*' -not -name 'Span*'` `find $(CORE) -name '*.class' -name '*Sort*' -or -name 'Span*'`

+ $(GCJ) $(GCJFLAGS) -c -I $(CORE) -o $@ `find $(ROOT)/src/java -name '*.java' -not -name '*Sort*' -not -name 'Span*' -not -name 'FieldCache*'` `find $(CORE) -name '*.class' -name '*Sort*' -or -name 'Span*' -or -name 'FieldCache*'`

# generate object code from jar files using gcj

%.a : %.jar


# -- # "The future is here. It's just not evenly distributed yet."
# -- William Gibson, quoted by Whitfield Diffie



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to