Using targets to make subdirectories is problematic, imho, since the
timestamps on the directory don't have any particular meaning. This is a
case of recursive maake being harmful.
If it was me, the dependency would be on the .a file, not on the directory.
all: $(TARGETS)
Target1: adir/lib1.a b
Follow-up Comment #43, bug #17873 (project make):
Another scenario wherein sequential processing of dependencies is useful:
all: subdirs $(TARGETS)
subdirs:
(cd dir1 && make)
(cd dir2 && make)
and the $(TARGETS) depend upon libraries (.a files) that are
made by dir1 and/or dir2.