[Cook] Foreach in a currentdirectory

xancorreu xancorreu at gmail.com
Fri Apr 27 06:56:19 EST 2012


Al 26/04/12 21:58, En/na Pendergraft, Jerry ha escrit:
> Best way to deal with issues like this is to have a "manifest" variable.
> Then you can do things like:
> All : [patsubst %0%.cpp %0%.out [match_mask %0%.cpp [project_files]];

Nothing more?

Is it the complete example?

Thanks,
Xan.
>
> -----Original Message-----
> From: cook-users-bounces+jpendergraft=sjm.com at lists.auug.org.au [mailto:cook-users-bounces+jpendergraft=sjm.com at lists.auug.org.au] On Behalf Of xancorreu
> Sent: Thursday, April 26, 2012 7:14 AM
> To: cook-users at lists.auug.org.au
> Subject: [Cook] Foreach in a currentdirectory
>
> Hi,
>
> I have this cookfile:
>
> all: algorisme.out hola.out;
>
>
> algorisme.out: algorisme.cpp
> {
>       clang++ -o algorisme.out algorisme.cpp;
> }
>
> hola.out: hola.cpp
> {
>      clang++ -o hola.out hola.cpp;
> }
>
>
> I want to substitute this for the rule:
>
> process every file with .cpp extension and write as this file.out
>
> I try this:
>
> %0.out: %.cpp
> {
>     clang...
> }
>
>
> but how to say that I want to process all the files in the current
> directory?
> What should I add to all:?
>
>
> Thanks in advance,
> Xan.
>
> _______________________________________________
> Cook-users mailing list
> Cook-users at lists.auug.org.au
> http://lists.auug.org.au/listinfo/cook-users
>
> This communication, including any attachments, may contain information that is proprietary, privileged, confidential or legally exempt from disclosure. If you are not a named addressee, you are hereby notified that you are not authorized to read, print, retain a copy of or disseminate any portion of this communication without the consent of the sender and that doing so may be unlawful. If you have received this communication in error, please immediately notify the sender via return e-mail and delete it from your system.



More information about the Cook-users mailing list