如何为msbuild.exe指定其他包含目录 [英] How to specify additional include directories for msbuild.exe

查看:261
本文介绍了如何为msbuild.exe指定其他包含目录的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试安装nodejs模块ibm_db.我遇到的问题是,要安装此模块,node-gyp需要使用msbuild进行构建,但无法检测到我已安装的某些头文件.

I am attempting to install the nodejs module ibm_db. The issue I am having is that in order to install this module node-gyp needs to build it using msbuild, but it won't detect some header files I have installed.

如何将其他头文件的目录添加到某个路径,以便在尝试编译任何项目时,hatt msbuild.exe可以找到它们?在Linux上,我只需设置cpath =即可,一切都构建良好.

How do I add the directory of my additional header files to some path so hatt msbuild.exe will find them when trying to compile any project? On linux I simply set cpath= and everything build just fine.

谢谢!

推荐答案

MSBuild公开了一些特殊属性,用于在构建时解析引用. 您可以设置AssemblySearchPathsAdditionalLibPaths.

MSBuild exposes special properties for resolving references in build time. You can set AssemblySearchPaths and AdditionalLibPaths.

例如msbuild your.sln /p:AssemblySearchPaths="C:\Dev\Lib\Foo;C:\Dev\Lib\Bar;"

请参见常见的MSBuild项目属性

这篇关于如何为msbuild.exe指定其他包含目录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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