Qt Extended Home · Build System Home · Reference · User Guide · Internals codeless banner

Add a global option

Put this in the optvar section of configure.

    set_optvar( "myopt", +{
        "set" => [ "%", "Enable myopt." ],
        "unset" => [ "no-%", "Disable myopt." ],
        "default" => 1,
        "visible" => $qtopia_visref,
        "autodep" => $qtopia_autoref,
        "config_pri" => "CONFIG+=enable_myopt",

Note the use of a positively-worded option. It is much easier to figure out what code does when the options are positively worded.

If you want defines for testing in code, put this in a suitable place (defaults.js is typical for global stuff).

    # positive define (preferred)
    # negative define (to match the QT_NO_ style)

See also Tasks and Opt System.

Copyright © 2009 Nokia
Qt Extended - Build System Documentation