You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by Vic Bancroft <ba...@america.net> on 2006/06/03 05:35:57 UTC
gjc compile
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 . . .
[bancroft@orca 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: java-dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-dev-help@lucene.apache.org
Re: gjc compile
Posted by Andi Vajda <va...@osafoundation.org>.
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
>
> [bancroft@orca 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: java-dev-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-dev-help@lucene.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-dev-help@lucene.apache.org