使用VS2010构建精简框架应用程序(不使用VS2005) [英] Building Compact Framework applications with VS2010 (without VS2005)

查看:103
本文介绍了使用VS2010构建精简框架应用程序(不使用VS2005)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用VS2010执行.NET CF 2.0构建。我知道不正常支持它,但是我已经看到了以下答案:(



我不认为提出的解决方案对我来说是可行的。我没有VS2008。我没有VS2005。我只有VS2010,没有其他产品的可安装媒体。



我也尝试了管理员安装( msiexec / a ),但是生成的目录结构不包含像Microsoft.CompactFramework.Common.targets之类的任何文件。??



Q1
我是否可以安装WM6标准SDK?



第二季度:有人知道它用来确定我是否有适当的先决条件的reg键吗?
如果我只是弄弄注册表,这会起作用吗?



第三季度:我的假设是否正确?真的,我想要Microsoft.CompactFramework.Common.targets文件及其朋友。我在哪里可以得到? (我没有现成的VS2008计算机可供吸纳)



Q4 :我能想到的另一种方法是获得一个VS2008的评估版,安装将其导入到VM中,然后在那里安装WM6 Std SDK,然后从中获取Microsoft.CompactFramework.Common.targets文件。很长的路要走。这行得通吗,值得吗?






ANSWER



答案。



可以使用VS2010构建CF应用,如乔尔·峡湾的博客文章。为了做到这一点,您需要先决条件。



我相信获取所需文件的唯一官方方法,包括Microsoft.CompactFramework.Common.targets,Microsoft.CompactFramework.CSharp.targets ,Microsoft.CompactFramework.VisualBasic.targets和Microsoft.CompactFramework.Build.Tasks.dll是要安装Visual Studio的相关版本。这些文件都是特定于版本的,因此,要获取用于.NET CF 2.0构建的文件,您需要安装VS2005,而对于.NET CF 3.5,则需要安装VS2008。安装VS2010不会给您任何帮助。它可以使用评估版的工具。无论如何,它对我有用。



如果您愿意自定义,则可以简单地将这些文件从VS2005或VS2008(或两者)的有效安装复制到适当的.NET目录中。类似于 C:\Windows\Microsoft.NET\Framework\v2.0.50727 (适当更改版本)。克里斯·塔克(Chris Tacke)有用地发布了指向所需文件 。我不知道复制这些文件是否违反了VS20的许可? ,我不是许可专家。



据我所知,您无法从Windows Mobile SDK获取这些文件。即使这样,您仍可能希望使用特定于版本的移动SDK来获得仿真器和外观等。



这是基本的构建功能。它可以工作,但不能为您提供设计人员支持,调试功能,内置项目模板等。对于任何希望在.NET CF上进行正向开发的人,我的建议是使用针对这些任务的工具-VS2005或VS2008。



感谢 Chris Tacke 发布了文件链接。

解决方案

不确定是否有帮助,但是来自VS2008的CF目标文件可以在此处找到。让我们知道您是否取得任何进展。


I want to perform a .NET CF 2.0 build using VS2010. I know it's not supported "normnally," but I've seen this answer: ( .NET Compact Framework with Visual Studio 2010? ) ...and I want to use that approach.

The blog post cited there says I need to modify the .csproj files for the .NET CF projects, to point to a particular Microsoft.CompactFramework.Common.targets . But I don't have that file.

I figured I needed to install the Windows Mobile 6 Standard SDK to get it.
I tried installing it and get this:

I have seen this question:
Windows Mobile 6 Standard SDK Refresh install issue on Visual Studio 2010 Professional Beta 2

I don't think the solution proposed there is workable for me. I do not have VS2008. I do not have VS2005. I have only VS2010, and I have no installable media for those other products.

I have also tried the administrative install (msiexec /a), but the resulting directory structure doesn't contain any files like Microsoft.CompactFramework.Common.targets .??

Q1: Is there a way for me to install WM6 Standard SDK?

Q2: Anyone know the reg key that it looks for to determine if I have the appropriate pre-reqs? Is this going to work if I just fiddle with my registry?

Q3: Is my assumption wrong? Really I want the Microsoft.CompactFramework.Common.targets file and its friends. Where can I get this? (I have no existing VS2008 machine to suck from)

Q4: Another approach I can think of is getting an eval version of VS2008, installing that into a VM, then installing the WM6 Std SDK there, then grabbing the Microsoft.CompactFramework.Common.targets file from that. Long way round. Is this gonna work and is it worth the trouble?


ANSWER

Here's the answer.

It is possible to build CF apps with VS2010, as outlined in Joel Fjorden's blog post. There are pre-requisites you need, in order to make this happen.

I believe the only official way to get the required files, including Microsoft.CompactFramework.Common.targets , Microsoft.CompactFramework.CSharp.targets , Microsoft.CompactFramework.VisualBasic.targets and Microsoft.CompactFramework.Build.Tasks.dll , is to install the related version of Visual Studio. These files are all version-specific, so to get the files for building for .NET CF 2.0, you need to install VS2005, and for .NET CF 3.5 you need to install VS2008. Installing VS2010 gives you neither. It works to use eval versions of the tools. It worked for me anyway.

If you are willing to go custom, you can simply copy these files from a working installation of VS2005 or VS2008 (or both), into the appropriate .NET directory, usually something like C:\Windows\Microsoft.NET\Framework\v2.0.50727 (change the version as appropriate). Chris Tacke has helpfully posted a link to the files you need. I don't know if copying these files violates the license for VS20?? , I am not a licensing expert.

You cannot get these files from the Windows Mobile SDK, as far as I can tell. Even so, you might still want a version-specific mobile SDK to get the emulators and skins and so on.

This is a basic "build" capability. It works but it doesn't give you designer support, debugging capability, built-in project templates, and so on. My advice to anyone who wants to do forward development on .NET CF is to use the tools that are geared toward those tasks - VS2005 or VS2008.

Thanks to Chris Tacke for posting a link for the files.

解决方案

Not sure if it's any help, but the CF targets files from VS2008 can be found here. Let us know if you make any progress.

这篇关于使用VS2010构建精简框架应用程序(不使用VS2005)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆