我有一个Xamarin iOS应用程序,当我在“调试”配置下启动该应用程序时,它可以在我的设备上运行得很好。现在,我创建了一个名为"Staging“的新配置,并将info.plist和entitlements.plist复制为info-Staging.plist和entitlements-Staging.plist,并希望在"Staging”配置中调试时使用它们。它们之间唯一的区别是不同的标识符(com.blah.blah)。我按如下方式编辑了.csproj:
<ItemGroup>
<None Include="packages.config" />
<None Include="Entitlements.plist" Condition="'$(Configuration)' != 'Staging'" />
<None Include="Info.plist" Condition="'$(Configuration)' != 'Staging'" />
<None Include="Info-Staging.plist" Condition="'$(Configuration)' == 'Staging'">
<LogicalName>Info.plist</LogicalName>
</None>
<None Include="Entitlements-Staging.plist" Condition="'$(Configuration)' == 'Staging'">
<LogicalName>Entitlements.plist</LogicalName>
</None>
</ItemGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Staging|AnyCPU' ">
<Optimize>false</Optimize>
<OutputPath>bin\Staging</OutputPath>
<DefineConstants></DefineConstants>
<WarningLevel>4</WarningLevel>
<CodesignKey>iPhone Developer</CodesignKey>
<CodesignEntitlements>Entitlements-Staging.plist</CodesignEntitlements>
<MtouchNoSymbolStrip>true</MtouchNoSymbolStrip>
<MtouchLink>SdkOnly</MtouchLink>
<MtouchHttpClientHandler>HttpClientHandler</MtouchHttpClientHandler>
<AssemblyName>MyApp.iOS</AssemblyName>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<DefineConstants>DEBUG;ENABLE_TEST_CLOUD;</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<ConsolePause>false</ConsolePause>
<DeviceSpecificBuild>true</DeviceSpecificBuild>
<MtouchDebug>true</MtouchDebug>
<MtouchFastDev>true</MtouchFastDev>
<MtouchFloat32>true</MtouchFloat32>
<MtouchArch>ARMv7, ARM64</MtouchArch>
<MtouchTlsProvider>Default</MtouchTlsProvider>
<PlatformTarget>x86</PlatformTarget>
</PropertyGroup>但当我试图在我的设备上构建这个应用程序时,我得到了这样的消息:
error MT1108: Could not find developer tools for this 10.2.1 (14D27) device. Please ensure you are using a compatible Xcode version and then connect this device to Xcode to install the development support files.
发布于 2017-09-07 14:13:06
这个问题很简单,实际上只要检查一下你的MAC机器上安装的Xcode版本和你系统中的Xamarin版本是否匹配即可。为此,您需要在Visual studio中检入Tools/Options/Xamarin
https://stackoverflow.com/questions/46081658
复制相似问题