1

我有一个应用程序,我在过去 2 年从 MonoDevelop 部署。该应用程序有 2 个具有不同捆绑 ID 的版本,因此有 2 个配置文件。以前我已经切换了捆绑 ID,部署了,一切都很好。

在 MonoDevelop/MonoTouch (3.0.4.7/6.0.2) 的最新升级之后,对于使用 LLVM 构建且未启用调试的临时构建,我无法再使用它了。由于开发时间长,不知道是Monodevelop/MonoTouch变化还是我的项目变化引起的。

奇怪的是,如果我检查发布版本的“启用调试”,一切都部署得很好。然后它会记录一条警告说“冲突--debug 和--llvm 选项。软调试被禁用。” 这似乎表明启用调试选项无效?

所以问题是:如果我在发布版本上启用调试,为什么应用程序只能正确部署到设备?

就第 3 方内容而言,唯一的变化是我们从此处添加了新的 Admob 绑定: https ://github.com/dalexsoto/AlexTouch.GoogleAdMobAds ,但据我所知,这些不需要包含任何特殊参数在发布版本中。

我在没有调试的情况下压缩了一个分发版本并发送给 Apple 以供批准,但我认为它与我的临时版本存在相同的问题,因此将被拒绝。希望一些 Mono 大师对此有所了解!

这是完整的日志,包括安装和首次启动:

    Sep 30 23:58:23 Christer-sin-iPhone librariand[5904] <Error>: client process 619 does not have a valid com.apple.developer.ubiquity-container-identifiers entitlement
    Sep 30 23:58:24 Christer-sin-iPhone ubd[5905] <Notice>:
    Sep 30 23:58:27 Christer-sin-iPhone librariand[5904] <Notice>: MMe quota status changed: under quota
    Sep 30 23:58:28 Christer-sin-iPhone installd[5365] <Error>: 0x2ffa2000 handle_uninstall: Uninstall requested by SpringBoard
    Sep 30 23:58:28 Christer-sin-iPhone installd[5365] <Error>: 0x2ffa2000 MobileInstallationUninstall_Server: Uninstalling com.myapp
    Sep 30 23:58:29 Christer-sin-iPhone ubd[5905] <Error>: Sep 30 23:58:29  SecTrustEvaluate  [leaf AnchorTrusted]
    Sep 30 23:58:30 Christer-sin-iPhone installd[5365] <Error>: 0x30b000 filter_attributes: Info.plist keys requested via MobileInstallationLookup/Browse in client Xcode (via mobile_installation_proxy) were not found in MobileInstallation's cache. Please file a bug requesting that these keys be added: <CFBasicHash 0x1e5851c0 [0x3b76a100]>{type = mutable set, count = 18,
    entries =>
    0 : <CFString 0x3b7569f4 [0x3b76a100]>{contents = "CFBundlePackageType"}
    1 : <CFString 0x1e57a800 [0x3b76a100]>{contents = "BuildMachineOSBuild"}
    2 : <CFString 0x3b757a44 [0x3b76a100]>{contents = "CFBundleResourceSpecification"}
    3 : <CFString 0x1e57b060 [0x3b76a100]>{contents = "DTPlatformBuild"}
    4 : <CFString 0x3b754794 [0x3b76a100]>{contents = "DTCompiler"}
    5 : <CFString 0x3b756564 [0x3b76a100]>{contents = "CFBundleSignature"}
    6 : <CFString 0x3b757224 [0x3b76a100]>{contents = "DTSDKName"}
    7 : <CFString 0x1e5782a0 [0x3b76a100]>{contents = "NSBundleResolvedPath"}
    8 : <CFString 0x3b753eb4 [0x3b76a100]>{contents = "UISupportedInterfaceOrientations"}
    10 : <CFString 0x3b75be84 [0x3b76a100]>{contents = "DTXcode"}
    13 : <CFString 0x3b75beb4 [0x3b76a100]>{contents = "CFBundleInfoDictionaryVersion"}
    16 : <CFString 0x3b759304 [0x3b76a100]>{contents = "CFBundleSupportedPlatforms"}
    17 : <CFString 0x1e57b0a0 [0x3b76a100]>{contents = "DTXcodeBuild"}
    18 : <CFString 0x1e5782c0 [0x3b76a100]>{contents = "UIStatusBarTintParameters"}
    19 : <CFString 0x3b757e54 [0x3b76a100]>{contents = "DTPlatformVersion"}
    20 : <CFString 0x3b75abf4 [0x3b76a100]>{contents = "DTPlatformName"}
    21 : <CFString 0x3b75bc84 [0x3b76a100]>{contents = "CFBundleDevelopmentRegion"}
    22 : <CFString 0x1e57b080 [0x3b76a100]>{contents = "DTSDKBuild"}
    }
    Sep 30 23:58:31 Christer-sin-iPhone mobile_installation_proxy[5908] <Error>: 0x3c390b88 MobileInstallationSlowLookupBreak: MobileInstallationBrowse was called without specifying an options dictionary containing kLookupReturnAttributesKey. This usage is inefficient and may cause performance problems. Break on MobileInstallationSlowLookupBreak to debug.
    Sep 30 23:58:31 Christer-sin-iPhone mobile_installation_proxy[5908] <Error>: 0x3c390b88 MobileInstallationSlowLookupBreak: Existing options dictionary: <CFBasicHash 0x1cd81790 [0x3b76a100]>{type = mutable dict, count = 1,
    entries =>
    0 : <CFString 0xa51a0 [0x3b76a100]>{contents = "RequestProxiedFor"} = <CFString 0x1cd818f0 [0x3b76a100]>{contents = "mtouch"}
    }
    Sep 30 23:58:38 Christer-sin-iPhone installd[5365] <Error>: 0x2ffa2000 handle_install: Install of "/var/mobile/Media/PublicStaging/NDC2010.app" requested by mobile_installation_proxy
    Sep 30 23:58:38 Christer-sin-iPhone installd[5365] <Error>: 0x2ffa2000 MobileInstallationInstall_Server: Installing app com.myapp
    Sep 30 23:58:39 Christer-sin-iPhone installd[5365] <Error>: Sep 30 23:58:39  SecTrustEvaluate  [leaf CriticalExtensions IssuerCommonName]
    Sep 30 23:58:41 Christer-sin-iPhone timed[5457] <Notice>: (Note ) CoreTime: Received timezone "Europe/Oslo" from "Location"
    Sep 30 23:58:41 Christer-sin-iPhone timed[5457] <Notice>: (Note ) CoreTime: Current mcc: '242' simulated:'0'.
    Sep 30 23:58:41 Christer-sin-iPhone timed[5457] <Notice>: (Note ) CoreTime: Not setting time zone to Europe/Oslo from Location
    Sep 30 23:58:42 Christer-sin-iPhone installd[5365] <Error>: 0x2ffa2000 MobileInstallationInstall_Server: Staging: 0.43s; Waiting: 0.00s; Installation: 4.41s; LS Sync: 0.12s; Overall: 4.96s
    Sep 30 23:58:42 Christer-sin-iPhone kernel[0] <Debug>: launchd[5911] Builtin profile: syncdefaultsd (sandbox)
    Sep 30 23:58:44 Christer-sin-iPhone installd[5365] <Error>: 0x2ffa2000 filter_attributes: Info.plist keys requested via MobileInstallationLookup/Browse in client Xcode (via mobile_installation_proxy) were not found in MobileInstallation's cache. Please file a bug requesting that these keys be added: <CFBasicHash 0x1e692820 [0x3b76a100]>{type = mutable set, count = 18,
    entries =>
    0 : <CFString 0x3b7569f4 [0x3b76a100]>{contents = "CFBundlePackageType"}
    1 : <CFString 0x1e58c4a0 [0x3b76a100]>{contents = "BuildMachineOSBuild"}
    2 : <CFString 0x3b757a44 [0x3b76a100]>{contents = "CFBundleResourceSpecification"}
    3 : <CFString 0x1e578200 [0x3b76a100]>{contents = "DTPlatformBuild"}
    4 : <CFString 0x3b754794 [0x3b76a100]>{contents = "DTCompiler"}
    5 : <CFString 0x3b756564 [0x3b76a100]>{contents = "CFBundleSignature"}
    6 : <CFString 0x3b757224 [0x3b76a100]>{contents = "DTSDKName"}
    7 : <CFString 0x1e5761a0 [0x3b76a100]>{contents = "NSBundleResolvedPath"}
    8 : <CFString 0x3b753eb4 [0x3b76a100]>{contents = "UISupportedInterfaceOrientations"}
    10 : <CFString 0x3b75be84 [0x3b76a100]>{contents = "DTXcode"}
    13 : <CFString 0x3b75beb4 [0x3b76a100]>{contents = "CFBundleInfoDictionaryVersion"}
    16 : <CFString 0x3b759304 [0x3b76a100]>{contents = "CFBundleSupportedPlatforms"}
    17 : <CFString 0x1e578240 [0x3b76a100]>{contents = "DTXcodeBuild"}
    18 : <CFString 0x1e57a970 [0x3b76a100]>{contents = "UIStatusBarTintParameters"}
    19 : <CFString 0x3b757e54 [0x3b76a100]>{contents = "DTPlatformVersion"}
    20 : <CFString 0x3b75abf4 [0x3b76a100]>{contents = "DTPlatformName"}
    21 : <CFString 0x3b75bc84 [0x3b76a100]>{contents = "CFBundleDevelopmentRegion"}
    22 : <CFString 0x1e578220 [0x3b76a100]>{contents = "DTSDKBuild"}
    }
    Sep 30 23:59:14 Christer-sin-iPhone NDC2010[5915] <Warning>: MonoTouch: Failed to open /private/var/mobile/Applications/38C5A938-BBDF-4BCD-AD25-1220671DDF63/NDC2010.app/MonoTouchDebugConfiguration.txt
    Sep 30 23:59:14 Christer-sin-iPhone kernel[0] <Debug>: launchd[5915] Builtin profile: container (sandbox)
    Sep 30 23:59:14 Christer-sin-iPhone kernel[0] <Debug>: launchd[5915] Container: /private/var/mobile/Applications/38C5A938-BBDF-4BCD-AD25-1220671DDF63 (sandbox)
    Sep 30 23:59:15 Christer-sin-iPhone NDC2010[5915] <Warning>: Application windows are expected to have a root view controller at the end of application launch
    Sep 30 23:59:15 Christer-sin-iPhone NDC2010[5915] <Critical>: Terminating runtime due to unhandled exception
    Sep 30 23:59:16 Christer-sin-iPhone ReportCrash[5917] <Notice>: Formulating crash report for process NDC2010[5915]
    Sep 30 23:59:16 Christer-sin-iPhone com.apple.launchd[1] (UIKitApplication:com.myapp[0x9886][5915]) <Warning>: (UIKitApplication:com.myapp[0x9886]) Job appears to have crashed: Abort trap: 6
    Sep 30 23:59:16 Christer-sin-iPhone backboardd[52] <Warning>: Application 'UIKitApplication:com.myapp[0x9886]' exited abnormally with signal 6: Abort trap: 6
    Sep 30 23:59:16 Christer-sin-iPhone ReportCrash[5917] <Error>: libMobileGestalt copySystemVersionDictionaryValue: Could not lookup ReleaseType from system version dictionary
4

1 回答 1

1

更新:

此问题已在最新的GoogleAdMobAds 绑定中得到修复


是的,您的问题是 Admob 绑定,在发布版本上检索大小时出现问题(谢谢 btw :)),这个类是问题所在 GADAdSizeCons,所以做这样的事情

var ad = new GADBannerView(GADAdSizeCons.Banner, new PointF(0,0))
{
    AdUnitID = "Your Id",
    RootViewController = this
};

只会崩溃release builds on real device,我今天在 Xamarin 上打开了一个关于这个的错误,所以我希望这会很快得到修复:)

所以这是解决方法

好的,所以在我们等待时,您需要手动创建GADSize struct,例如,如果您需要 iPhone 肖像横幅,您可以这样做

GADAdSize gsize = new GADAdSize()
{
    flags = 0,
    size = new System.Drawing.SizeF(320, 50)
};

var ad = new GADBannerView(gsize, new PointF(0,0))
{
    AdUnitID = "Your Id",
    RootViewController = this
}; 

这是值

横幅: 标志:0 尺寸:{Width= 320 , Height= 50 }

FullBanner: 标志:0 尺寸:{Width= 468 , Height= 60 }

排行榜: 标志:0 大小:{Width= 728 , Height= 90 }

MediumRectangle: 标志:0 尺寸:{Width= 300 , Height= 250 }

摩天大楼: 标志:0 尺寸:{Width= 120 , Height= 600 }

此解决方法的缺点是您只能创建上述尺寸,如果您尝试创建一个Custom Size,您将不会收到广告

希望这可以帮助

亚历克斯

于 2012-10-01T01:45:57.760 回答