构建失败,因为找不到 AL.exe

发布于 2024-08-07 00:32:22 字数 1025 浏览 3 评论 0原文

这是一个让我摸不着头脑的有趣问题。我有一个正在 TeamCity 中构建的项目。它一直工作正常,直到开发人员将资源文件添加到其中一个项目,其中包含另一种语言环境的一些字符串。他将 .resx 文件添加到默认文件旁边的 Properties 文件夹下。这是来自构建日志的错误消息:

C:\WINDOWS\Microsoft.NET\Framework\v3.5\Microsoft.Common.targets(2105, 9):
error MSB3091: Task failed because "AL.exe" was not found, or the correct
Microsoft Windows SDK is not installed. The task is looking for "AL.exe" in the "bin"
subdirectory beneath the location specified in the InstallationFolder value
of the registry key
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v6.0A.
You may be able to solve the problem by doing one of the following:
1) Install the Microsoft Windows SDK for Windows Server 2008 and .NET Framework 3.5.
2) Install Visual Studio 2008.
3) Manually set the above registry key to the correct location.
4) Pass the correct location into the "ToolPath" parameter of the task. 

这里有很多事情我无法解决。 - 为什么它可以找到默认 .resx 文件的 AL.exe 而不能找到这个新文件? - 当构建在 Server 2003 上运行时,为什么它要查找看起来特定于 Vista 的注册表项?

有什么想法吗?

Here's an interesting problem that really has me scratching my head. I have a project that's being built in TeamCity. It's been working fine until a developer added a resource file to one of the projects with some strings for another locale. He's added the .resx file under the Properties folder next to the default one. Here's the error message from the build log:

C:\WINDOWS\Microsoft.NET\Framework\v3.5\Microsoft.Common.targets(2105, 9):
error MSB3091: Task failed because "AL.exe" was not found, or the correct
Microsoft Windows SDK is not installed. The task is looking for "AL.exe" in the "bin"
subdirectory beneath the location specified in the InstallationFolder value
of the registry key
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v6.0A.
You may be able to solve the problem by doing one of the following:
1) Install the Microsoft Windows SDK for Windows Server 2008 and .NET Framework 3.5.
2) Install Visual Studio 2008.
3) Manually set the above registry key to the correct location.
4) Pass the correct location into the "ToolPath" parameter of the task. 

There are a number of things here that I can't work out.
- How come it can find AL.exe for the default .resx file but not for this new one?
- Why's it looking in a registry key that looks Vista-specific, when the build is running on Server 2003?

Any ideas?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

唠甜嗑 2024-08-14 00:32:22

通过安装适用于 Windows Server 2008 和 .NET Framework 3.5 SP1 的 Windows SDK 解决了问题。

我不明白 MSBuild 是如何与其工具不一致的,也许我永远不会发现原因,但安装该 SDK 解决了我的问题。

Problem solved by installing Windows SDK for Windows Server 2008 and .NET Framework 3.5 SP1.

I don't understand how MSBuild got out of step with its tools, perhaps I never will discover the reason, but installing that SDK fixed the problem for me.

把梦留给海 2024-08-14 00:32:22

检查是否使用了 x86 的 msbuild。 TeamCity 构建运行程序中应该有一个选项。

机器上安装了VS2008吗?

Check msbuild from x86 is used. There should be an option in TeamCity build runner.

Was VS2008 installed on the machine?

温柔戏命师 2024-08-14 00:32:22

确保服务器上已完整安装 Windows SDK。 AL.exe(汇编链接器)包含在 .NET SDK(不是运行时)中。

(我的TFS服务器上的ClickOnce也有同样的问题,但懒得修复)

Make sure the Windows SDK is completely installed on the server. AL.exe (Assembly Linker) is included with the .NET SDK (not the runtime).

(I have the same problem on my TFS server with ClickOnce, but too lazy to fix)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文