Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 64907 - Add gcj to xmingw-gcc
Summary: Add gcj to xmingw-gcc
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 All
: Normal enhancement
Assignee: Stefan Jones (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-09-21 15:37 UTC by chris-gentoo
Modified: 2004-09-22 11:11 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
gcj support for xmingw-gcc (gcj.patch,1.14 KB, patch)
2004-09-21 15:40 UTC, chris-gentoo
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description chris-gentoo 2004-09-21 15:37:36 UTC
Here's a partial patch to compile xmingw-gcc-3.4.1 with gcj support. However at the moment it doesn't create or install the libgcj.spec file, and I can't figure out how to get it to.

Configure options are based on those I found at
http://ranjitmathew.tripod.com/phartz/gcj/bldgcj.html
Comment 1 chris-gentoo 2004-09-21 15:40:02 UTC
Created attachment 40130 [details, diff]
gcj support for xmingw-gcc

Patch for gcj and debug use flags
Comment 2 Stefan Jones (RETIRED) gentoo-dev 2004-09-21 21:53:00 UTC
If you get this working I will happily add it. I think it should use the java use variable as I think that is what the normal gcc ebuild uses to enable gcj.

Will have a play when I have time. Thanks
Comment 3 chris-gentoo 2004-09-21 22:05:48 UTC
All the latest sys-devel/gcc ebuilds declare
IUSE="... gcj ..."
no java flag.
Plus
# euse -i gcj
gcj [+] [C] [L] [sys-devel/gcc] : Build gcj (java compiler included with gcc
                package)
Comment 4 Stefan Jones (RETIRED) gentoo-dev 2004-09-22 09:06:39 UTC
Looks like you have modified your patch after you tested it to neaten it up! All minor stuff.

Like config being set and not being used, $myconf="" not being right.

For the spec file, it needs to be moved after the make install step has finished, see the regular gcc ebuild. Same problem there, also google has some information.
Comment 5 Stefan Jones (RETIRED) gentoo-dev 2004-09-22 11:11:52 UTC
Done. See xmingw-gcc-3.4.1-r1.ebuild

I had to remove --enable-version-specific-runtime-libs config option as that was causing problems with finding libraries and spec files.

Also fixed up the typos.

Tested with: hello.java
class hello {
        public static void main(String[] args) {
                System.out.println("Hello World!"); //Display the string.
        }
}

$ i386-mingw32msvc-gcj hello.java --main=hello
$ ls -l a.exe
-rwxr-xr-x  1 saj users 15347637 Sep 22 11:01 a.exe
$ wine ./a.exe
Hello World!

All works then ... but gcj and java is horrible, 15Mb exe ?!?!