rmyorston / pdpmake

Public domain POSIX make
https://frippery.org/make
Other
111 stars 11 forks source link

Always build everything from scratch? #68

Closed mh466lfa closed 1 week ago

mh466lfa commented 1 month ago

GNU Make keeps track of things and only builds what are needed to rebuild after I modified the code. PDPMake seems to always build everything from scratch. Please correct me if I'm wrong.

rmyorston commented 1 month ago

Not 'always':

$ pdpmake clean
rm -f check.o input.o macro.o main.o make.o modtime.o rules.o target.o utils.o make
$ pdpmake
cc -O1 -c check.c
cc -O1 -c input.c
cc -O1 -c macro.c
cc -O1 -c main.c
cc -O1 -c make.c
cc -O1 -c modtime.c
cc -O1 -c rules.c
cc -O1 -c target.c
cc -O1 -c utils.c
cc  -o make check.o input.o macro.o main.o make.o modtime.o rules.o target.o utils.o
$ touch make.c
$ pdpmake
cc -O1 -c make.c
cc  -o make check.o input.o macro.o main.o make.o modtime.o rules.o target.o utils.o
$

Can you provide an example of a project where pdpmake is rebuilding more than necessary after a change?