How does make decide if a binary is 'up to date'

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

How does make decide if a binary is 'up to date'

cdanek
 Hi all

Say I would like to reproduce the behavior of make. How exactly does
make decide if a binary is 'up to date'?
Maybe something like this?:
https://unix.stackexchange.com/questions/372857/compare-two-file-modification-dates
But how exactly?

Thanks a lot for any answer,
Chris

 
_______________________________________________
Help-make mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-make
Reply | Threaded
Open this post in threaded view
|

Re: How does make decide if a binary is 'up to date'

John Calcote-2
Hi Chris,

Make uses file existence and last-modified timestamps to determine if a
target is newer than it's prerequisites. There are other tools that use
checksums like md5, but make only uses presence and timestamps.

John

On Thu, May 2, 2019 at 11:52 AM <[hidden email]> wrote:

>  Hi all
>
> Say I would like to reproduce the behavior of make. How exactly does
> make decide if a binary is 'up to date'?
> Maybe something like this?:
>
> https://unix.stackexchange.com/questions/372857/compare-two-file-modification-dates
> But how exactly?
>
> Thanks a lot for any answer,
> Chris
>
>
> _______________________________________________
> Help-make mailing list
> [hidden email]
> https://lists.gnu.org/mailman/listinfo/help-make
>
_______________________________________________
Help-make mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-make