linux audio software using gcj&swt!

Bryce McKinlay bryce@mckinlay.net.nz
Wed Oct 22 22:19:00 GMT 2003


On Oct 23, 2003, at 10:23 AM, Norbert Frese wrote:
> i have written a little free software application for scheduled sound
> recording on linux using swt and gcj.
>> http://www.scheinwelt.at/~norbertf/radiocap_homepage/
> (sources)

Looks nice!
> just a few questions:
>> 1) how can i do a static compile of my application with gcj? (cause
> libgcj is not so common).
>> the application starts but throws the following exception:
>> Caused by: java.util.MissingResourceException: Bundle
> gnu.java.locale.Calendar not found
> at java.util.ResourceBundle.getBundle(java.lang.String,
> java.util.Locale, java.lang.ClassLoader)
> (/mnt/tiny/gcc_cvs/gcc/libjava/java/util/ResourceBundle.java:388)

Static linking with Java is tricky. Certain resources may be missing 
because they are only loaded dynamically (ie Class.forName), and the 
linker can't see that to include them. One workaround is to add static 
links to the missing classes in your code ie:
static class foo = gnu.java.localeCalendar.class;
> 2) what do you think will be the future of swt on linux: will it ever
> become a kind of system-library (in its own package like gtk+ or wxgtk 
> -
> separated from applications)?

Yes, hopefully! The intent is that libgcj will become a system library 
that you can generally depend on being around too. The BC-ABI will help 
this along.
> this would have the advantage that pure
> GPLed swt-apps could be written and distributed legally.

Ideally the FSF people and the eclipse people would get together and 
sort out whatever it is that makes the SWT license incompatible with 
the GPL.
> 3) are there plans for a "fake" jni bridge, which would allow to 
> compile
> jni libraries and the "client-app" into a single binary (for better
> performance?)

Its already possible to do this, with a few tweaks. I don't know the 
exact details, but I believe redhat are doing it for their eclipse 
build. I'm not sure if it improves performance in itself, but there is 
room for optimization in our current JNI layer.
Regards
Bryce.


More information about the Java mailing list

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