In bash I can use src/{foo/{one,two},bar/{three,four}}.o
to describe the files:
src/foo/one.o
src/foo/two.o
src/bar/three.o
src/bar/four.o
I would like to describe the prerequisites of a makefile target in a similar manner. Is there a way to accomplish this in GNU Make?
This is what I have:
SHELL:=/bin/bash
all: src/{foo/{one,two},bar/{three,four}}.o
@echo "$(^)"
And I get:
make: *** No rule to make target 'src/{foo/{one,two},bar/{three,four}}.o', needed by 'all'. Stop.
I came across this and this questions that suggest to add SHELL=/usr/bin/bash
to the makefile. But I still cannot get it to work.
Thanks.