Re: jni with Guard Malloc
Re: jni with Guard Malloc
- Subject: Re: jni with Guard Malloc
- From: Eric Albert <email@hidden>
- Date: Sat, 11 Sep 2004 00:41:53 -0700
On Sep 10, 2004, at 11:39 PM, Dave Payne wrote:
On Sep 10, 2004, at 10:02 PM, Frank Rimlinger wrote:
I suppose there is something called _copysign that is multiply
defined,
but I only include the stock frameworks JavaVM.framework and
libstdc++.a. And why should Guard Malloc care one way or the other as
this is not a memory thing. Is there a way around this problem so
that
I can debug a C++ program that makes jni calls with Guard Malloc?
All applications on the system get libSystem.dylib pulled in
automatically. Unfortunately, it looks like the JavaVM's
libjava.jnilib exports a symbol of the same name (copysign) as
libSystem, thus requiring Java apps to need two-level namespace. (If
an app needs to include two different modules with symbols of the same
name, it needs two-level namespace.) I don't know what that copysign
symbol does in libjava.jnilib.
I would suggest filing a bug against the Java component giving your
observations.
I filed the same bug a while back and learned that unfortunately the
JVM can't be changed to avoid this. Hopefully at some point Mac OS X
will provide a way for Guard Malloc to override the functions that it
needs to replace while maintaining two-level namespaces. Once that
happens, Guard Malloc will work with Java applications.
Until then, your only option is to follow Dave's suggestion and see if
you can avoid pulling in the JavaVM framework for your Guard Malloc
tests.
-Eric
_______________________________________________
xcode-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/xcode-users
Do not post admin requests to the list. They will be ignored.