build/Makefile.comp
changeset 26 dc7c549001d5
parent 21 2a9601315dfc
child 35 85266cc22c7f
child 46 4376525cdefb
--- a/build/Makefile.comp	Fri May 14 15:47:24 2010 +0300
+++ b/build/Makefile.comp	Thu May 27 12:49:31 2010 +0300
@@ -98,6 +98,24 @@
 	echo SUBDIRS += $(TARGET_SUB)/$(PRO_FILE) >> $(TARGET_PRO)
 endif
 
+# The remove_notbuilt removes platform specific subdirectories not
+# participating in the built of current environment
+ifeq ($(BUILDENV),symbian)
+REMOVEWILDCARD = *.linux
+else
+REMOVEWILDCARD = *.s60
+endif
+REMOVEDIRECORIES = $(call PATHFIX,$(wildcard ../$(REMOVEWILDCARD)))
+remove_notbuilt:
+ifneq ($(REMOVEDIRECORIES),)
+ifdef SIMULATE
+	echo Remove not-built directories at $(CURDIR): $(REMOVEDIRECORIES)
+else
+	echo Removing not-built directories at $(CURDIR): $(REMOVEDIRECORIES) \
+	$(foreach d,$(REMOVEDIRECORIES),&& $(call DELTREE,$(d)))
+endif
+endif
+
 # Symbian ----------------------------------
 ifeq ($(BUILDENV),symbian)