Using Xcode, the plugin base-SDK is 10.9 while the deployment is set to OSX 10.7. The application build with Xojo 2015r3.1 is used on OSX 10.7.5 and a runtime error is generated:
Message: Could not open plugin LexingCocoa
Not sure what to think of this. Someone could clarify what is going on?
is this error from your app or the IDE?
Anything showing in console?
or if you run app from terminal there?
This is what I get when launching Xojo 2015r3.1 on a newly installed OSX 10.7.5 (parallels):
11/18/15 10:54:38.200 AM Xojo: [RB] Unable to load plugin Lexing Plugin.xojo_plugin
11/18/15 10:54:38.222 AM [0x0-0x32032].com.xojo.xojo: dlopen(/private/var/folders/99/qkh5h0756hqcvv9551mlzvmr0000gn/T/1PZeoi.LexingCocoa, 1): Symbol not found: _environ
11/18/15 10:54:38.222 AM [0x0-0x32032].com.xojo.xojo: Referenced from: /private/var/folders/99/qkh5h0756hqcvv9551mlzvmr0000gn/T/1PZeoi.LexingCocoa
11/18/15 10:54:38.222 AM [0x0-0x32032].com.xojo.xojo: Expected in: /usr/lib/libSystem.B.dylib
11/18/15 10:54:38.222 AM [0x0-0x32032].com.xojo.xojo: in /private/var/folders/99/qkh5h0756hqcvv9551mlzvmr0000gn/T/1PZeoi.LexingCocoaNov 18 10:54:38 Alfreds-Mac.local Xojo : [RB] Unable to load plugin Lexing Plugin.xojo_plugin
So I am missing the symbol _environ
something wrong there.
so maybe define DYNAMIC somewhere?
Or maybe your C code has no prefix file which includes Apple frameworks, so Apple would set the variables for you.
Thanks for the pointer,
#if defined(__unix__) || defined(__APPLE__)
extern char **environ;
is doing fine in osx10.9 but not in osx10.7. Everything is linked to cocoa, appkit, etc. Your trick does not do it though. This code and the rest is not critical for the current plugin, so I removed it and fortunately all is well. Again, thanks.
However, I got to figure what’s going on, presumably it is not defined osx-lion: /usr/lib/libSystem.B.dylib