diff --git a/Makefile b/Makefile index ee4f18be5a..f92f1c16bc 100644 --- a/Makefile +++ b/Makefile @@ -20,11 +20,11 @@ docclean: clean: @echo "Cleaning all build products for the current board" - @find ./examples/ ./tests/ -maxdepth 2 -mindepth 2 -type f -name Makefile -execdir "$(MAKE)" clean ';' + @for dir in $(APPLICATION_DIRS); do "$(MAKE)" -C$$dir clean; done distclean: docclean @echo "Cleaning all build products" - @find ./examples/ ./tests/ -maxdepth 2 -mindepth 2 -type f -name Makefile -execdir "$(MAKE)" distclean ';' + @for dir in $(APPLICATION_DIRS); do "$(MAKE)" -C$$dir distclean; done welcome: @echo "Welcome to RIOT - The friendly OS for IoT!" @@ -37,4 +37,6 @@ welcome: @echo "Or ask questions on our mailing list:" @echo " users@riot-os.org (http://lists.riot-os.org/mailman/listinfo/users)" +include makefiles/app_dirs.inc.mk + -include makefiles/tests.inc.mk