Mage.exe独立使用

时间:2013-03-06 09:00:29

标签: clickonce mage octopus-deploy

我正在开发一个示例,我使用Octopus Deploy在安装时配置和创建clickonce包,并且我在'生产'机器上使用mage.exe时遇到一些问题。我已经包含了mage.exe和mageui.exe,但是在使用mage.exe时出现以下错误

  

错误

Unhandled Exception: System.TypeLoadException: Could not load type 'System.Reflection.AssemblySignatureKeyAttribute' from assembly 'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.
2013-03-05 20:28:12 INFO     ERROR:    at System.ModuleHandle.ResolveMethod(RuntimeModule module, Int32 methodToken, IntPtr* typeInstArgs, Int32 typeInstCount, IntPtr* methodInstArgs, Int32 methodInstCount)
2013-03-05 20:28:12 INFO     ERROR:    at System.ModuleHandle.ResolveMethodHandleInternalCore(RuntimeModule module, Int32 methodToken, IntPtr[] typeInstantiationContext, Int32 typeInstCount, IntPtr[] methodInstantiationContext, Int32 methodInstCount)
2013-03-05 20:28:12 INFO     ERROR:    at System.ModuleHandle.ResolveMethodHandleInternal(RuntimeModule module, Int32 methodToken, RuntimeTypeHandle[] typeInstantiationContext, RuntimeTypeHandle[] methodInstantiationContext)
2013-03-05 20:28:12 INFO     ERROR:    at System.Reflection.CustomAttributeData..ctor(RuntimeModule scope, CustomAttributeRecord caRecord)
2013-03-05 20:28:12 INFO     ERROR:    at System.Reflection.CustomAttributeData.GetCustomAttributes(RuntimeModule module, Int32 tkTarget)
2013-03-05 20:28:12 INFO     ERROR:    at System.Reflection.CustomAttributeData.GetCustomAttributesInternal(RuntimeAssembly target)
2013-03-05 20:28:12 INFO     ERROR:    at System.Reflection.RuntimeAssembly.GetCustomAttributesData()
2013-03-05 20:28:12 INFO     ERROR:    at System.Reflection.CustomAttributeData.GetCustomAttributes(Assembly target)
2013-03-05 20:28:12 INFO     ERROR:    at System.Resources.ManifestBasedResourceGroveler.GetNeutralResourcesLanguage(Assembly a, UltimateResourceFallbackLocation& fallbackLocation)
2013-03-05 20:28:12 INFO     ERROR:    at System.Resources.ResourceManager.CommonSatelliteAssemblyInit()
2013-03-05 20:28:12 INFO     ERROR:    at System.Resources.ResourceManager..ctor(Type resourceSource)
2013-03-05 20:28:12 INFO     ERROR:    at MageCLI.Application.get_Resources()
2013-03-05 20:28:12 INFO     ERROR:    at MageCLI.Application.InternalError(String message, String stackTrace)
2013-03-05 20:28:12 INFO     ERROR:    at MageCLI.Application.Main(String[] args)

所以我的问题是在不安装.NET Framework SDK的情况下运行mage.exe需要哪些依赖项?

1 个答案:

答案 0 :(得分:2)

我设法使用FUSLOGVW.exe找出问题。我已经从.NET Framework 4.5复制了mage.exe和mageui.exe,默认情况下没有安装在Windows 2008 Server中。从.NET 4.0中取出法师解决了这个问题。