qt - Force qmake to error out when reading undefined variables -


i need force qmake have set -eu in bash, this:

$ bash -eu -c 'echo $foo; echo carrying on' bash: foo: unbound variable $ echo $? 1 

results in failure, , not print "carrying on".

does qmake support option "reading undefined variable error"?

for qmake variables can use isempty() is. checking environment variables there dirty hack:

var = $$(foo) isempty(var) {     message(empty) } else {     message(foo $(foo)) } 

test:

$ qmake project message: empty $ foo=test qmake project message: foo test 

Comments

Popular posts from this blog

android - How to save instance state of selected radiobutton on menu -

python 3 IndexError: list index out of range -

IF statement in MySQL trigger -