To define PATH
locally in a project from property sheet, I need to add it in LocalDebuggerEnvironment
.
This approach works well when there is only 1 property sheet that define PATH
.
If I have more than one property sheet, while I want to use PATH
from every property sheet,
Visual Studio will consider only PATH
of the last property sheet that I have included.
Example
If I create property sheet B1.props
:-
<PropertyGroup Label="UserMacros"><LocalDebuggerEnvironment>
PATH=SOMEPATH1;%PATH%
</LocalDebuggerEnvironment></PropertyGroup>
, property sheet B2.props
:-
<PropertyGroup Label="UserMacros"><LocalDebuggerEnvironment>
PATH=SOMEPATH2;%PATH% <!-- different only this line -->
</LocalDebuggerEnvironment></PropertyGroup>
, property sheet C.props
(=include B1.props
& B2.props
):-
<ImportGroup Label="PropertySheets">
<Import Project="B1.props" />
<Import Project="B2.props" />
</ImportGroup>
, and set a Visual Studio project to use C.props
, I will get the result : PATH=SOMEPATH2;%PATH%
.
Question
How to make Visual Studio use the summation of path e.g. PATH=SOMEPATH2;
SOMEPATH1
;%PATH%
... while maintain the nice property sheet modularity?