WIX错误:Light.exe在给出相对路径时找不到文件,但是如果给出了绝对路径,可以找到它
The system cannot find the file '..\..\..\..\..\..\out\Debug\[FilePath]' with type ''.
我正在使用Wixproj中的HeatDirectory任务来从指定的目录中获取文件,但是当我使用相对路径时,它会给我这个错误,当我使用绝对路径时,它将成功构建。是否有任何解决方法或解决方案,因为我无法使用ABS路径,因为它是由团队进行的,而且我们必须使用DevOps在云中构建它。
注意:我已经阅读 httpps://sourceforge.net/pp/p/wix/wix/bugs/bugs/24445/ 这并不建议解决方案。
The system cannot find the file '..\..\..\..\..\..\out\Debug\[FilePath]' with type ''.
I am using a HeatDirectory task in wixproj to fetch files from the specified directory but when I use relative path it gives me this error and when I use absolute path it is building successfully. Is there any workaround or solution for this as I cant have abs path as it is being worked upon by a team and also we have to build it in cloud using DevOps.
Note: I have read https://sourceforge.net/p/wix/bugs/2445/ but this doesn't suggest a solution.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
有一些解决方案。
您可以在$(solutiondir)或$(projectDir)等属性中使用构建来省略...
或者,您可以使用如下所示的构建任务转换对象。
如果您有先进的话,甚至可以使用C#脚本。
there are a couple of solutions to this.
You can use build in properties like $(SolutionDir) or $(ProjectDir) to be able to omit ...
Or you can use the build task ConvertToAbsolutePath as shown below.
You could even use a C# script if you prefere this.