OK, understood.
Thank you!

18.12.2017 14:15, Christian Kandeler пишет:
On Mon, 18 Dec 2017 14:04:21 +0300
Карелин Павел <hka...@yandex.ru> wrote:

In my project, I use the following construction:

      cpp.defines: {
          var def = [];
          if (project.simdDebug)
              def.push("SIMD_DEBUG");

          if (project.useSimd)
              def.push("USE_SIMD");

          return def;
      }

It works fine.
But I decided to experiment and do the same through "Properties"

      Properties {
          condition: project.simdDebug
          cpp.defines: outer.concat(["SIMD_DEBUG"])
      }
      Properties {
          condition: project.useSimd
          cpp.defines: outer.concat(["USE_SIMD"])
      }

As a result, I get either SIMD_DEBUG or USE_SIMD at the output, but not
both at once.
Is it possible to get both values immediately using "Properties"?
No, the Properties items form an implicit "else if" chain, so the conditions 
should be mutually exclusive if the same property appears in more than one of them. They 
are not well-suited for additive semantics like in your example.


Christian
_______________________________________________
Qbs mailing list
Qbs@qt-project.org
http://lists.qt-project.org/mailman/listinfo/qbs

_______________________________________________
Qbs mailing list
Qbs@qt-project.org
http://lists.qt-project.org/mailman/listinfo/qbs

Reply via email to