Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

NSIS: using environment variable at compile time?

If I'm not mistaken, all discussion about environment variables (EVs) in NSIS docs (eg ReadEnvStr), deal with EVs in the target computer: all happens at install time.

I wonder if there is any support for accesing EVs on the developer (build) machine, at compile time. Specifically, suppose I have

!define SRCDIR "C:\progs\version1\src"

...
File /r "${SRCDIR}\*.*" 

and I'd rather want to write

!define SRCDIR "%{PROG_DIR}\src"

(or something similar), where PROG_DIR is an environment variable. Can this be done?

like image 358
leonbloy Avatar asked Jan 22 '14 20:01

leonbloy


1 Answers

!echo "$%temp%"

I'm pretty sure this is documented somewhere.

like image 172
Anders Avatar answered Oct 13 '22 09:10

Anders