I can't believe I am asking this...
我不敢相信我问这个......
It has been a while since I used VC6. I set up what I thought was the correct way to include additional directories for include files (I removed another developer's hard coded paths) and put in something like:
我用VC6已经有一段时间了。我设置了我认为正确的方法来包含其他目录的包含文件(我删除了另一个开发人员的硬编码路径)并输入如下内容:
%MY_DIR%\include
but this does not work. Am I missing something? Did VC6 not allow this? It seems like a pretty basic thing to have and now that I think about it it I can't recall ever having done it before...
但这不起作用。我错过了什么吗? VC6不允许这样吗?它似乎是一个非常基本的东西,现在我想起来,我记不起曾经做过它...
(I did stop and re-start VC6 after I set the variables)
(我在设置变量后停止并重新启动VC6)
Google search and a quick search here did not reveal anything.
谷歌搜索和快速搜索没有透露任何信息。
EDIT
Apparently I can't vote for my own answer - but it is below:
显然我不能投票给我自己的答案 - 但它在下面:
The syntax is:
语法是:
$(ENV_VAR)
not
%ENV_VAR%
I'd rather not have to add to an include env variable - that seems to imply that I have to build from a command line now. I want to be able to add an environment variable in the project settings. That seems like a very simple thing to do, but perhaps that was expecting too much from the IDE team.
我宁愿不必添加到include env变量 - 这似乎暗示我现在必须从命令行构建。我希望能够在项目设置中添加环境变量。这似乎是一件非常简单的事情,但也许这对IDE团队来说太过期待了。
I am not sure what it means that %MY_DIR% is not taken into account properly... I did start cmd.exe from the tools menu like you suggested and the env path I set is there and as expected.
我不确定这是什么意思%MY_DIR%没有被正确考虑...我确实从你建议的工具菜单中启动了cmd.exe,我设置的env路径就在那里并且正如预期的那样。
2 个解决方案
#1
2
Here's the answer...
这是答案......
it works fine.
它工作正常。
$(ENV_VAR_NAME) not %ENV_VAR_NAME%
$(ENV_VAR_NAME)不是%ENV_VAR_NAME%
(I feel like an idiot. )
(我觉得自己像个白痴。)
#2
0
I don't think that the IDE will take any environment settings unless you use that flag.
除非您使用该标志,否则我认为IDE不会采用任何环境设置。
Oh, and you don't have build from the command line if you launch it from the command line. You can still use the build menu in the IDE.
哦,如果从命令行启动它,则没有从命令行构建。您仍然可以在IDE中使用构建菜单。
#1
2
Here's the answer...
这是答案......
it works fine.
它工作正常。
$(ENV_VAR_NAME) not %ENV_VAR_NAME%
$(ENV_VAR_NAME)不是%ENV_VAR_NAME%
(I feel like an idiot. )
(我觉得自己像个白痴。)
#2
0
I don't think that the IDE will take any environment settings unless you use that flag.
除非您使用该标志,否则我认为IDE不会采用任何环境设置。
Oh, and you don't have build from the command line if you launch it from the command line. You can still use the build menu in the IDE.
哦,如果从命令行启动它,则没有从命令行构建。您仍然可以在IDE中使用构建菜单。