[Qbs] How do I build using GCC with the "-march=native" option?

Ola Røer Thorsen ola at silentwings.no
Thu Dec 7 22:38:56 CET 2017

Hi, I'm trying to build my code with the gcc "-march=native"-option
(x86-64), or any other value there for that matter. Qbs won't let me do
that using

cpp.cxxFlags: [ "-march=native" ]


"warning: The following properties have invalid values:
cpp.cxxFlags: '-target', '-triple', '-arch' and '-march' cannot appear in
flags; set qbs.architecture instead"


qbs.architecture: "native"


"warning: The following properties have invalid values:
cpp.architecture: 'native' differs from the architecture produced by this
compiler (x86_64)"

How do I fix this?

The -mtune option works but it's not quite what I'm after here.

Best regards,
Ola Røer Thorsen
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/qbs/attachments/20171207/9b8a5b6a/attachment.html>

More information about the Qbs mailing list