[build2] What does these means? exe{*} lib{*}
Klaim - Joël Lamotte
mjklaim at gmail.com
Tue Sep 18 22:30:50 UTC 2018
On Tue, 18 Sep 2018 at 18:51, Boris Kolpackov <boris at codesynthesis.com> wrote:
>
> Klaim - Joėl Lamotte <mjklaim at gmail.com> writes:
> > 1. Would it make sense to make globing syntax an error for targets
> > that are not file targets?
>
> Yes, I will look into your examples once I am back from CppCon and
> we will add the diagnostics.
>
Noted, it's not blocking me anyway.
> Also note that
>
> lib{*}: x = y
>
> and
>
> exe{x}: lib{*}
>
> mean very different things. The former is a target type/patter-specific
> variable assignment and makes sense for the lib{} target type (i.e. it
> has nothing to do with globbing).
I think I will need a longer explanation on this point because I find
it (either the syntax or the semantic) confusing in several ways, in
particular in contrast with the documentation example with
"exe{*.test} : test = true"
Let's discuss this again once you got back to the issue.
> The latter is a prerequisite name
> pattern, which should probably be an error in this case since lib{} is
> not file-based.
Ok. I think my examples show cases where it would have been useful to
have lib{*} mean "all the library targets in current directory scope"
but maybe you have another syntax that would solve the same problem.
Joël
More information about the users
mailing list