Skip to content

qibuild add-config --host lets you create a qibuild.xml with several host configs (which qibuild does not support) #105

@sbarthelemy

Description

@sbarthelemy

Seen on qibuild 3.11.6 from pip.

$ qibuild add-config foo --host
$ qibuild add-config bar --host
$ cat ~/.config/qi/qibuild.xml
<qibuild version="1">
  <defaults>
    <env />
    <cmake />
  </defaults>
  <config host="true" name="bar">
    <env />
    <cmake />
    <profiles />
  </config>
  <config host="true" name="foo">
    <env />
    <cmake />
    <profiles />
  </config>
</qibuild>

Since two config are marked "host" qibuild make-host-tools picks one arbitrarily, possibly the wrong one.

A workaround is to use qibuild set-host-config.

$ qibuild set-host-config bar
$ cat ~/.config/qi/qibuild.xml
<qibuild version="1">
  <defaults>
    <env />
    <cmake />
  </defaults>
  <config host="true" name="bar">
    <env />
    <cmake />
    <profiles />
  </config>
  <config name="foo">
    <env />
    <cmake />
    <profiles />
  </config>
</qibuild>

I think the proper fix is to avoid this "only one host config requirement". As explained in issue #81.
This new bug is one more clue that the current design is flawed.

Note: the current code is quite easy to understand:

add_build_config creates the config (host or not), then add_config adds it without checking for host config collision.

On the contrary set_host_config does check.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions