使用 Windows 服务器上的构建服务和 F# 运行时 2.0 构建包含 F# 项目的解决方案
我正在尝试使 TFS 2010 构建服务(在 Windows Server SP2 上)工作。我想要构建的解决方案包括许多 C# 项目和一个 F# 项目。在我自己的 PC 上,我安装了带有 F# 的 Microsoft Visual Studio 2010(版本 10.0.40219.1 SP1Rel、Microsoft .NET Framework、版本 4.0.30319 SP1Rel),我可以构建解决方案。 当我创建 TFS 构建定义(通过团队资源管理器 -> 右键单击“所有构建定义”->“新构建定义”)时,我只选择了默认内容并在服务器共享上指定了一个放置文件夹。
在服务器上,我已从 安装了 VS 2010 F# Runtime 2.0 http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=13450
将构建排队时,它会运行一段时间然后输出以下错误: C:\Builds\1\Processing\SM0021\Sources\Processing\Libraries\Syntune.Math\Release\Syntune.Math.FSharp\Syntune.Math.FSharp.fsproj (39): 导入的项目“C:\Program Files\未找到 Microsoft F#\v4.0\Microsoft.FSharp.Targets”。确认声明中的路径正确,并且该文件存在于磁盘上。
我不知道构建定义是否需要指定构建服务应如何找到 F# 运行时、是否需要安装其他 F# 包/发行版或者是否必须执行其他操作。或者如果这根本无法通过 TFS 构建服务来完成。
这与 F# 运行时有关还是我的构建定义有问题? 我可以将文件从 PC 复制到服务器并将其注册到 GAC 中吗?
I am trying to make work the TFS 2010 build service (on a Windows Server SP2). The solution I want to get built includes many C# projects and one F# project. On my own PC, where I have Microsoft Visual Studio 2010 (Version 10.0.40219.1 SP1Rel, Microsoft .NET Framework, Version 4.0.30319 SP1Rel) installed with F#, I can build the solution.
When I created my TFS Build definition (Via Team Explorer -> right click 'All Build Definitions' -> 'New Build Definition') I only selected default stuff and specified a drop folder on a server share.
On the server I have installed the VS 2010 F# Runtime 2.0 from http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=13450
When queuing the build it runs for a while and then outputs the following error:
C:\Builds\1\Processing\SM0021\Sources\Processing\Libraries\Syntune.Math\Release\Syntune.Math.FSharp\Syntune.Math.FSharp.fsproj (39): The imported project "C:\Program Files\Microsoft F#\v4.0\Microsoft.FSharp.Targets" was not found. Confirm that the path in the declaration is correct, and that the file exists on disk.
I do not know whether the build definition needs to specify how the Build Service should find the F# runtime, if I need to install some other F# package/distribution or if I must do something else. Or if this simply cannot be accomplishe dby a TFS build service.
Is this related to the F# runtime or is it something wrong with my build definition?
Can I copy files from my PC to the server and register them in the GAC?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
“F# 运行时”不包含编译器(也不包含 MS BUILD 的
targets
文件)。如果您可以做到这一点,那么最简单的选择是在构建计算机上安装带有 F# 的 Visual Studio。如果这不是一个选项,您可以尝试安装独立版本F#,其中包含编译器。但是,我不确定 TFS 构建服务是否会自动找到此安装。
The "F# runtime" does not include a compiler (and it also doesn't include
targets
file for MS BUILD).If you can do that, then the easiest option would be to install Visual Studio with F# on the build machine. If that's not an option, you can try installing standalone version of F#, which includes a compiler. However, I'm not sure if the TFS build service will find this installation automatically.