[转]MSBuild Target Framework and Target Platform

本文转自;https://msdn.microsoft.com/en-us/library/hh264221.aspx


A project can be built to run on a target framework, which is a particular version of the .NET Framework, and a target platform, which is a particular software architecture.  For example, you can target an application to run on the .NET Framework 2.0 on a 32-bit platform that is compatible with the 802x86 processor family (“x86”). The combination of target framework and target platform is known as the target context.

Target Framework and Profile


A target framework is the particular version of the .NET Framework that your project is built to run on. Specification of a target framework is required because it enables compiler features and assembly references that are exclusive to that version of the framework.

Currently, the following versions of the .NET Framework are available for use:

  • The .NET Framework 2.0 (included in Visual Studio 2005)
  • The .NET Framework 3.0 (included in Windows Vista)
  • The .NET Framework 3.5 (included in Visual Studio 2008)
  • The .NET Framework 4 (included in Visual Studio 2010)
  • The .NET Framework 4.5 (included in Visual Studio 2012)
  • The .NET Framework 4.5.1 (included in Visual Studio 2013)
  • The .NET Framework 4.5.2
  • The .NET Framework 4.6 (included in Visual Studio 2015)

The versions of the .NET Framework differ from one another in the list of assemblies that each makes available to reference. For example, you cannot build Windows Presentation Foundation (WPF) applications unless your project targets the .NET Framework version 3.0 or above.

The target framework is specified in the TargetFrameworkVersion property in the project file. You can change the target framework for a project by using the project property pages in the Visual Studio integrated development environment (IDE). For more information, see How to: Target a Version of the .NET Framework. The available values for TargetFrameworkVersion are v2.0, v3.0, v3.5, v4.0, v4.5, v4.5.1, v4.5.2, and v4.6.

Copy

<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>

A target profile is a subset of a target framework. For example, the .NET Framework 4 Client profile does not include references to the MSBuild assemblies.

The target profile is specified in the TargetFrameworkProfile property in a project file. You can change the target profile by using the target-framework control in the project property pages in the IDE. For more information, see How to: Target a Version of the .NET Framework.

Copy

<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<TargetFrameworkProfile>Client</TargetFrameworkProfile>

Target Platform


A platform is combination of hardware and software that defines a particular runtime environment. For example,

  • x86 designates a 32-bit Windows operating system that is running on an Intel 80x86 processor or its equivalent.
  • Xbox designates the Microsoft Xbox 360 platform.

A target platform is the particular platform that your project is built to run on. The target platform is specified in the Platform build property in a project file. You can change the target platform by using the project property pages or the Configuration Manager in the IDE.

Copy

<PropertyGroup>
   <Platform>x86</Platform>
</PropertyGroup>

A target configuration is a subset of a target platform. For example, the x86``Debug configuration does not include most code optimizations. The target configuration is specified in the Configuration build property in a project file. You can change the target configuration by using the project property pages or the Configuration Manager.

Copy

<PropertyGroup>
   <Platform>x86</Platform>
   <Configuration>Debug</Configuration>
<PropertyGroup>  

http://stackoverflow.com/questions/328017/path-to-msbuild

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSBuild\ToolsVersions\2.0

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSBuild\ToolsVersions\3.5

时间: 2024-08-03 13:24:45

[转]MSBuild Target Framework and Target Platform的相关文章

ASP.NTE 5 Target framework dnx451 and dnxcore50(转)原文:http://www.cnblogs.com/xishuai/p/aspnet5-target-framework-dnx451-and-dnxcore50.html

中文不知如何定义标题,所以干脆就直接贴出关键字,在 ASP.NTE 5 项目的 project.json 配置文件中,会有这样的定义: "frameworks": { "dnx451": { }, "dnxcore50": { } } frameworks 配置的是什么东西?dnx451 和 dnxcore50 又是什么鬼? 可能了解过 ASP.NTE 5 的童鞋会知道,但如果再深入一些,就必须搞清楚 ASP.NTE 5 相关内容的来龙去脉,幸好

Vs2013 坑爹的Target framework问题

之前的一个项目是使用Vs2008来开发的,因为这段时间家里有事情所以只能跟经理协商在家里来做此项目,因为家里的VS是2013的所以在迁移时没有什么问题 但今天我更改一个类库的文件后重新生成解决方案结果却出现了以下问题: Error 101 The type or namespace name '****' could not be found (are you missing a using directive or an assembly reference?) 意思是说该类型或命名空间没有找

target=_parent与target=_top的区别与用途

在手动改HTML代码时经常会用到target参数,常用的有两个target=_blank 和target=_self意思为:target=_blank表示在新窗口中打开该链接:target=_self表示相同框架,即在当前窗口(或当前选项卡)中打开该链接还有两个不常用的:target=_parent,将链接的文件载入含有该链接框架的父框架集或父窗口中.如果含有该链接的框架不是嵌套的,则在浏览器全屏窗口中载入链接的文件,就象_self参数一样. target=_top,在当前的整个浏览器窗口中打开

【原创】什么是目标框架别名(What are the Target Framework Monikers (TFMs))?

我们现在的.NET Core 1.0应用(ASP.NET Core 1.0应用或控制台应用)有了新的被运行在不同框架上的可能性:①运行在.NET Core平台上 ②运行在传统的.NET Framework 4.5.x 上(对很多企业级应用来说仍然是一个至关重要的框架).相对传统的.NET Framework 4.5.x(体积大.臃肿但全面) ,.NET Core平台栈和类库变得更加小和轻量化了. 在project.json文件中指定框架平台

HTML &lt;base&gt; 标签的 target 属性 —— &lt;base target=&quot;_blank&quot; /&gt;

为页面上所有链接规定默认目标: <head> <base target="_blank" /> </head> <body> <a href="http://www.w3school.com.cn">W3School</a> </body> 定义和用法 target 属性规定在何处打开页面上的所有链接. 语法 <base target="value">

MSBuild 命令行参考

MSBuild 命令行参考 Visual Studio 2013 其他版本 使用 MSBuild.exe 生成项目或解决方案文件时,可以包含几个开关来指定过程的各个方面. MSBuild.exe [Switches] [ProjectFile] 参数 参数 描述 ProjectFile 在指定项目文件中生成目标. 如果不指定项目文件,则 MSBuild 会在当前工作目录中搜索以“proj”结尾的文件扩展名并使用该文件. 还可以为此参数指定 Visual Studio 解决方案文件. 开关 开关

〖Android〗Android源代码所有目录生成的Target(编译生成文件反查)

=> build/tools/zipalign: out/host/linux-x86/bin/zipalign (host) => build/tools/atree: out/host/linux-x86/bin/atree (host) => build/tools: => build/tools/bin2asm: out/host/linux-x86/bin/icudata (host) => build/tools/check_prereq: system/bin/

三种iSCSI target管理工具的比较

1. iSCSI简介 从协议层次的角度看,通常所说的SCSI通常是指一组包含块命令.控制器管理.系统命令和enclosure服务等内容的协议规范,对应于回话层:而其下的物理通道和链接方式就对应在数据链路层,SCSI命令可以通过串口.Fibre Channel.SAS.infiniband.Internet.USB.PCIE等进行传输.iSCSI就是一种把异地存储资源通过TCP/IP网络映射到本地逻辑存储设备的SCSI实现.不同于NFS向用户提供按文件为单位访问远程存储的方式,它向用户提供了以块方

iscsi介绍及iscsi target配置

iSCSI 主要是透过 TCP/IP 的技术,将储存设备端透过 iSCSI target (iSCSI 目标) 功能,做成可以提供磁盘的服务器端,再透过 iSCSI initiator (iSCSI 初始化用户) 功能,做成能够挂载使用 iSCSI target 的客户端,如此便能透过 iSCSI 协议来进行磁盘的应用了. 也就是说,iSCSI 这个架构主要将储存装置与使用的主机分为两个部分,分别是: iSCSI target:就是储存设备端,存放磁盘或 RAID 的设备,目前也能够将 Linu