hey folks,
I have an InstallAware 8 project that I have inherited. It has several compiler variables with hard coded paths in there:
foo_foo C:\some\path\a.exe
foo_bar C:\some\path\b.cpp
foo_baz C:\some\path\c.pdf
The section "C:\some\path" is available as a windows environment variable. I tried editing the variables to read:
%var%\a.exe
%var%\b.cpp
%var%\c.pdf
but that didn't seem to be picked up internally by installaware correctly. Is there some way to get the value of an environment variable into the installaware compiler variables?
thanks!
Compiler variables able to use environment variables?
-
MichaelNesmith
- Posts: 3452
- Joined: Thu Dec 22, 2005 7:17 pm
- Contact:
Re: Compiler variables able to use environment variables?
Great question!
InstallAware does not parse environment variables. We are adding support for relative paths though. I'll also add in a request for environment variable parsing.
I'd suggest you just use compiler variables - you can combine them too. For example, #PROJDIR#\#OTHER_VAR#\hard-coded.path.
Also the Refactor Paths tool can help you change multiple paths used in your project in a single pass.
InstallAware does not parse environment variables. We are adding support for relative paths though. I'll also add in a request for environment variable parsing.
I'd suggest you just use compiler variables - you can combine them too. For example, #PROJDIR#\#OTHER_VAR#\hard-coded.path.
Also the Refactor Paths tool can help you change multiple paths used in your project in a single pass.
Michael Nesmith
Install[b]Aware[/b]
[i]Home of The Next Generation MSI Installer[/i]
Get your free copy today - http://www.installaware.com/
Install[b]Aware[/b]
[i]Home of The Next Generation MSI Installer[/i]
Get your free copy today - http://www.installaware.com/
Re: Compiler variables able to use environment variables?
Thanks Michael! So it sounds like you're saying I can define in my compiler variables:
PROJDIR = C:\some\path
and just use #PROJDIR# within the compiler variables everywhere else it's needed, yeah?
Is the definition list order sensitive? Does the PROJDIR definition have to be defined above anywhere else it's used? Such that:
PROJDIR = C:\some\path
FOO = #PROJDIR#\a.exe
will work but:
FOO = #PROJDIR#\a.exe
PROJDIR = C:\some\path
will not work?
Thanks!
PROJDIR = C:\some\path
and just use #PROJDIR# within the compiler variables everywhere else it's needed, yeah?
Is the definition list order sensitive? Does the PROJDIR definition have to be defined above anywhere else it's used? Such that:
PROJDIR = C:\some\path
FOO = #PROJDIR#\a.exe
will work but:
FOO = #PROJDIR#\a.exe
PROJDIR = C:\some\path
will not work?
Thanks!
-
MichaelNesmith
- Posts: 3452
- Joined: Thu Dec 22, 2005 7:17 pm
- Contact:
Re: Compiler variables able to use environment variables?
I believe both should work fine 
Michael Nesmith
Install[b]Aware[/b]
[i]Home of The Next Generation MSI Installer[/i]
Get your free copy today - http://www.installaware.com/
Install[b]Aware[/b]
[i]Home of The Next Generation MSI Installer[/i]
Get your free copy today - http://www.installaware.com/

