Most of the changes needed to support Windows native clean; distclean is has a problem
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5367 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
parent
43dda7996d
commit
26c9112ad2
31 changed files with 228 additions and 141 deletions
|
|
@ -419,10 +419,10 @@ context: check_context include/nuttx/config.h include/nuttx/version.h include/ma
|
|||
# and symbolic links created by the context target.
|
||||
|
||||
clean_context:
|
||||
$(Q) rm -f include/nuttx/config.h
|
||||
$(Q) rm -f include/nuttx/version.h
|
||||
$(Q) rm -f include/math.h
|
||||
$(Q) rm -f include/stdarg.h
|
||||
$(call DELFILE include/nuttx/config.h)
|
||||
$(call DELFILE include/nuttx/version.h)
|
||||
$(call DELFILE include/math.h)
|
||||
$(call DELFILE include/stdarg.h)
|
||||
$(Q) $(DIRUNLINK) include/arch/board
|
||||
$(Q) $(DIRUNLINK) include/arch/chip
|
||||
$(Q) $(DIRUNLINK) include/arch
|
||||
|
|
@ -686,8 +686,13 @@ ifeq ($(CONFIG_BUILD_2PASS),y)
|
|||
endif
|
||||
|
||||
clean: subdir_clean
|
||||
$(Q) rm -f $(BIN) nuttx.* mm_test *.map _SAVED_APPS_config *~
|
||||
$(Q) rm -f nuttx-export*
|
||||
$(call DELFILE $(BIN))
|
||||
$(call DELFILE nuttx.*)
|
||||
$(call DELFILE mm_test)
|
||||
$(call DELFILE *.map)
|
||||
$(call DELFILE _SAVED_APPS_config)
|
||||
$(call DELFILE nuttx-export*)
|
||||
$(call CLEAN)
|
||||
|
||||
subdir_distclean:
|
||||
$(Q) for dir in $(CLEANDIRS) ; do \
|
||||
|
|
@ -700,7 +705,11 @@ distclean: clean subdir_distclean clean_context
|
|||
ifeq ($(CONFIG_BUILD_2PASS),y)
|
||||
$(Q) $(MAKE) -C $(CONFIG_PASS1_BUILDIR) TOPDIR="$(TOPDIR)" distclean
|
||||
endif
|
||||
$(Q) rm -f Make.defs setenv.sh setenv.bat .config .config.old
|
||||
$(call DELFILE Make.defs)
|
||||
$(call DELFILE setenv.sh)
|
||||
$(call DELFILE setenv.bat)
|
||||
$(call DELFILE .config)
|
||||
$(call DELFILE .config.old)
|
||||
|
||||
# Application housekeeping targets. The APPDIR variable refers to the user
|
||||
# application directory. A sample apps/ directory is included with NuttX,
|
||||
|
|
|
|||
36
Makefile.win
36
Makefile.win
|
|
@ -438,10 +438,10 @@ context: check_context include\nuttx\config.h include\nuttx\version.h include\ma
|
|||
# and symbolic links created by the context target.
|
||||
|
||||
clean_context:
|
||||
$(Q) rm -f include\nuttx\config.h
|
||||
$(Q) rm -f include\nuttx\version.h
|
||||
$(Q) rm -f include\math.h
|
||||
$(Q) rm -f include\stdarg.h
|
||||
$(call DELFILE include\nuttx\config.h)
|
||||
$(call DELFILE include\nuttx\version.h)
|
||||
$(call DELFILE include\math.h)
|
||||
$(call DELFILE include\stdarg.h)
|
||||
$(Q) $(DIRUNLINK) include\arch\board
|
||||
$(Q) $(DIRUNLINK) include\arch\chip
|
||||
$(Q) $(DIRUNLINK) include\arch
|
||||
|
|
@ -688,8 +688,13 @@ ifeq ($(CONFIG_BUILD_2PASS),y)
|
|||
endif
|
||||
|
||||
clean: subdir_clean
|
||||
$(Q) rm -f $(BIN) nuttx.* mm_test *.map _SAVED_APPS_config *~
|
||||
$(Q) rm -f nuttx-export*
|
||||
$(call DELFILE $(BIN))
|
||||
$(call DELFILE nuttx.*)
|
||||
$(call DELFILE mm_test)
|
||||
$(call DELFILE *.map)
|
||||
$(call DELFILE _SAVED_APPS_config)
|
||||
$(call DELFILE nuttx-export*)
|
||||
$(call CLEAN)
|
||||
|
||||
subdir_distclean:
|
||||
$(Q) for %%G in ($(CLEANDIRS)) do ( if exist %%G\Makefile $(MAKE) -C %%G TOPDIR="$(TOPDIR)" distclean )
|
||||
|
|
@ -698,7 +703,11 @@ distclean: clean subdir_distclean clean_context
|
|||
ifeq ($(CONFIG_BUILD_2PASS),y)
|
||||
$(Q) $(MAKE) -C $(CONFIG_PASS1_BUILDIR) TOPDIR="$(TOPDIR)" distclean
|
||||
endif
|
||||
$(Q) rm -f Make.defs setenv.sh setenv.bat .config .config.old
|
||||
$(call DELFILE Make.defs)
|
||||
$(call DELFILE setenv.sh)
|
||||
$(call DELFILE setenv.bat)
|
||||
$(call DELFILE .config)
|
||||
$(call DELFILE .config.old)
|
||||
|
||||
# Application housekeeping targets. The APPDIR variable refers to the user
|
||||
# application directory. A sample apps\ directory is included with NuttX,
|
||||
|
|
@ -723,16 +732,9 @@ endif
|
|||
|
||||
apps_distclean:
|
||||
ifneq ($(APPDIR),)
|
||||
$(Q) if [ -r "$(TOPDIR)\$(APPDIR)\.config" ]; then \
|
||||
cp "$(TOPDIR)\$(APPDIR)\.config" _SAVED_APPS_config || \
|
||||
{ echo "Copy of $(APPDIR)\.config failed" ; exit 1 ; } \
|
||||
else \
|
||||
rm -f _SAVED_APPS_config; \
|
||||
fi
|
||||
$(call DELFILE _SAVED_APPS_config
|
||||
$(Q) if exist "$(TOPDIR)\$(APPDIR)\.config" ( cp "$(TOPDIR)\$(APPDIR)\.config" _SAVED_APPS_config )
|
||||
$(Q) $(MAKE) -C "$(TOPDIR)\$(APPDIR)" TOPDIR="$(TOPDIR)" distclean
|
||||
$(Q) if [ -r _SAVED_APPS_config ]; then \
|
||||
mv _SAVED_APPS_config "$(TOPDIR)\$(APPDIR)\.config" || \
|
||||
{ echo "Copy of _SAVED_APPS_config failed" ; exit 1 ; } \
|
||||
fi
|
||||
$(Q) if exist _SAVED_APPS_config ( mv _SAVED_APPS_config "$(TOPDIR)\$(APPDIR)\.config" )
|
||||
endif
|
||||
|
||||
|
|
|
|||
|
|
@ -221,13 +221,15 @@ clean:
|
|||
$(Q) if [ -e board/Makefile ]; then \
|
||||
$(MAKE) -C board TOPDIR=$(TOPDIR) clean ; \
|
||||
fi
|
||||
$(Q) rm -f libarch$(LIBEXT) up_mem.h *~ .*.swp
|
||||
$(call DELFILE libarch$(LIBEXT))
|
||||
$(call DELFILE up_mem.h)
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
$(Q) if [ -e board/Makefile ]; then \
|
||||
$(MAKE) -C board TOPDIR=$(TOPDIR) distclean ; \
|
||||
fi
|
||||
rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -178,13 +178,14 @@ clean:
|
|||
ifeq ($(BOARDMAKE),y)
|
||||
$(Q) $(MAKE) -C board TOPDIR="$(TOPDIR)" clean
|
||||
endif
|
||||
$(Q) rm -f libarch$(LIBEXT) *~ .*.swp
|
||||
$(call DELFILE libarch$(LIBEXT))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
ifeq ($(BOARDMAKE),y)
|
||||
$(Q) $(MAKE) -C board TOPDIR="$(TOPDIR)" distclean
|
||||
endif
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -171,14 +171,15 @@ clean:
|
|||
ifeq ($(BOARDMAKE),y)
|
||||
$(Q) $(MAKE) -C board TOPDIR="$(TOPDIR)" clean
|
||||
endif
|
||||
$(Q) rm -f libarch$(LIBEXT) *~ .*.swp
|
||||
$(call DELFILE libarch$(LIBEXT))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
ifeq ($(BOARDMAKE),y)
|
||||
$(Q) $(MAKE) -C board TOPDIR="$(TOPDIR)" distclean
|
||||
endif
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
||||
|
|
|
|||
|
|
@ -166,13 +166,14 @@ clean:
|
|||
ifeq ($(BOARDMAKE),y)
|
||||
$(Q) $(MAKE) -C board TOPDIR="$(TOPDIR)" clean
|
||||
endif
|
||||
$(Q) rm -f libarch$(LIBEXT) *~ .*.swp
|
||||
$(call DELFILE libarch$(LIBEXT))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
ifeq ($(BOARDMAKE),y)
|
||||
$(Q) $(MAKE) -C board TOPDIR="$(TOPDIR)" distclean
|
||||
endif
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -164,13 +164,14 @@ clean:
|
|||
ifeq ($(BOARDMAKE),y)
|
||||
$(Q) $(MAKE) -C board TOPDIR="$(TOPDIR)" clean
|
||||
endif
|
||||
$(Q) rm -f libarch$(LIBEXT) *~ .*.swp
|
||||
$(call DELFILE libarch$(LIBEXT))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
ifeq ($(BOARDMAKE),y)
|
||||
$(Q) $(MAKE) -C board TOPDIR="$(TOPDIR)" distclean
|
||||
endif
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -96,12 +96,14 @@ export_head:
|
|||
depend: .depend
|
||||
|
||||
clean:
|
||||
@rm -f $(TOPDIR)/arch/rgmp/src/x86/*.o
|
||||
@rm -f $(TOPDIR)/kernel.img nuttx.img
|
||||
@rm -f libarch$(LIBEXT) *~ .*.swp
|
||||
$(call DELFILE "$(TOPDIR)/arch/rgmp/src/x86/*.o")
|
||||
$(call DELFILE "$(TOPDIR)/kernel.img")
|
||||
$(call DELFILE nuttx.img)
|
||||
$(call DELFILE libarch$(LIBEXT))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
@rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -161,13 +161,14 @@ clean:
|
|||
ifeq ($(BOARDMAKE),y)
|
||||
$(Q) $(MAKE) -C board TOPDIR="$(TOPDIR)" clean
|
||||
endif
|
||||
$(Q) rm -f libarch$(LIBEXT) *~ .*.swp
|
||||
$(call DELFILE libarch$(LIBEXT))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
ifeq ($(BOARDMAKE),y)
|
||||
$(Q) $(MAKE) -C board TOPDIR="$(TOPDIR)" distclean
|
||||
endif
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -214,14 +214,16 @@ clean: cleanrel
|
|||
$(Q) if [ -e board/Makefile ]; then \
|
||||
$(MAKE) -C board TOPDIR="$(TOPDIR)" clean ; \
|
||||
fi
|
||||
$(Q) rm -f nuttx.rel libarch$(LIBEXT) *~ .*.swp
|
||||
$(call DELFILE nuttx.rel)
|
||||
$(call DELFILE libarch$(LIBEXT))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
$(Q) if [ -e board/Makefile ]; then \
|
||||
$(MAKE) -C board TOPDIR="$(TOPDIR)" distclean ; \
|
||||
fi
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
$(Q) rm -rf GNU
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -172,13 +172,14 @@ clean:
|
|||
ifeq ($(BOARDMAKE),y)
|
||||
$(Q) $(MAKE) -C board TOPDIR="$(TOPDIR)" clean
|
||||
endif
|
||||
$(Q) rm -f libarch$(LIBEXT) *~ .*.swp
|
||||
$(call DELFILE libarch$(LIBEXT))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
ifeq ($(BOARDMAKE),y)
|
||||
$(Q) $(MAKE) -C board TOPDIR="$(TOPDIR)" distclean
|
||||
endif
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -137,16 +137,20 @@ clean:
|
|||
$(Q) if [ -e board/Makefile ]; then \
|
||||
$(MAKE) -C board TOPDIR="$(TOPDIR)" clean ; \
|
||||
fi
|
||||
$(Q) rm -f libarch$(LIBEXT) *~ .*.swp
|
||||
ifeq ($(COMPILER),zneocc.exe)
|
||||
$(Q) rm -f nuttx.linkcmd *.asm *.tmp *.map
|
||||
$(call DELFILE nuttx.linkcmd)
|
||||
$(call DELFILE *.asm)
|
||||
$(call DELFILE *.tmp)
|
||||
$(call DELFILE *.map)
|
||||
endif
|
||||
$(call DELFILE libarch$(LIBEXT))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
$(Q) if [ -e board/Makefile ]; then \
|
||||
$(MAKE) -C board TOPDIR="$(TOPDIR)" distclean ; \
|
||||
fi
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -240,13 +240,19 @@ clean:
|
|||
$(Q) if [ -e board/Makefile ]; then \
|
||||
$(MAKE) -C board TOPDIR="$(TOPDIR)" clean ; \
|
||||
fi
|
||||
$(Q) rm -f libarch$(LIBEXT) up_mem.h asm_mem.h pass1.* nuttx.* *~ .*.swp
|
||||
$(call DELFILE up_mem.h)
|
||||
$(call DELFILE asm_mem.h)
|
||||
$(call DELFILE pass1.*)
|
||||
$(call DELFILE nuttx.*)
|
||||
$(call DELFILE libarch$(LIBEXT))
|
||||
$(call CLEAN)
|
||||
|
||||
|
||||
distclean: clean
|
||||
$(Q) if [ -e board/Makefile ]; then \
|
||||
$(MAKE) -C board TOPDIR="$(TOPDIR)" distclean ; \
|
||||
fi
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -150,14 +150,18 @@ clean:
|
|||
$(Q) if [ -e board/Makefile ]; then \
|
||||
$(MAKE) -C board TOPDIR="$(TOPDIR)" clean ; \
|
||||
fi
|
||||
$(Q) rm -f libarch$(LIBEXT) *~ .*.swp
|
||||
$(Q) rm -f nuttx.linkcmd *.asm *.tmp *.map
|
||||
$(call DELFILE nuttx.linkcmd)
|
||||
$(call DELFILE *.asm)
|
||||
$(call DELFILE *.tmp)
|
||||
$(call DELFILE *.map)
|
||||
$(call DELFILE libarch$(LIBEXT))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
$(Q) if [ -e board/Makefile ]; then \
|
||||
$(MAKE) -C board TOPDIR="$(TOPDIR)" distclean ; \
|
||||
fi
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -87,13 +87,11 @@ $(BIN): $(BINFMT_OBJS)
|
|||
depend: .depend
|
||||
|
||||
clean:
|
||||
$(Q) rm -f $(BIN) *~ .*.swp
|
||||
$(call DELFILE $(BIN))
|
||||
$(call CLEAN)
|
||||
$(Q) ( for dir in $(SUBDIRS); do \
|
||||
rm -f $${dir}/*~ $${dir}/.*.swp; \
|
||||
done ; )
|
||||
|
||||
distclean: clean
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -126,16 +126,17 @@ libboard$(LIBEXT): $(OBJS)
|
|||
$(call ARCHIVE, $@, $(OBJS))
|
||||
|
||||
.depend: Makefile $(SRCS)
|
||||
@$(MKDEP) $(CC) -- $(CFLAGS) -- $(SRCS) >Make.dep
|
||||
@touch $@
|
||||
$(Q) $(MKDEP) $(CC) -- $(CFLAGS) -- $(SRCS) >Make.dep
|
||||
$(Q) touch $@
|
||||
|
||||
depend: .depend
|
||||
|
||||
clean:
|
||||
@rm -f libboard$(LIBEXT) *~ .*.swp
|
||||
$(call DELFILE libboard$(LIBEXT))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
@rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -111,10 +111,11 @@ $(BIN): $(OBJS)
|
|||
depend: .depend
|
||||
|
||||
clean:
|
||||
$(Q) rm -f $(BIN) *~ .*.swp
|
||||
$(call DELFILE $(BIN))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -130,13 +130,11 @@ $(BIN): $(OBJS)
|
|||
depend: .depend
|
||||
|
||||
clean:
|
||||
$(Q) rm -f $(BIN) *~ .*.swp
|
||||
$(call DELFILE $(BIN))
|
||||
$(call CLEAN)
|
||||
$(Q) ( for dir in $(SUBDIRS); do \
|
||||
rm -f $${dir}/*~ $${dir}/.*.swp; \
|
||||
done ; )
|
||||
|
||||
distclean: clean
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -33,7 +33,6 @@
|
|||
#
|
||||
############################################################################
|
||||
|
||||
-include $(TOPDIR)/.config
|
||||
-include $(TOPDIR)/Make.defs
|
||||
|
||||
DEPPATH = --dep-path .
|
||||
|
|
@ -201,13 +200,14 @@ context: gensources
|
|||
clean:
|
||||
$(Q) $(MAKE) -C nxglib -f Makefile.sources clean TOPDIR=$(TOPDIR) EXTRADEFINES=$(EXTRADEFINES)
|
||||
$(Q) $(MAKE) -C nxfonts -f Makefile.sources clean TOPDIR=$(TOPDIR) EXTRADEFINES=$(EXTRADEFINES)
|
||||
$(Q) rm -f $(BIN) *~ .*.swp
|
||||
$(call DELFILE $(BIN))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
$(Q) $(MAKE) -C nxglib -f Makefile.sources distclean TOPDIR=$(TOPDIR) EXTRADEFINES=$(EXTRADEFINES)
|
||||
$(Q) $(MAKE) -C nxfonts -f Makefile.sources distclean TOPDIR=$(TOPDIR) EXTRADEFINES=$(EXTRADEFINES)
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
||||
|
|
|
|||
|
|
@ -33,7 +33,6 @@
|
|||
#
|
||||
############################################################################
|
||||
|
||||
-include $(TOPDIR)/.config
|
||||
-include $(TOPDIR)/Make.defs
|
||||
|
||||
ifdef NXFONTS_BITSPERPIXEL
|
||||
|
|
@ -177,13 +176,14 @@ all: $(GEN_CSRC)
|
|||
.PHONY : clean distclean
|
||||
|
||||
$(GEN_CSRC) : $(DEPENDENCY)
|
||||
@$(call PREPROCESS, $<, $(GEN_TMP))
|
||||
@cat $(GEN_TMP) | sed -e "/^#/d" >$@
|
||||
@rm -f $(GEN_TMP)
|
||||
$(call PREPROCESS, $<, $(GEN_TMP))
|
||||
$(Q) cat $(GEN_TMP) | sed -e "/^#/d" >$@
|
||||
$(Q) rm -f $(GEN_TMP)
|
||||
|
||||
clean:
|
||||
@rm -f *~ .*.swp *.i
|
||||
$(call DELFILE *.i)
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
@rm -f nxfonts_convert_*bpp.c
|
||||
@rm -f nxfonts_bitmaps_*.c
|
||||
$(call DELFILE nxfonts_convert_*bpp.c)
|
||||
$(call DELFILE nxfonts_bitmaps_*.c)
|
||||
|
|
|
|||
|
|
@ -33,7 +33,6 @@
|
|||
#
|
||||
############################################################################
|
||||
|
||||
-include $(TOPDIR)/.config
|
||||
-include $(TOPDIR)/Make.defs
|
||||
|
||||
ifeq ($(NXGLIB_BITSPERPIXEL),1)
|
||||
|
|
@ -123,53 +122,54 @@ all: $(GEN_CSRCS)
|
|||
|
||||
$(SETP_CSRC) : $(BLITDIR)/nxglib_setpixel.c nxglib_bitblit.h
|
||||
ifneq ($(NXGLIB_BITSPERPIXEL),)
|
||||
@$(call PREPROCESS, $(BLITDIR)/nxglib_setpixel.c, $(SETP_TMP))
|
||||
@cat $(SETP_TMP) | sed -e "/^#/d" >$@
|
||||
@rm -f $(SETP_TMP)
|
||||
$(call PREPROCESS, $(BLITDIR)/nxglib_setpixel.c, $(SETP_TMP))
|
||||
$(Q) cat $(SETP_TMP) | sed -e "/^#/d" >$@
|
||||
$(Q) rm -f $(SETP_TMP)
|
||||
endif
|
||||
|
||||
$(RFILL_CSRC) : $(BLITDIR)/nxglib_fillrectangle.c nxglib_bitblit.h
|
||||
ifneq ($(NXGLIB_BITSPERPIXEL),)
|
||||
@$(call PREPROCESS, $(BLITDIR)/nxglib_fillrectangle.c, $(RFILL_TMP))
|
||||
@cat $(RFILL_TMP) | sed -e "/^#/d" >$@
|
||||
@rm -f $(RFILL_TMP)
|
||||
$(call PREPROCESS, $(BLITDIR)/nxglib_fillrectangle.c, $(RFILL_TMP))
|
||||
$(Q) cat $(RFILL_TMP) | sed -e "/^#/d" >$@
|
||||
$(Q) rm -f $(RFILL_TMP)
|
||||
endif
|
||||
|
||||
$(RGET_CSRC) : $(BLITDIR)/nxglib_getrectangle.c nxglib_bitblit.h
|
||||
ifneq ($(NXGLIB_BITSPERPIXEL),)
|
||||
@$(call PREPROCESS, $(BLITDIR)/nxglib_getrectangle.c, $(RGET_TMP))
|
||||
@cat $(RGET_TMP) | sed -e "/^#/d" >$@
|
||||
@rm -f $(RGET_TMP)
|
||||
$(call PREPROCESS, $(BLITDIR)/nxglib_getrectangle.c, $(RGET_TMP))
|
||||
$(Q) cat $(RGET_TMP) | sed -e "/^#/d" >$@
|
||||
$(Q) rm -f $(RGET_TMP)
|
||||
endif
|
||||
|
||||
$(TFILL_CSRC) : $(BLITDIR)/nxglib_filltrapezoid.c nxglib_bitblit.h
|
||||
ifneq ($(NXGLIB_BITSPERPIXEL),)
|
||||
@$(call PREPROCESS, $(BLITDIR)/nxglib_filltrapezoid.c, $(TFILL_TMP))
|
||||
@cat $(TFILL_TMP) | sed -e "/^#/d" >$@
|
||||
@rm -f $(TFILL_TMP)
|
||||
$(call PREPROCESS, $(BLITDIR)/nxglib_filltrapezoid.c, $(TFILL_TMP))
|
||||
$(Q) cat $(TFILL_TMP) | sed -e "/^#/d" >$@
|
||||
$(Q) rm -f $(TFILL_TMP)
|
||||
endif
|
||||
|
||||
$(RMOVE_CSRC) : $(BLITDIR)/nxglib_moverectangle.c nxglib_bitblit.h
|
||||
ifneq ($(NXGLIB_BITSPERPIXEL),)
|
||||
@$(call PREPROCESS, $(BLITDIR)/nxglib_moverectangle.c, $(RMOVE_TMP))
|
||||
@cat $(RMOVE_TMP) | sed -e "/^#/d" >$@
|
||||
@rm -f $(RMOVE_TMP)
|
||||
$(call PREPROCESS, $(BLITDIR)/nxglib_moverectangle.c, $(RMOVE_TMP))
|
||||
$(Q) cat $(RMOVE_TMP) | sed -e "/^#/d" >$@
|
||||
$(Q) rm -f $(RMOVE_TMP)
|
||||
endif
|
||||
|
||||
$(RCOPY_CSRC) : $(BLITDIR)/nxglib_copyrectangle.c nxglib_bitblit.h
|
||||
ifneq ($(NXGLIB_BITSPERPIXEL),)
|
||||
@$(call PREPROCESS, $(BLITDIR)/nxglib_copyrectangle.c, $(RCOPY_TMP))
|
||||
@cat $(RCOPY_TMP) | sed -e "/^#/d" >$@
|
||||
@rm -f $(RCOPY_TMP)
|
||||
$(call PREPROCESS, $(BLITDIR)/nxglib_copyrectangle.c, $(RCOPY_TMP))
|
||||
$(Q) cat $(RCOPY_TMP) | sed -e "/^#/d" >$@
|
||||
$(Q) rm -f $(RCOPY_TMP)
|
||||
endif
|
||||
|
||||
clean:
|
||||
@rm -f *~ .*.swp *.i
|
||||
$(call DELFILE *.i)
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
@rm -f nxglib_setpixel_*bpp.c
|
||||
@rm -f nxglib_fillrectangle_*bpp.c
|
||||
@rm -f nxglib_getrectangle_*bpp.c
|
||||
@rm -f nxglib_filltrapezoid_*bpp.c
|
||||
@rm -f nxglib_moverectangle_*bpp.c
|
||||
@rm -f nxglib_copyrectangle_*bpp.c
|
||||
$(call DELFILE nxglib_setpixel_*bpp.c)
|
||||
$(call DELFILE nxglib_fillrectangle_*bpp.c)
|
||||
$(call DELFILE nxglib_getrectangle_*bpp.c)
|
||||
$(call DELFILE nxglib_filltrapezoid_*bpp.c)
|
||||
$(call DELFILE nxglib_moverectangle_*bpp.c)
|
||||
$(call DELFILE nxglib_copyrectangle_*bpp.c)
|
||||
|
|
|
|||
|
|
@ -40,6 +40,6 @@ all:
|
|||
depend:
|
||||
|
||||
clean:
|
||||
$(Q) rm -f *$(LIBEXT)
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
|
|
|
|||
|
|
@ -114,7 +114,7 @@ else
|
|||
$(Q) ( if [ -f .userlib ]; then rm -f *$(OBJEXT); fi )
|
||||
endif
|
||||
endif
|
||||
$(Q) rm -f .userlib *~ .*.swp
|
||||
$(call DELFILE .userlib)
|
||||
|
||||
# Clean kernel-mode temporary files (retaining the KBIN binary)
|
||||
|
||||
|
|
@ -126,17 +126,20 @@ else
|
|||
$(Q) ( if [ -f .kernlib ]; then rm -f *$(OBJEXT); fi )
|
||||
endif
|
||||
endif
|
||||
$(Q) rm -f .kernlib *~ .*.swp
|
||||
$(call DELFILE .kernlib)
|
||||
|
||||
# Really clean everything
|
||||
|
||||
clean: uclean kclean
|
||||
$(Q) rm -f $(BIN) $(UBIN) $(KBIN) *~ .*.swp
|
||||
$(call DELFILE $(BIN))
|
||||
$(call DELFILE $(UBIN))
|
||||
$(call DELFILE $(KBIN))
|
||||
$(call CLEAN)
|
||||
|
||||
# Deep clean -- removes all traces of the configuration
|
||||
|
||||
distclean: clean
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -105,10 +105,11 @@ $(BIN): $(OBJS)
|
|||
depend: .depend
|
||||
|
||||
clean:
|
||||
$(Q) rm -f $(BIN) *~ .*.swp
|
||||
$(call DELFILE $(BIN))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -70,10 +70,11 @@ $(BIN): $(OBJS)
|
|||
depend: .depend
|
||||
|
||||
clean:
|
||||
$(Q) rm -f $(BIN) *~ .*.swp
|
||||
$(call DELFILE $(BIN))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -33,12 +33,14 @@
|
|||
#
|
||||
############################################################################
|
||||
|
||||
SRCS = mm_test.c mm_initialize.c mm_sem.c mm_addfreechunk.c mm_size2ndx.c mm_shrinkchunk.c \
|
||||
-include $(TOPDIR)/Make.defs
|
||||
|
||||
SRCS = mm_test.c mm_initialize.c mm_sem.c mm_addfreechunk.c mm_size2ndx.c mm_shrinkchunk.c \
|
||||
mm_malloc.c mm_zalloc.c mm_calloc.c mm_realloc.c \
|
||||
mm_memalign.c mm_free.c mm_mallinfo.c
|
||||
OBJS = $(SRCS:.c=.o1)
|
||||
OBJS = $(SRCS:.c=.o1)
|
||||
|
||||
LIBS = -lpthread -lc
|
||||
LIBS = -lpthread -lc
|
||||
|
||||
CC = gcc
|
||||
LD = gcc
|
||||
|
|
@ -48,17 +50,19 @@ WARNIGNS = -Wall -Wstrict-prototypes -Wshadow
|
|||
CFLAGS = -g $(DEFINES)
|
||||
LDFLAGS =
|
||||
|
||||
BIN = ../mm_test
|
||||
BIN = ..$(DELIM)mm_test
|
||||
|
||||
all: $(BIN)
|
||||
|
||||
$(OBJS): %.o1: %.c
|
||||
@echo "Compiling $<"
|
||||
$(CC) -c $(CFLAGS) $< -o $@
|
||||
$(Q) $(CC) -c $(CFLAGS) $< -o $@
|
||||
|
||||
$(BIN): $(OBJS)
|
||||
@echo "Linking {$(OBJS)} to produce $@"
|
||||
$(LD) $(LDFLAGS) $(OBJS) $(LIBS) -o $@
|
||||
$(Q) $(LD) $(LDFLAGS) $(OBJS) $(LIBS) -o $@
|
||||
|
||||
clean:
|
||||
@rm -f $(BIN) *.o1 *~
|
||||
$(call DELFILE $(BIN))
|
||||
$(call DELFILE *.o1)
|
||||
$(call CLEAN)
|
||||
|
|
|
|||
|
|
@ -111,11 +111,11 @@ endif
|
|||
depend: .depend
|
||||
|
||||
clean:
|
||||
$(Q) rm -f $(BIN) *~ .*.swp
|
||||
$(Q) rm -f uip/*~ uip/.*.swp
|
||||
$(call DELFILE $(BIN))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -188,6 +188,7 @@ OBJS = $(AOBJS) $(COBJS)
|
|||
BIN = libsched$(LIBEXT)
|
||||
|
||||
all: $(BIN)
|
||||
.PHONY: context depend clean distclean
|
||||
|
||||
$(AOBJS): %$(OBJEXT): %.S
|
||||
$(call ASSEMBLE, $<, $@)
|
||||
|
|
@ -205,10 +206,11 @@ $(BIN): $(OBJS)
|
|||
depend: .depend
|
||||
|
||||
clean:
|
||||
$(Q) rm -f $(BIN)
|
||||
$(call DELFILE $(BIN))
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
$(Q) rm -f Make.dep .depend
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
|
||||
-include Make.dep
|
||||
|
|
|
|||
|
|
@ -34,11 +34,11 @@
|
|||
###########################################################################
|
||||
|
||||
-include $(TOPDIR)/Make.defs
|
||||
include proxies/Make.defs
|
||||
include stubs/Make.defs
|
||||
include proxies$(DELIM)Make.defs
|
||||
include stubs$(DELIM)Make.defs
|
||||
|
||||
MKSYSCALL = "$(TOPDIR)/tools/mksyscall$(EXEEXT)"
|
||||
CSVFILE = "$(TOPDIR)/syscall/syscall.csv"
|
||||
MKSYSCALL = "$(TOPDIR)$(DELIM)tools$(DELIM)mksyscall$(EXEEXT)"
|
||||
CSVFILE = "$(TOPDIR)$(DELIM)syscall$(DELIM)syscall.csv"
|
||||
|
||||
STUB_SRCS += stub_lookup.c
|
||||
|
||||
|
|
@ -85,7 +85,7 @@ $(BIN2): $(STUB_OBJS)
|
|||
depend: .depend
|
||||
|
||||
$(MKSYSCALL):
|
||||
$(Q) $(MAKE) -C $(TOPDIR)/tools -f Makefile.host mksyscall
|
||||
$(Q) $(MAKE) -C $(TOPDIR)$(DELIM)tools -f Makefile.host mksyscall
|
||||
|
||||
.context: syscall.csv
|
||||
$(Q) (cd proxies; $(MKSYSCALL) -p $(CSVFILE);)
|
||||
|
|
@ -95,15 +95,20 @@ $(MKSYSCALL):
|
|||
context: $(MKSYSCALL) .context
|
||||
|
||||
clean:
|
||||
$(Q) rm -f $(BIN1) $(BIN2) *~ .*.swp
|
||||
$(call DELFILE $(BIN1))
|
||||
$(call DELFILE $(BIN2))
|
||||
ifneq ($(OBJEXT),)
|
||||
$(Q) rm -f proxies/*$(OBJEXT) stubs/*$(OBJEXT)
|
||||
$(call DELFILE proxies$(DELIM)*$(OBJEXT))
|
||||
$(call DELFILE stubs$(DELIM)*$(OBJEXT))
|
||||
endif
|
||||
$(call CLEAN)
|
||||
|
||||
distclean: clean
|
||||
$(Q) rm -f Make.dep .depend .context
|
||||
$(Q) rm -f proxies/*.c stubs/*.c
|
||||
$(call DELFILE .context)
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE .depend)
|
||||
$(call DELFILE proxies$(DELIM)*.c)
|
||||
$(call DELFILE stubs$(DELIM)*.c)
|
||||
|
||||
-include Make.dep
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,9 @@
|
|||
# Config.mk
|
||||
# Global build rules and macros.
|
||||
#
|
||||
# Copyright (C) 2011 Gregory Nutt. All rights reserved.
|
||||
# Author: Richard Cochran
|
||||
# Gregory Nutt <gnutt@nuttx.org>
|
||||
#
|
||||
# This file (along with $(TOPDIR)/.config) must be included by every
|
||||
# configuration-specific Make.defs file.
|
||||
|
|
@ -43,6 +45,12 @@ CONFIG_ARCH := $(patsubst "%",%,$(strip $(CONFIG_ARCH)))
|
|||
CONFIG_ARCH_CHIP := $(patsubst "%",%,$(strip $(CONFIG_ARCH_CHIP)))
|
||||
CONFIG_ARCH_BOARD := $(patsubst "%",%,$(strip $(CONFIG_ARCH_BOARD)))
|
||||
|
||||
# Some defaults just to prohibit some bad behavior if for some reason they
|
||||
# are not defined
|
||||
|
||||
OBJEXT ?= .o
|
||||
LIBEXT ?= .a
|
||||
|
||||
# DELIM - Path segment delimiter character
|
||||
#
|
||||
# Depends on this settings defined in board-specific defconfig file installed
|
||||
|
|
@ -167,12 +175,30 @@ define ARCHIVE
|
|||
endef
|
||||
endif
|
||||
|
||||
# DELFILE - Delete one file
|
||||
|
||||
ifeq ($(CONFIG_WINDOWS_NATIVE),y)
|
||||
define CLEAN
|
||||
$(Q) rm -f *.o *.a
|
||||
define DELFILE
|
||||
$(Q) if exist $1 (del /f /q $1)
|
||||
endef
|
||||
else
|
||||
define CLEAN
|
||||
$(Q) rm -f *.o *.a *~ .*.swp
|
||||
$(Q) rm -f $1
|
||||
endef
|
||||
endif
|
||||
|
||||
# CLEAN - Default clean target
|
||||
|
||||
ifeq ($(CONFIG_WINDOWS_NATIVE),y)
|
||||
define CLEAN
|
||||
$(Q) if exist *$(OBJEXT) (del /f /q *$(OBJEXT))
|
||||
$(Q) if exist *$(LIBEXT) (del /f /q *$(LIBEXT))
|
||||
$(Q) if exist *~ (del /f /q *~)
|
||||
$(Q) if exist (del /f /q .*.swp)
|
||||
endef
|
||||
else
|
||||
define CLEAN
|
||||
$(Q) rm -f *$(OBJEXT) *$(LIBEXT) *~ .*.swp
|
||||
endef
|
||||
endif
|
||||
|
||||
|
|
@ -122,8 +122,18 @@ mkdeps: mkdeps$(HOSTEXEEXT)
|
|||
endif
|
||||
|
||||
clean:
|
||||
$(Q) rm -f *.o *.a *~ .*.swp
|
||||
$(Q) rm -f mkdeps mkconfig mksyscall mkversion bdf-converter
|
||||
$(Q) rm -f mkdeps.exe mkconfig.exe mksyscall.exe mkversion.exe bdf-converter.exe
|
||||
$(call DELFILE mkdeps)
|
||||
$(call DELFILE mkdeps.exe)
|
||||
$(call DELFILE mkconfig)
|
||||
$(call DELFILE mkconfig.exe)
|
||||
$(call DELFILE Make.dep)
|
||||
$(call DELFILE mksyscall)
|
||||
$(call DELFILE mksyscall.exe)
|
||||
$(call DELFILE mkversion)
|
||||
$(call DELFILE mkversion.exe)
|
||||
$(call DELFILE bdf-converter)
|
||||
$(call DELFILE bdf-converter.exe)
|
||||
ifneq ($(CONFIG_WINDOWS_NATIVE),y)
|
||||
$(Q) rm -rf *.dSYM
|
||||
|
||||
endif
|
||||
$(call CLEAN)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue