background jobs in makefile

James <[email protected]> Wed, 18 Aug 2010 10:46:11 -0700 (PDT)
Newsgroups gmane.comp.gnu.utils
Organization http://groups.google.com
Message-ID <28e7e75e-91a0-487a-b935-b3381f0cd9d3@v35g2000prn.googlegroups.com>
all:
        for f in xx yy; do\
                (make $$f &);\
        done;\
        wait
        @echo [ $@:done ]

xx yy:
        sleep 2
        @echo [ $@:done ]


How do I put backgroud jobs in makefile?
"wait" does not seem to work here.

TIA
jl