MonoMac包装错误

时间:2013-07-23 16:36:14

标签: macos mono monomac

我正在使用MonoMac 3.0.6和Mono Runtime 2.10.12,我用它创建了一个应用程序。所以,我想用它打包MonoRuntime:转到它的选项并选择链接“Framework SDKs only”。当我构建它时,我收到此错误:

构建:ThisSimpleApp(Debug | x86) 执行主编译...... /Library/Frameworks/Mono.framework/Versions/2.10.12/bin/dmcs / noconfig“/out:/Users/shreyansh/Projects/ThisSimpleApp/ThisSimpleApp/bin/Debug/ThisSimpleApp.exe”“/ r:/ Library / Frameworks / Mono.framework / Versions / 2.10.12 / lib / mono / 4.0 / System.dll“”/ r:/Library/Frameworks/Mono.framework/Versions/2.10.12/lib/mono/4.0/System.Xml .dll“”/ rl/Library/Frameworks/Mono.framework/Versions/2.10.12/lib/mono/4.0/System.Core.dll“”/ r:/Library/Frameworks/Mono.framework/Versions/2.10 .12 / lib / mono / 4.0 / System.Xml.Linq.dll“”/ r:/Library/Frameworks/Mono.framework/Versions/2.10.12/lib/mono/4.0/System.Drawing.dll“”/ r:/Applications/MonoDevelop.app/Contents/MacOS/lib/monodevelop/AddIns/MonoDevelop.MonoMac/MonoMac.dll“/ nologo / warn:4 / debug:full / optimize- / codepage:utf8 / platform:x86”/ define:DEBUG“/ t:exe”/Users/shreyansh/Projects/ThisSimpleApp/ThisSimpleApp/MainWindow.cs""/Users/shreyansh/Projects/ThisSimpleApp/ThisSimpleApp/MainWindowController.cs“”/ Users / shreyansh / Projects / ThisSimpleApp / ThisSimpleApp /的MainWin dow.designer.cs“”/ Users / shreyansh / Project / ThisSimpleApp/ThisSimpleApp/Main.cs“”/ Users / shreyansh /Projects / ThisSimpleApp/ThisSimpleApp/AppDelegate.cs“”/ Users / shreyansh / Projects / ThisSimpleApp / ThisSimpleApp / AppDelegate.designer.cs” 构建完成 - 0个错误,0个警告

更新应用程序清单

将Mono Runtime合并到应用程序包中 /Applications/MonoDevelop.app/Contents/MacOS/lib/monodevelop/AddIns/MonoDevelop.MonoMac/mmp -linksdkonly“-minos = 10.6”-o“/ Users / shreyansh / Projects / ThisSimpleApp / ThisSimpleApp / bin / Debug”-n “ThisSimpleApp”-a“/Library/Frameworks/Mono.framework/Versions/2.10.12/lib/mono/4.0/System.dll”-a“/Library/Frameworks/Mono.framework/Versions/2.10.12/lib /mono/4.0/System.Xml.dll“-a”/Library/Frameworks/Mono.framework/Versions/2.10.12/lib/mono/4.0/System.Core.dll“-a”/ Library / Frameworks / Mono .framework / Versions / 2.10.12 / lib / mono / 4.0 / System.Xml.Linq.dll“-a”/Library/Frameworks/Mono.framework/Versions/2.10.12/lib/mono/4.0/System.Drawing .dll“-a”/Applications/MonoDevelop.app/Contents/MacOS/lib/monodevelop/AddIns/MonoDevelop.MonoMac/MonoMac.dll“”/用户/ shreyansh /Projects /ThisSimpleApp/ThisSimpleApp/bin/Debug/ThisSimpleApp.exe “

未处理的异常:System.TypeInitializationException:MonoMac.Bundler.Driver的类型初始化程序抛出异常---> System.ComponentModel.Win32Exception:ApplicationName ='pkg-config',CommandLine =' - variable = prefix mono-2',CurrentDirectory =''   在System.Diagnostics.Process.Start_noshell(System.Diagnostics.ProcessStartInfo startInfo,System.Diagnostics.Process进程)[0x00000] in:0   在System.Diagnostics.Process.Start_common(System.Diagnostics.ProcessStartInfo startInfo,System.Diagnostics.Process进程)[0x00000] in:0   在System.Diagnostics.Process.Start(System.Diagnostics.ProcessStartInfo startInfo)[0x00000] in:0   在MonoMac.Bundler.Driver.RunCommand(System.String path,System.String args,System.String [] env,System.String& output)[0x00000] in:0   在MonoMac.Bundler.Driver..cctor()[0x00000]中:0   ---内部异常堆栈跟踪结束--- [错误]致命的未处理的异常:System.TypeInitializationException:MonoMac.Bundler.Driver的类型初始化程序抛出异常---> System.ComponentModel.Win32Exception:ApplicationName ='pkg-config',CommandLine =' - variable = prefix mono-2',CurrentDirectory =''   在System.Diagnostics.Process.Start_noshell(System.Diagnostics.ProcessStartInfo startInfo,System.Diagnostics.Process进程)[0x00000] in:0   在System.Diagnostics.Process.Start_common(System.Diagnostics.ProcessStartInfo startInfo,System.Diagnostics.Process进程)[0x00000] in:0   在System.Diagnostics.Process.Start(System.Diagnostics.ProcessStartInfo startInfo)[0x00000] in:0   在MonoMac.Bundler.Driver.RunCommand(System.String path,System.String args,System.String [] env,System.String& output)[0x00000] in:0   在MonoMac.Bundler.Driver..cctor()[0x00000]中:0   ---内部异常堆栈跟踪结束--- mmp退出代码1

----------------------完成----------------------

构建:1个错误,0个警告

然后退出......

我想问一下是否有人可以帮助我,因为我一直在努力解决这个问题一个月。

1 个答案:

答案 0 :(得分:0)

由于异常状态无法找到pkg-config工具。

以前在Mono的旧版本中将其复制到/usr/bin但与其他软件包(例如macport)冲突,因此不再复制。

解决此问题的一种方法是在/usr/bin/pkg-config

下创建一个符号链接(从pkg-config)到Mono附带的/Library/Frameworks/Mono.framework/...工具