diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2012-09-08 16:40:12 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2012-09-08 16:40:12 +0000 |
commit | 6225d35fa1d5087755574c10d7ccec48d878dc44 (patch) | |
tree | e425d0096af13d7e633bce8641a4dd3306327540 /nuttx/Makefile | |
parent | b4420923cb149a5a8164bb06794e12b88203d97c (diff) | |
download | nuttx-6225d35fa1d5087755574c10d7ccec48d878dc44.tar.gz nuttx-6225d35fa1d5087755574c10d7ccec48d878dc44.tar.bz2 nuttx-6225d35fa1d5087755574c10d7ccec48d878dc44.zip |
Changes to get a clean compile with the Kconfig Shenzhou board. Still some link issues
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5115 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/Makefile')
-rw-r--r-- | nuttx/Makefile | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/nuttx/Makefile b/nuttx/Makefile index 1a51ca09b..0f3413cb1 100644 --- a/nuttx/Makefile +++ b/nuttx/Makefile @@ -616,9 +616,10 @@ endif # apps_clean: Perform the clean operation only in the user application # directory # apps_distclean: Perform the distclean operation only in the user application -# directory. Note that the apps/.config file is preserved -# so that this is not a "full" distclean but more of a -# configuration "reset." +# directory. Note that the apps/.config file (inf any) is +# preserved so that this is not a "full" distclean but more of a +# configuration "reset." (There willnot be an apps/.config +# file if the configuration was generated via make menuconfig). apps_clean: ifneq ($(APPDIR),) @@ -627,10 +628,16 @@ endif apps_distclean: ifneq ($(APPDIR),) - @cp "$(TOPDIR)/$(APPDIR)/.config" _SAVED_APPS_config || \ - { echo "Copy of $(APPDIR)/.config failed" ; exit 1 ; } + @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 @$(MAKE) -C "$(TOPDIR)/$(APPDIR)" TOPDIR="$(TOPDIR)" distclean - @mv _SAVED_APPS_config "$(TOPDIR)/$(APPDIR)/.config" || \ - { echo "Copy of _SAVED_APPS_config failed" ; exit 1 ; } + @if [ -r _SAVED_APPS_config ]; then \ + @mv _SAVED_APPS_config "$(TOPDIR)/$(APPDIR)/.config" || \ + { echo "Copy of _SAVED_APPS_config failed" ; exit 1 ; } \ + fi endif |