What are the merits of debug_and_release config fe

2019-04-26 19:40发布

I can see only one merit of the feauture: we are able to issue the make all commad.

Well, I do not call make in any point of my developer's life. I use Qt Creator and when I build the project I want it strictly as debug or as release. I guess this is an expeted behaviour by people.

But debug_and_release is on by default in Qt Creator. Is there a merit in this I can't see? Is there some sense in the unintuitive mess like this:

CONFIG( debug, debug|release ) {
    # debug
} else {
    # release
}

which people are learning by making mistakes and asking WTF questions all over the internet?

Am I missing something?

1条回答
Luminary・发光体
2楼-- · 2019-04-26 20:05

I switch it off:

CONFIG -= debug_and_release
CONFIG( debug, debug|release )  {
  CONFIG -= release
}
else {
  CONFIG -= debug
  CONFIG += release
}

UPD.

I've got it. My question is completely wrong. debug_and_release have not much to do with debug and release.

查看更多
登录 后发表回答