16.3.2012 5:21, Me Myself and I kirjoitti:
I'm pretty well giving up on compiling GCJ under mingw32, or Windows 7 for that matter. Is there a GCJ, compiled for windows already, that I can download? One that is not the Java Native Compiler a la IBM, because it is payment limited. And certainly not gcc43ecj-20061207.tar, which puts too much into the executable file. One that supports 1.5 tiger syntax options and beyond.. And doesn't require commercial payment. And compiles an executable binary, as well as the option to build .class files? A URL, anyone?
The obvious choice would be the latest official MinGW GCC release which had Java support, the gcc-4.4.0 release : http://sourceforge.net/projects/mingw/files/MinGW/Base/gcc/Version4/Previous%20Release%20gcc-4.4.0/ What are the problems with this? BTW, one can easily try the latest GCC releases for MinGW-target via cross-compile, for instance : 0. build & install the common Linux-X-MinGW cross-binutils and install the MinGW runtime, w32api, libiconv, pthreads etc. required target libraries for the cross-toolchain(s) 1. build & install the Linux-X-MinGW cross-GCC(s) from the GCC sources 2. build & install the common "native" or MinGW-X-MinGW cross-binutils with the 0 and 1 step tools and install the MinGW runtime, w32api, libiconv, pthreads etc. required target libraries for the native or cross-toolchain(s) on the Windoze/MinGW host. 3. build & install the "native" or MinGW-X-MinGW cross-GCC(s) from the GCC sources with the 0 and 1 step tools. and see that the gcc-4.4.x and 4.5.x will (almost) succeed, 4.6.x will fail but 4.7.0(-RC) will again (almost) succeed. In all these "almost" cases the problem is the missing '-liconv' (or more in 4.5.x) in the : *-*-cygwin) extra_ldflags_libjava=-liconv ;; *-*-mingw*) extra_ldflags_libjava=-lws2_32 ;; seen in 'libjava/configure.ac' and 'libjava/configure', here the 4.7.0 one. The latter should of course be : *-*-mingw*) extra_ldflags_libjava="-liconv -lws2_32" ;; Whether the native MinGW/MSYS build platform is as stable and working as a typical Linux platform, I don't know. I myself used Ubuntu 11.04 for x86_64 as my build platform, however using a cross GCC for Linux/x86 as the build & host "CC", not the native default x86_64 target one... Ok, this was only for the "how to build" :-( For the "download and use" I haven't much to tell. Whether the toolchain(s) will work perfectly only heaven will know, I myself haven't any interest for the testing etc and maintaining the toolchain(s) for the "not-paying customers"... My choice for the GCC types was "cross" - to be incarnations of the "original" Linux-X-MinGW ones on the "secondary" MinGW runtime host: C:\opt\cross\bin>dir i586-mingw32-gcj-* Asemalla C ei ole nimeä. Aseman sarjanumero on 58E2-9BC5 Kansio C:\opt\cross\bin 15.03.2012 21:19 393 157 i586-mingw32-gcj-4.4.exe 16.03.2012 10:12 414 196 i586-mingw32-gcj-4.5.exe 16.03.2012 10:51 467 784 i586-mingw32-gcj-4.6.exe 15.03.2012 17:35 649 082 i586-mingw32-gcj-4.7.exe 4 tiedosto(a) 1 924 219 tavua 0 kansio(ta) 27 650 560 000 tavua vapaana When building now and then all kind of other $target GCCs etc for the MinGW-host, it really is only a runtime $host for me, nothing else...