
Can't build on OS X
Posted Monday, 3 March, 2008 - 01:18 by seoushi inI'm not sure if this is mono related or mac related error but here is what I did.
Extracted the zip, went into Build via the terminal and ran "mono Build.exe mono" it runs fine until OpenTK.dll is trying to be made. Here is the relevant output
[csc] ** (/Library/Frameworks/Mono.framework/Versions/1.2.6/lib/mono/2.0/gmcs.exe:19216): WARNING **: The class Mono.WebBrowser.DOM.IDocument could not be loaded, used in Mono.Mozilla, Version=0.2.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756 [csc] ** (/Library/Frameworks/Mono.framework/Versions/1.2.6/lib/mono/2.0/gmcs.exe:19216): WARNING **: The class Mono.WebBrowser.DOM.IElement could not be loaded, used in Mono.Mozilla, Version=0.2.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756 [csc] ** (/Library/Frameworks/Mono.framework/Versions/1.2.6/lib/mono/2.0/gmcs.exe:19216): WARNING **: The class Mono.WebBrowser.DOM.IWindow could not be loaded, used in Mono.Mozilla, Version=0.2.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756 [csc] Unhandled Exception: System.Reflection.ReflectionTypeLoadException: The classes in the module cannot be loaded. [csc] at (wrapper managed-to-native) System.Reflection.Assembly:GetTypes (bool) [csc] at System.Reflection.Assembly.GetExportedTypes () [0x00000] [csc] at Mono.CSharp.TypeManager.LoadAllImportedTypes () [0x00000] [csc] at Mono.CSharp.Driver.MainDriver (System.String[] args) [0x00000] [csc] at Mono.CSharp.Driver.Main (System.String[] args) [0x00000] BUILD FAILED - 0 non-fatal error(s), 68 warning(s) /Users/seoushi/Desktop/opentk-0.9.0/Source/OpenTK/OpenTK.dll.build(10,10): External Program Failed: /Library/Frameworks/Mono.framework/Versions/1.2.6/lib/mono/2.0/gmcs.exe (return code was 1)
I'm curious where in the code Mono.WebBrower.DOM.IWindow is referenced (or what would be calling it). Also is there anyway for the build to be more verbose like what file is causing the exception?


Comments
Re: Can't build on OS X
It's difficult to say what is wrong without a debug build.
Wild stab: try using the default contructor for GameWindow (
new GameWindow()), or specify a non-null DisplayMode and title for GameWindow (e.g.new GameWindow(new DisplayMode(640, 480), "Test")).Does Examples.exe run on OSX? Try running a few samples from that, to see if they behave the same - this will help pinpoint the actual problem.
Re: Can't build on OS X
Being at work I can't really test too much but the examples have the same issue as my last post. Will work on this more when I'm at home.
Re: Can't build on OS X
No problem. :)
It might be useful to create a debug build on Windows and run that on OSX (instructions). Not as good as a native Mono debug build (which would give the exact line number of the crash), but it can help.
Re: Can't build on OS X
Well now I'm just confused. For a frame of reference I use 10.5 at home and 10.4 at work. Now that I'm at home I tested it by making the debug dll and enabling debug information in my program like the previous link and it works. What is even stranger is that after I got that working I put in the orignal opentk.dll and it works. Then I proceeded to rebuild my application in release mode and it works (except some windows centric path names).
So in other words my issue is solved at home. On a further note once I updated my opentk.dll.config on my home machine the examples work just fine. This is leading me to believe that it is some sort of 10.4 issue. I will find out tomorrow.
Also I am still interested in getting a native mac version going.
Re: Can't build on OS X
So at work I tested using the debug dll and app and it doesn't really give any new information.
Given that mono doesn't really have a debugger it's quite hard to trace down what exactly is null. I really think that focusing on a native version is a much better alternative then trying to fix this error.