summaryrefslogtreecommitdiff
path: root/apps/Makefile
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-03-20 18:18:19 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-03-20 18:18:19 +0000
commiteafaeb9398216dacb92de69683ccdda6007efb1d (patch)
treee513e4fd791670d9b74d33821682d4059ed73098 /apps/Makefile
parentf68c474e8ae9cfa5c9124a6eb92ec06fe2bf40a1 (diff)
downloadnuttx-eafaeb9398216dacb92de69683ccdda6007efb1d.tar.gz
nuttx-eafaeb9398216dacb92de69683ccdda6007efb1d.tar.bz2
nuttx-eafaeb9398216dacb92de69683ccdda6007efb1d.zip
Move nuttx/examples to apps/examples
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3405 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'apps/Makefile')
-rw-r--r--apps/Makefile23
1 files changed, 11 insertions, 12 deletions
diff --git a/apps/Makefile b/apps/Makefile
index d81606a3f..76eeb1e92 100644
--- a/apps/Makefile
+++ b/apps/Makefile
@@ -36,10 +36,6 @@
-include $(TOPDIR)/Make.defs
-ifeq ($(WINTOOL),y)
-INCDIROPT = -w
-endif
-
APPDIR = ${shell pwd}
# Application Directories
@@ -47,7 +43,7 @@ APPDIR = ${shell pwd}
# SUBDIRS is the list of all directories containing Makefiles. It is used
# only for cleaning.
-SUBDIRS = nshlib netutils vsn
+SUBDIRS = nshlib netutils examples vsn
# we use a non-existing .built_always to guarantee that Makefile
# always walks into the sub-directories and asks for build
@@ -93,7 +89,8 @@ $(foreach BUILT, $(AVAILABLE_APPS), $(eval $(call BUILTIN_ADD_BUILT,$(BUILT))))
endif
-ROOTDEPPATH = --dep-path .
+# Source and object files
+
ASRCS =
CSRCS = exec_nuttapp.c
@@ -105,9 +102,11 @@ OBJS = $(AOBJS) $(COBJS)
BIN = libapps$(LIBEXT)
+ROOTDEPPATH = --dep-path .
VPATH =
all: $(BIN)
+.PHONY: .depend depend clean distclean
$(AOBJS): %$(OBJEXT): %.S
$(call ASSEMBLE, $<, $@)
@@ -138,21 +137,21 @@ $(BIN): $(OBJS) $(BUILTIN_APPS_BUILT)
depend: .depend
-define MAKECLEAN
- @(MAKE) -C $1 $2 TOPDIR="$(TOPDIR)" APPDIR=$(APPDIR)
-endef
-
clean:
@rm -f $(BIN) *~ .*.swp *.o libapps.a
$(call CLEAN)
- $(foreach DIR, $(SUBDIRS), $(eval $(call MAKECLEAN,$(DIR),clean)))
+ @for dir in $(SUBDIRS) ; do \
+ $(MAKE) -C $$dir clean TOPDIR="$(TOPDIR)" APPDIR=$(APPDIR); \
+ done
distclean: clean
@rm -f .config
@rm -f Make.dep .depend
@rm -f exec_nuttapp_list.h
@rm -f exec_nuttapp_proto.h
- $(foreach DIR, $(SUBDIRS), $(eval $(call MAKECLEAN,$(DIR),distclean)))
+ @for dir in $(SUBDIRS) ; do \
+ $(MAKE) -C $$dir distclean TOPDIR="$(TOPDIR)" APPDIR=$(APPDIR); \
+ done
-include Make.dep