1SUBDIRS = kernel 2 3.PHONY: all 4all: 5 mkdir -p bin/kernel/ 6 @list='$(SUBDIRS)'; for subdir in $$list; do \ 7 echo "make all in $$subdir";\ 8 cd $$subdir;\ 9 $(MAKE) all;\ 10 cd ..;\ 11 done 12 13.PHONY: clean 14clean: 15 @list='$(SUBDIRS)'; for subdir in $$list; do \ 16 echo "Clean in dir: $$subdir";\ 17 cd $$subdir && $(MAKE) clean;\ 18 cd .. ;\ 19 done 20 21gdb: 22 gdb -n -x tools/.gdbinit