aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tomo.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/tomo.c b/tomo.c
index a2e5342f..03056bfc 100644
--- a/tomo.c
+++ b/tomo.c
@@ -252,7 +252,8 @@ int transpile(const char *filename, bool force_retranspile)
int compile_object_file(const char *filename, bool force_recompile)
{
const char *obj_file = heap_strf("%s.o", filename);
- if (!force_recompile && !stale(obj_file, filename)) {
+ if (!force_recompile && !stale(obj_file, filename)
+ && !stale(obj_file, heap_strf("%s.c", filename)) && !stale(obj_file, heap_strf("%s.h", filename))) {
return 0;
}
const char *cmd = heap_strf("%s %s -c %s.c -o %s.o", cc, cflags, filename, filename);