LibGCJ static linking trouble

Andrew Haley aph@redhat.com
Wed Nov 15 17:47:00 GMT 2006


Thomas Womack writes:
 > 
 > I'm following the instructions in
 > http://gcc.gnu.org/wiki/Statically%20linking%20libgcj
 > for compiling things so that they don't need libgcj.so at runtime.
Hmm. I think I need to edit that page.
 > The final link-it-all-together line in my makefile is (remove carriage 
 > returns as needed)
 > 
 > $(EXECOUT)/%: %-adaptor.o globalphasing/maketnt/%.o $(maketntlibs) $(javalibs)
 > $(GCJ) -o $(EXECOUT)/$* $^ -shared-libgcc 
 > -Wl,-non_shared -lgcj -Wl,-call_shared -lsupc++ -Wl,--as-needed -lz 
 > -lgcc_s -lpthread -lc -lm -ldl -Wl,--no-as-needed
This is wrong. You're using $(GCJ) to do the link.
That's not what the page says.
Andrew.


More information about the Java mailing list

AltStyle によって変換されたページ (->オリジナル) /