【发布时间】:2022-08-14 02:24:08
【问题描述】:
我有VS Mac 2022 和xamarin.forms 项目,android 项目设置为启动。
当我想运行app 时,没有Run 按钮,只有锤子图标出现在左上角的VS 中。我不确定这里出了什么问题。
这是安卓项目androidconfiguration file。
<?xml version=\"1.0\" encoding=\"utf-8\"?>
<Project DefaultTargets=\"Build\" ToolsVersion=\"4.0\" xmlns=\"http://schemas.microsoft.com/developer/msbuild/2003\">
<PropertyGroup>
<Configuration Condition=\" \'$(Configuration)\' == \'\' \">Debug</Configuration>
<Platform Condition=\" \'$(Platform)\' == \'\' \">AnyCPU</Platform>
<OutputType>Library</OutputType>
<RootNamespace>s_Order.Droid</RootNamespace>
<AndroidApplication>True</AndroidApplication>
<TargetFrameworkVersion>v11.0</TargetFrameworkVersion>
</PropertyGroup>
<PropertyGroup Condition=\" \'$(Configuration)|$(Platform)\' == \'Debug|AnyCPU\' \">
<DebugSymbols>true</DebugSymbols>
<DebugType>portable</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\\Debug</OutputPath>
<DefineConstants>DEBUG;</DefineConstants>
<AndroidLinkMode>None</AndroidLinkMode>
</PropertyGroup>
<PropertyGroup Condition=\" \'$(Configuration)|$(Platform)\' == \'Release|AnyCPU\' \">
<DebugSymbols>true</DebugSymbols>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\\Release</OutputPath>
<AndroidManagedSymbols>true</AndroidManagedSymbols>
<AndroidUseSharedRuntime>false</AndroidUseSharedRuntime>
</PropertyGroup>
<PropertyGroup Condition=\" \'$(Configuration)|$(Platform)\' == \'Debug|AnyCPU\' \">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\\Debug</OutputPath>
<DefineConstants>DEBUG;</DefineConstants>
<DebugType>portable</DebugType>
<PlatformTarget>x86</PlatformTarget>
<GenerateSerializationAssemblies>Off</GenerateSerializationAssemblies>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
<IntermediateOutputPath></IntermediateOutputPath>
<ConsolePause>true</ConsolePause>
<ExternalConsole>false</ExternalConsole>
<Commandlineparameters></Commandlineparameters>
<RunWithWarnings>true</RunWithWarnings>
<AndroidManagedSymbols>false</AndroidManagedSymbols>
<MandroidExtraArgs></MandroidExtraArgs>
<AndroidCreatePackagePerAbi>false</AndroidCreatePackagePerAbi>
<BundleAssemblies></BundleAssemblies>
<AndroidEnableProfiledAot>false</AndroidEnableProfiledAot>
<EnableLLVM>false</EnableLLVM>
</PropertyGroup>
<PropertyGroup Condition=\" \'$(Configuration)|$(Platform)\' == \'Release|AnyCPU\' \">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\\Release</OutputPath>
<Optimize>true</Optimize>
<DebugType>pdbonly</DebugType>
<PlatformTarget>x86</PlatformTarget>
<GenerateSerializationAssemblies>Off</GenerateSerializationAssemblies>
<ExternalConsole>false</ExternalConsole>
<AotAssemblies></AotAssemblies>
<AndroidEnableProfiledAot>false</AndroidEnableProfiledAot>
<EnableLLVM>false</EnableLLVM>
<EmbedAssembliesIntoApk></EmbedAssembliesIntoApk>
</PropertyGroup>
</Project>
请检查下面的截图
以下是android 的编译器选项
我怎样才能解决这个问题 ?
-
你见过这个吗? stackoverflow.com/questions/66939015/… 他们似乎也只有锤子图标。至少看起来很相似。
-
您是否按照 VS 2022 mac 说明安装 android?
标签: xamarin xamarin.forms visual-studio-2022 visual-studio-mac