slightly closer but cleanups are still wrong.
[feisty_meow.git] / scripts / clam / cpp / rules.def
index e0b723156de1f9dc31df9322ed31347467436e0b..a6821bf4037bd1f3400ce48753f88d12cfe990c5 100644 (file)
@@ -398,15 +398,6 @@ ACTUAL_LAST_TARGETS = post_compilation $(LAST_TARGETS)
 
 ############################################################################
 
-ifneq "$(CLEAN)" ""
-# Add the obligatory junk to be cleaned up.
-set_cleanups_variable:
-       $(eval CLEANUPS += $(ACTUAL_TARGETS) $(ACTUAL_TARGETS:%.exe=%) )
-#      echo "new CLEANUPS variable: $(CLEANUPS)"
-endif
-
-############################################################################
-
 # This section defines the rules used to generate various objects from their
 # source files.
 
@@ -444,6 +435,17 @@ endif
 
 ############################################################################
 
+# trying to delay loading this as long as possible so the built in rule system for CLEANUPS can run with the right values.
+# so far not working right!
+#hmmm: fix this.
+
+# Adds the main CLAM system in to get some work done.  This should be placed
+# after the module's rules are defined and before the module's targets are
+# defined.
+include rules.def
+
+############################################################################
+
 # C++ source to object file translation.
 # if there is a special set of flags for this source file, we use them
 # instead of the default compiler flags.
@@ -663,11 +665,6 @@ endif
 
 # Now the active part of the make process...
 
-# Adds the main CLAM system in to get some work done.  This should be placed
-# after the module's rules are defined and before the module's targets are
-# defined.
-include rules.def
-
 # make sure we really want to include the dependencies file.
 ifeq "$(TYPE)" "hierarchy"
   # no dependencies for a simple hierarchy builder.