视觉工作室路径的环境变量? [英] environment variable of visual studio path?

查看:130
本文介绍了视觉工作室路径的环境变量?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

感谢你阅读这个线程。



基本上我想知道如何使用相对路径/环境变量指向visual studio 2012 vcvarsall.bat文件在脚本中?



我目前正在使用绝对路径:

  \Program Files(x86)\Microsoft Visual Studio 11.0 \VC\vcvarsall.batx86_amd64 



<

 调用$(系统)\ $(程序文件)$(VS )\ $(VC)\vcvarsall.batx86_amd64 

非常感谢。 >

EDIT



如果我有多个版本的visual studio会怎么样?我已在我的电脑上安装了vs2008和vs2012。

解决方案

使用Visual Studio宏VCInstallDir

  call $(VCInstallDir)vcvarsall.bat 

或没有Visual Studio宏使用VS110COMNTOOLS

 调用$(VS110COMNTOOLS).. \..\VC\ vcvarsall.bat 


Thanks for reading this thread.

Basically I am wondering how I can use relative path/environment variable pointing to visual studio 2012 vcvarsall.bat file in a script?

I am currently using absolute path:

call "C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\vcvarsall.bat" x86_amd64

How can I do something like this?

call "$(System)\$(Program Files)$(VS)\$(VC)\vcvarsall.bat" x86_amd64

Thanks a lot.

EDIT

What if I have more than one version of visual studio? I have vs2008 and vs2012 both installed on my computer.

解决方案

Using a Visual Studio macro VCInstallDir

call $(VCInstallDir)vcvarsall.bat

Or without Visual Studio macros use VS110COMNTOOLS

call $(VS110COMNTOOLS)..\..\VC\vcvarsall.bat

这篇关于视觉工作室路径的环境变量?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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