包含路径(include path) 库路径(lib path)VC++2010 (附加)包含目录 (附加)库目录
来源:互联网 发布:我们来了网络更新时间 编辑:程序博客网 时间:2024/05/21 09:30
VC++2010项目属性设置有很多,如果有什么不明白的,单击选择项目属性窗口的某一项设置,按F1(或者单击窗口的帮助按钮),就可以在msdn上看到相关解释了(使用联机帮助的话)。本文的内容整理自msdn,先给出链接,这里只对(附加)包含目录,(附加)库目录进行总结。
“VC++目录”属性页
这里面有包含目录(Include Directories)、库目录(Library Directories)等等,点开看看,里面有VC安装目录、Windows SDK目录、.NET Framework目录,是VC++默认设置好的。对于额外的头文件、库文件,我都在“附加包含目录”、“附加库目录+附加依赖项”处指定(见下文)。
另见一篇专门介绍VC++目录的博客文章:VC++ Directories
"C/C++"
/I(附加包含目录) 指定(第三方的)头文件的目录
附加包含目录(Additional Include Directories)(/I ) :Adds a directory to the list of directories searched for include files.
To add more than one directory, use this option more than once.Directories are searched only until the specified include file is found.
You can use this option with the Ignore Standard Include Paths(/X (Ignore Standard Include Paths))option.
附加包含目录 与 “VC++目录”的“包含目录” 的关系如下:
The compiler searches for directories in the following order:
Directories containing the source file.
Directories specified withthe/I option(即附加包含目录), in the order that CL (编译器cl.exe)encounters them.
Directories specified in the INCLUDE environment variable(即“VC++目录”的“包含目录” ‘Include Directories’).
有关“C/C++ -> 代码生成 -> 运行时库”的内容请参考这里
Choosing the Correct C/C++ Runtime Library
“链接器”
/LIBPATH附加库目录 .lib file的所在目录,
与“VC++目录”的“库目录”的关系如下:
附加库目录(Additional Libpath)(/LIBPATH) :Specifies a path that the linker will search before it searches the path specified in theLIB environment(即“VC++目录”的“库目录” ‘Library Directories’) option.
Use the /LIBPATH option to override the environment library path.The linker will first search in the path specified by this option, and then search in the path specified in the LIB environment variable(即“VC++目录”的“库目录” ‘Library Directories’).
附加依赖项:指定要添加到链接命令行的附加项(.lib file的名字)。
see .Lib Files as Linker Input
更多
下面也是些相关的东西:
LIB Reference
/DLL
/DEFAULTLIB
《深入理解计算机系统》链接那一章。
《程序员的自我修养——链接装载与库》windows dll 那一章。
Beginer's Guide to Linkers
有时,项目配置不仅适用于当前项目,还适用于之后的项目;为了避免重复配置,可以使用“属性管理器”中的用户属性表,
用户属性表会影响计算机上的特定用户的所有项目,如下图所示(Microsoft.Cpp.Win32.user):
这样之后的项目就都会有这儿的配置了。还可以使用项目模板。
See also:
属性表
如何:创建项目模板 “导出模板”向导
- 包含路径(include path) 库路径(lib path)VC++2010 (附加)包含目录 (附加)库目录
- 包含目录、库目录、附加包含目录、附加库目录、附加依赖项之详解(转)
- 附加库目录与附加包含目录
- vc包含路径/附加包含路径/include的机制
- 包含目录、库目录、附加包含目录、附加库目录、附加依赖项之详解
- 包含目录、库目录、附加包含目录、附加库目录、附加依赖项之详解
- VS中包含目录、附加包含目录、附加库目录及附加依赖项
- C/C++附加包含目录和VC++目录包含目录区别? 连接器常规附加库目录和VC++目录库目录区别?
- VS中包含目录、库目录、附加包含目录、附加库目录、附加依赖项的解释
- Visusl Studio——包含目录、库目录、附加包含目录、附加库目录、附加依赖项之详解
- 在VC项目中附加包含目录
- VS2008 vs2010附加包含Inlude目录、Lib目录区别
- 包含目录和附加包含目录
- VS2013 添加附加依赖项(包含目录,库目录)
- C++ 包含目录、库目录、附加依赖项总结
- VS包含目录、附加依赖项、库目录设置
- VC包含目录、附加依赖项、库目录及具体设置
- VC包含目录、附加依赖项、库目录及具体设置
- E-R图转换成关系模式
- CSDN 真垃圾,奶奶的,下载个资源,登录了也提示下载请登录,shit
- Magento Core: (FIX) Admin slow loading on product save
- 关于vs2003、vs2005、vs2008和vs2010项目互转的总结
- shell 中单引号、双引号的区别
- 包含路径(include path) 库路径(lib path)VC++2010 (附加)包含目录 (附加)库目录
- 10GR2迁移升级到11GR2压力性能测试二
- vb.net写的断点续传下载类
- RAID
- ocp-047-18 create view
- CSS3字体
- 一个简单的Web服务器(Web服务器如何工作)
- 链表的建立、输出、非递归反转、递归反转
- 《UNIX环境高级编程》笔记--读和写流