[jitsi-dev] Symbol not found: _OBJC_METACLASS_$_NSObject in libjnawtrenderer


#1

When using libjitsi on OS X 10.6.8, I get an error when I call LibJitsi.getMediaService(), although the call seems to still work. This appears to be the relevant output:

SEVERE: Failed to register custom Renderer org.jitsi.impl.neomedia.jmfext.media.renderer.video.JAWTRenderer with JMF.
java.lang.UnsatisfiedLinkError: /Users/bjorn/Documents/workspace/jingle-test2/libs/libjitsi/lib/native/mac/libjnawtrenderer.jnilib: Symbol not found: _OBJC_METACLASS_$_NSObject Referenced from: /Users/bjorn/Documents/workspace/jingle-test2/libs/libjitsi/lib/native/mac/libjnawtrenderer.jnilib Expected in: /usr/lib/libobjc.A.dylib in /Users/bjorn/Documents/workspace/jingle-test2/libs/libjitsi/lib/native/mac/libjnawtrenderer.jnilib
  at java.lang.ClassLoader$NativeLibrary.load(Native Method)
  at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1827)
  at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1742)
  at java.lang.Runtime.loadLibrary0(Runtime.java:823)
  at java.lang.System.loadLibrary(System.java:1045)
  at org.jitsi.impl.neomedia.jmfext.media.renderer.video.JAWTRenderer.<clinit>(JAWTRenderer.java:90)
  at java.lang.Class.forName0(Native Method)
  at java.lang.Class.forName(Class.java:171)
  at org.jitsi.impl.neomedia.device.DeviceConfiguration.registerCustomRenderers(DeviceConfiguration.java:815)
  at org.jitsi.impl.neomedia.device.DeviceConfiguration.<init>(DeviceConfiguration.java:288)
  at org.jitsi.impl.neomedia.MediaServiceImpl.<init>(MediaServiceImpl.java:122)
  at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
  at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
  at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
  at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
  at java.lang.Class.newInstance0(Class.java:357)
  at java.lang.Class.newInstance(Class.java:310)
  at org.jitsi.impl.libjitsi.LibJitsiImpl.getService(LibJitsiImpl.java:132)
  at org.jitsi.service.libjitsi.LibJitsi.invokeGetServiceOnImpl(LibJitsi.java:163)
  at org.jitsi.service.libjitsi.LibJitsi.getMediaService(LibJitsi.java:115)
....

Many posts online, including this

http://prod.lists.apple.com/archives/cocoa-dev/2013/Jan/msg00525.html

suggest that such errors are due to setting the wrong target in XCode (you must set the target to 10.7 or earlier when building on 10.8).

  bjorn

···

-----------------------------
Bjorn Roche
http://www.xonami.com
Audio Collaboration
http://blog.bjornroche.com
@xonamiaudio