[Qt-creator] Creator ignores condition blocks?

Coda Highland chighland at gmail.com
Mon Mar 12 21:34:59 CET 2012


On Mon, Mar 12, 2012 at 3:25 PM, Danny Price <deepblue842 at googlemail.com> wrote:
> I have the following in my .pro file:
>
> macx {
>    include(mac.pri)
> }
>
> win32 {
>    include(win.pri)
> }
>
> These pri files include different code for the relevant platform and only the correct files are compiled. However, rather than display only the relevant files in the project tree as I would expect, Creator includes ALL of them as though the conditions were not there.
>
> I tried putting message() calls in the blocks above and only one or the other is parsed when I run QMake so why is Creator displaying the wrong files?
>
> I've noticed similar problems with configuration blocks - Creator includes the files fall all configurations, even those are not active.
>
> Is this a bug?

My understanding from earlier discussions is that this is intentional.
The theory is that you're interested in modifying the source files in
your project regardless of the build configuration you have chosen at
the moment.

/s/ Adam



More information about the Qt-creator mailing list