Discussion:
How to do (for-each-)loops?
(too old to reply)
Sebastian Schuberth
2008-08-06 15:50:02 UTC
Permalink
Raw Message
Hi,

are something like loops supported in Bakefile? E.g. how would I create a <msvc-file-group> for each name in an array of strings (which is the output of the fileList() function)?

Thanks.
--
Sebastian Schuberth
Vaclav Slavik
2008-08-06 19:33:10 UTC
Permalink
Raw Message
Post by Sebastian Schuberth
are something like loops supported in Bakefile?
No.
Post by Sebastian Schuberth
E.g. how would I create a <msvc-file-group> for each name in an array
of strings (which is the output of the fileList() function)?
Even if there was a loop construct, I don't see how would it help with
<msvc-file-group> (which you need *one* per group, not per file, and
which accepts files wildcard as part of its argument).

Vaclav
Sebastian Schuberth
2008-08-06 19:59:08 UTC
Permalink
Raw Message
Post by Vaclav Slavik
Post by Sebastian Schuberth
E.g. how would I create a <msvc-file-group> for each name in an array
of strings (which is the output of the fileList() function)?
Even if there was a loop construct, I don't see how would it help with
<msvc-file-group> (which you need *one* per group, not per file, and
which accepts files wildcard as part of its argument).
The list of strings fileList() would return here is not a list of files,
but a list of directories. I'd like to have one <msvc-file-group> per
directory, and put *any* files in that directory into that group. In
other words, I'd like to resemble the directory structure on my hard
disk in the project file. This means that not all header files in the
source code tree go to one group, but to the group in which's directory
they are in.

Is this possible with Bakefile, in a generic way?
--
Sebastian Schuberth
Vaclav Slavik
2008-08-06 20:36:34 UTC
Permalink
Raw Message
Post by Sebastian Schuberth
Is this possible with Bakefile, in a generic way?
Yes -- enumerate the groups manually. If it's too burdensome, then
you're probably having too many groups for them to be usable anyway.

Regards,
Vaclav

Loading...