GCC 3.3 MingW Crossed-Native Build Fails on fastjar

Ranjit Mathew rmathew@hotmail.com
Sun Feb 23 06:32:00 GMT 2003


> >> > The build fails on fastjar with the following unresolved symbols:
> >> >
> >> > jartool.o(.text+0x12ed):jartool.c: undefined reference to `opendir'
> >> > jartool.o(.text+0x14b0):jartool.c: undefined reference to `readdir'
> >> > jartool.o(.text+0x153a):jartool.c: undefined reference to `closedir'
>> >BTW, if you're using 3.3/3.4, this should no longer be necessary for
> >MinGW as the GCC specs file itself adds -lmingwex. You *are* using the
> >3.3 cross-compiler to build the crossed native compiler, right?
>>Ranjit (or anyone else that knows how to do this), I'm redoing the
>crossed-native build and the same fastjar error is occurring. I did
>a grep in ALL files in the gcc source distribution and was unable to
>find mingwex in any of them.

This is added by a mingw-local patch that has apparently not yet
made it to the GCC CVS. In any case, first locate the GCC "specs"
file in your MinGW cross-compiler installation - this is located
in the folder $XGCC_DIR/lib/gcc-lib/mingw32/3.3, where $XGCC_DIR
is the folder where you installed the cross-compiler. In this file,
change this line:
 %{mthreads:-lmingwthrd} -lmingw32 -lgcc -lmoldname -lmsvcrt
to this:
 %{mthreads:-lmingwthrd} -lmingw32 -lgcc -lmoldname -lmingwex -lmsvcrt
and you should be done.
BTW, this line is generated from the "#define LIBGCC_SPEC" line in
"gcc/config/i386/mingw32.h".
Hope this helps.
Ranjit.
_________________________________________________________________
The new MSN 8: smart spam protection and 2 months FREE* 
http://join.msn.com/?page=features/junkmail


More information about the Java mailing list

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