Subject: Re: [Boost-build] Problem with mingw flavour
From: Steven Watanabe (watanabesj_at_[hidden])
Date: 2008-10-30 17:12:37
Vladimir Prus wrote:
> 1. Be able to select the right compiler, by giving its version and some
Whatever properties that are sufficient to uniquely identify the compiler,
should be ok.
> The question of what features form primary key is tricky.
> 1. If compiler is selected based on version alone, and target-os/architecture is set
> from it, it means that we cannot have the same version in the example above. We probably
> would need to have two versions -- specified by user, and the 'real version' reported by
> compiler, which can be checked in Jamfiles.
So, the one specified by the user would just be a unique toolset id, right?
> 2. If we also use target-os and/or architecture in compiler selection, it forces the user
> to specify those properties, which is inconvenient. The upcoming configure mechanism
> will make it required to specif those properties only once, but still -- is this OK?
> Maybe it is, after all when cross-compiling auto* projects, one usually uses
> --target=cpu-none-os. I'd imagine that if we can reliably detect architecture of the
> current machine, and the architecture of the compiler, we can use host's architecture
> as default.
> I don't know what a really good interface would be. Ideas?
I think that it should obey these rules:
a) We should only select a compiler which matches all of the relevant
have been specified.
b) Once we know which compiler to use, any remaining features that can
be deduced from the identity of the compiler should be added.
c) If only one compiler matches the known features, then we're home free.
d) If there is more than one choice, we can:
i) Issue an error.
ii) Choose the first version to be initialized.
iii) Add the default values of features (specifically target-os and
architecture) and try again.
I don't know how feasible this would be, though.
Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk