Using gcj as an extension language

Andy Tai atai@atai.org
Wed Dec 18 12:23:00 GMT 2002


Hi, this is just a general question about gcj... How
well can gcj be used as an extension language, in the
sense of guile?  I mean, I want to embed gcj
interpreter/run-time in a C program and implement high
level application logic in Java/gcj and "drives" low
level logic in C.  Or, like the way Emacs is done
(elisp on top of C).  This kind of application thus
does not make full use of the "standard" Java
environment as defined by Sun, i.e., AWT and SWING is
not used but the application uses low level C code
calling native GUI libraries.   However, standard data
structures like lists, hash tables, etc.  will be
useful for the Java driver code (I think GNU Classpath
already has these).
The existences of bindings to the GUI library at the
Java level is not important (as they are handled in
C).

Is the gcj runtime thread safe?  Can I call into the
runtime from multiple POSIX threads (started in C
code)?  Can I have multiple gcj interpreters active in
the same application?  

I am asking, because implementing large applications
in C in the GNOME environment is painful :-( 

Thanks for any info.



More information about the Java mailing list