I'd just like to add to what @Christoph suggested, because for some reason just using DIRS = $(wildcard */) did NOT work for me, so I ended up having to do $ROOT_DIR = ./ & then substituting that to do $DIRS = $(wildcard $(ROOT_DIT)*/)$ which gave me the appropriate output of the sub-folders/files