Jv_CreateJavaVM problems

steve steve@netfuel.com
Tue Jun 3 19:36:00 GMT 2003


Here is a very simple program what fails. I hope you guys can fix this 
soon. I would be willing to accept a work around if there is one. If it 
is already fixed please let us know or update the PR.
Thanks
Steve
[steve@pascal native]$ cat junk.cpp
#include <gcj/cni.h>
int main(int argc, char *argv[])
{
 JvCreateJavaVM(argv[0]);
}
[steve@pascal native]$ gcc -o junk junk.cpp -lgcj -static -ldl -lpthread
[steve@pascal native]$ ./junk
[steve@pascal native]$ gcc -o junk junk.cpp -lgcj
[steve@pascal native]$ ./junk
Segmentation fault
[steve@pascal native]$
Just to make sure that I am not getting some other version of libgcj.
[root@pascal root]# find / -name libgcj.so
/opt/gcc-3.3/lib/libgcj.so
[root@pascal root]#
echo $LD_LIBRARY_PATH
/opt/gcc-3.3/lib
[steve@pascal native]$ gcc -v
Reading specs from /opt/gcc-3.3/lib/gcc-lib/i686-pc-linux-gnu/3.3/specs
Configured with: ../configure --prefix /opt/gcc-3.3
Thread model: posix
gcc version 3.3
steve wrote:
> I have been working with the 3.3 release of gcc.
>> If you compile using -static -lpthread -ldl -lgcj it works with and with 
> out the work around mentioned below.
>> However I can not get the dynamically liked version to work at all. 
> Still have the same problem mentions if PR 8685.
>> Thanks
> Steve



More information about the Java mailing list

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