OpenGL causing DllNotFoundException on OSX

Hi,

I am running the trial of unity pro 4.2.1f4 to see if it’s a viable option for an upcoming gig at work. We are interested in using libcinder.org within a native plugin. OSX for now although windows soon. I have run the following example fine:
Unity - Manual: Low-level native plug-in interface

but to recompile it I must change

#include <OpenGL/OpenGL.h>

to

#include <OpenGL/gl.h>

(both are in the OpenGL.framework)

However, after compiling it with Xcode 5 on OSX 10.8.5 successfully I place it in the Plugins folder and I get ‘DllNotFOundException’ error that points to the correct path of the bundle. From my googlings it seems this may be due to dependancies but I find this strange given the above was the only change I made to the example.

Any advice? I have no problem including libcinder and compiling but I get the same error so hopefully resolving the simpler issue above will fix this too.

Best,
nay.

So it turns out that despite documentation regarding universal binaries the plugin will only load correctly if 32 bit when compiled with XCode 4.6 or 5 using any of the available compilers (LLVM 4.2, LLVM GCC 4.2, LLVM 5.0). I assume this is a Unity bug although at least I can get it to work for my purposes at the moment.

One other very annoying bug that came up is that Unity will only detect changes to the plugin when I reimport all assets (the refresh command does not work). This makes for incredibly slow development.

I have filed bug reports relating to both of these issues ( 569289 and 569290 ).