chiark / gitweb /
&TARGETS*: make autogenerated targets .PHONY
[subdirmk.git] / generate
index dd22146..7bdbd88 100755 (executable)
--- a/generate
+++ b/generate
@@ -254,6 +254,11 @@ sub process_subtree ($$) {
        }
        print O "\n";
     }
+    if (@targets) {
+       print O ".PHONY:";
+       print O " ${dir_prefix}${_}" foreach @targets;
+       print O "\n";
+    }
 
     return @targets;
 }